The Amiga vs the Fairlight CMI


Since I have several Amigas, I don't really care if publishing this pushes the used prices of Amigas through the roof because of GAS.

The Amiga and the Fairlight CMI (I/II) have many similarities in how they sound and work:

AmigaFairlight CMI I/II
Sample bit depth:8 bits8 bits
Maximum sample rate:28kHz with DMA, 50+kHz with CPU24kHz (Series I), 32kHz (Series II)
Sample RAM:512KB to 2MB, shared between all voices16KB per voice, 128KB total
Re-sampling:None, DAC runs at variable sample rateNone, DAC runs at variable sample rate
Interpolation:None, but switchable low-pass filter can be enabled for all 4 voicesNone, but variable low-pass filter can be applied for each voice
Voices:4, but can chain several Amigas for more8
DAC type:R2R ladderR2R ladder
Amplifier:64-step PWM (~84dB dynamic range)Analogue VCA (90dB+ dynamic range)

Apart from the lack of a variable low-pass filter on the Amiga, the sound is very similar. It has the same harmonically-related aliasing when you down-pitch a sample. Similar types of distortion due to the precision of the R2R ladder DAC. High dynamic range but low SNR as typical of an 8 bit sampler with a post-DAC variable amplifier.

For sounds which benefit from a variable low-pass filter, you can run the Amiga's output through an external filter in a modular synthesiser. Now you have the "Fairlight sound" at a fraction of the price!

The sound is both gritty and clean at the same time. This is because the aliasing moves around with the pitch of the sample being played. Later samplers employ a fixed sample rate and re-sampling. They have strange wrap-around aliasing behaviour which sounds completely unnatural. In still later samplers, digital filtering is employed to eliminate as much aliasing as possible. But small amounts of non-harmonic aliasing remain (even on the latest software plug-ins).

It is no surprise that several hit records have been produced with Amigas as the sound source. There is nothing quite like it at the price point.

Doing a variable low-pass filter in software

Of course Amiga makes this possible too.

I haven't tested this yet, it may give you a 12dB/oct (2-pole) non-resonant continuously-variable lowpass filter:

		;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
		; Form the multiplier table
		; d0.w: filter cutoff frequency 0-65535
		; a0:   multiplier table base pointer (512 bytes)
		;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
form_table
		move.l	d3,-(sp)
		move.w	d2,-(sp)

		move.w	#-256,d1
		move.w	#512-1,d2
.loop
		move.w	d1,d3
		muls.w	d0,d3
		swap	d3
		move.b	d3,(a0)+
		addq.w	#1,d1
		dbra	d2,.loop

		move.w	(sp)+,d2
		move.l	(sp)+,d3
		rts


		;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
		; Init the filter (call at the start of a sample)
		; a0:   state structure base pointer (4 bytes)
		;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
init_filter
		clr.l	(a0)
		rts


		;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
		; Filter a buffer for one channel
		; d0.w: buffer size in longwords
		; a0:   source buffer pointer
		; a1:   dest buffer pointer
		; a2:   multiplier table base pointer (512 bytes)
		; a3:   state structure base pointer (4 bytes)
		;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
do_filter
		movem.l	a2-a3,d2-d3,-(sp)
		move.w	(a3),d2
		move.w	(a3,2),d3
		subq.w	#1,d0
		lea	(a2,256),a2
.loop
		rept	4

		moveq	#0,d1
		move.b	(a0)+,d1
		sub.w	d2,d1
		add.b	(a2,d1.w,0),d2

		moveq	#0,d1
		move.b	d2,d1
		sub.w	d3,d1
		add.b	(a2,d1.w,0),d3

		move.b	d3,(a1)+

		endr
		dbra	d0,.loop

		move.w	d2,(a3)
		move.w	d3,(a3,2)
		movem.l	(sp)+,a2-a3,d2-d3
		rts

Rather than re-calc the multiplier table every time the filter is adjusted, pre-calc a separate table for every possible filter cut-off. 256 possible cut-off frequencies requires 128KB RAM. The relationship between cut-off frequency and the constant is not linear, but I'm sure you can figure it out.

The code requires 68 CPU clock cycles per sample to execute on a stock A500. Fast enough to do 4 channels at 24kHz.

Faster Amigas could benefit from calculating at 16 or 32 bit precision. Then compand the output down to 8 bits and use the hardware volume control to restore dynamic range.


Back to Home