An audio (and #AUDIO) question

On the creation of AY or Beeper music, including the packages used to do so.
User avatar
SkoolKid
Manic Miner
Posts: 407
Joined: Wed Nov 15, 2017 3:07 pm

Re: An audio (and #AUDIO) question

Post by SkoolKid »

TheMartian wrote: Sat Nov 04, 2023 7:12 am I believe the cause for this effect resides in Nyquist theorem: You need the signal to be frequency-limited previous to a sampling process (the creation of the WAV file is a sampling at 44100). If the signal is not bound in frequency to half the sampling frequency there'll be aliasing.
I'll take your word for it, but this is one of those occasions where I understand what I've coded, but I don't really understand how it actually works. I'm just glad that it does! :lol:
SkoolKit - disassemble a game today
Pyskool - a remake of Skool Daze and Back to Skool
User avatar
Seven.FFF
Manic Miner
Posts: 744
Joined: Sat Nov 25, 2017 10:50 pm
Location: USA

Re: An audio (and #AUDIO) question

Post by Seven.FFF »

Yes, square waves have odd harmonics. That is, a perfect square wave is equivalent to a bunch of sine waves at 1, 3, 5, 7 … Infinity times the base frequency, tailing off in amplitude as it goes higher, all superimposed on top of each other. The Speccy beeper is far from a perfect square wave but unfiltered harmonics above the nyquist limit can have an audible effect.
Robin Verhagen-Guest
SevenFFF / Threetwosevensixseven / colonel32
NXtel NXTP ESP Update ESP Reset CSpect Plugins
Post Reply