[sdiy] Pulse Width Modulation sampling??
Rainer Buchty
buchty at cs.tum.edu
Tue Feb 3 11:18:59 CET 2004
On Tue, 3 Feb 2004, Mark Smith wrote:
> I think you are talking about mod files. These were something like
> a 4 channel sound source - probably done by the SID chip using PCM
> modulation (unless someone corrects me). Some of the best files I recall
> were public domain demos done on the amiga.
Uhm, mod files were invented on the Commodore Amiga. What's typically done
on the C64 is to extend the 3 analog voices by a 4th or even 5th sample
voice. There are basically two methods for playing back samples on the
C64:
- through the volume register; works best on 6581, 8580 need to be tweaked
(basically because a design flaw, a constant DC level IIRC, was
eliminated; with a 8580 you need to pull the external input, see below, to
GND) and gives a resolution of 4 bits. Because the final DCA sits on the
end of the chain, no further processing is possible.
- through the PWM registers; gives up to 3 sample voices with a resolution
of 12-bit, but you need an (audible) carrier tone to modulate it on, i.e.
one "analog" (it's a phase accu design) oscillator is lost for each PWM
sample voice; however, the sample can be processed through the
oscillator's ADSR EG, the multimode filter, and the final DCA.
- fake, by routing an external signal through the external input which
allows routing signals through the filter and final DCA.
- DAC connected to any port (user, joystick, expansion, tape), but since
it's extra hardware, it counts as fake to me :)
For any decent playback rate, however, the C64 is far too slow. E.g. 22kHz
is only possible with a SuperCPU (which is a 20MHz 65816 system which
basically uses the C64 attached as an I/O terminal); but the extreme lo-fi
sounds of 4-bit/8kHz playback are somewhat charming (I recommend the game
musics done by Chris Huelsbeck like "To be on top" or "Jinks").
Rainer
More information about the Synth-diy
mailing list