INDEX | ROMS





WiLL-i-ROMS mods


Disassembly of Defender sound ROM code and use of Heathkit ET-3400 to play the SYNTHs and change a parameter via the PIA B input binary bit data switches. Audio is typically sent from the 8 bit accumulator A to the PIA port A output address 0x8000 (arcade: 0x0400). PIA port B is the sound select port on pinball and arcade games, but here it is assigned to parameter changes via an 8 bit binary data switch. The digital audio sent out from the PIA is then piggy-backed onto a modified sound board's 1408 DAC chip and then amplified with the TDA2002 8 watt amplifier.

Link to the github repo of functioning .asm files.

Below is the Heathkit ET-3400 mpu system with added PIA and addressing logic and a modified system 7 sound board with RAM, ROM, MPU and PIA ICs removed:

Heathkit ET-4300 mpu and modified sound board









Williams Defender sound ROM code layout

The following table shows the current state of figuring out the code layout for the 2kb Sound Rom 15 (work in progress).

Definitions:
PARAM : modifier or setter of parameters that affect the sound
SYNTH : looping code with output writes to generate sound via the PIA/DAC
UTIL : similar to PARAM
IRQ : routine handles the interrupt request vectors that select the sound
CALCOS : calculate offset routine for both sound select and PARAM modifiers
NMI : non-masking interrupt routine to handle the test/reset button press
VWTAB : vector table (fdb) addresses for PARAM/SYNTH routines as per IRQ
VVECT : table (fcb) parameters for SYNTHs (7x 8 bit params and 1x 16 bit counter)
WAVFCB : waveform data called by SYNTHs or PARAMs
MOTVCT : Motorola vector table for IRQ, SWI, NMI, RESET

Addr Label F800 ORG F801 RESET F82A PARAM1 F83F SYNTH1 F88C PARAM2 F894 SYNTH2 F8CD SYNTH3 F913 PARAM3 F91C PARAM4 F923 PARAM5 F930 SYNTH4 F9A6 SYNTH5 F9D4 SYNTH6 F9F3 SYNTH7 FA44 PARAM6 FA48 PARAM7 FA84 PARAM8 FA89 PARAM9 FA9A SYNTH8 FB0A UTIL1 FB1E PARAM10 FB24 PARAM11 FB34 UTIL2 FB49 PARAM12 FB71 PARAM13 FBE7 SYNTH9 FC21 PARAM14 FC4B PARAM15 FC56 PARAM16 FC65 PARAM17 FC75 PARAM18 FC87 PARAM19 FCB6 IRQ FD0E IRQ2 FD21 CALCOS FD2F NMI FD58 VWTAB FD76 VVECT FDAA WAVFCB1 FE41 WAVFCB2 FE4D WAVFCB3 FEEC WAVFCB4 FF55 WAVFCB5 FFF8 MOTVCT





WiLL-i-ROMS mods code

Example code for SYNTH2:

****** Hardware data ****** Sound 6802/6808 board $0000 - $007F RAM $0400 - $0403 PIA $F800 - $FFFF ROM Accumulator A 8 bits Accumulator B 8 bits Index Register X 16 bits Program Counter PC 16 bits Stack Pointer SP 16 bits Status Register COSZAc 8 bits (Carry, Overflow, Sign, Zero, Aux Carry)(|1|1|Ac|1|S|Z|O|C|) ************************** ; SYNTH2 CODE - 08 Nov 2019 ; hack for Heathkit ET-3400 Audio Setup ; user RAM = 197 + 256 bytes = 453 ; addr 0000 - 00C4 and 0100 - 01FF ; using PIA addr 8000 (not 0400) ; mpu clock speed is default/low (quoted as 0.5 MHz), expecting ~894750 cycles per second ; working, looping one shot with ramp up/down, pitch/frequency and duration params
;*************************************; ; Main loop scratch memory, default values ;*************************************;
0000 : 00 ; not used
; ~ RESERVED
0014 : 00 ;
0015 : 10 ; loop duration
0016 : 00 00 00 ; not used
0019 : C0 ; pitch/frequency start (add 1A into A)
001A : FE ; LFO to env, also change ramp down
001C : 00 ; end main loop mem
;*************************************; ;RESET INIT (POWER-ON) org 001D ;*************************************;
001D : 8E 01 FF lds #$01FF ; load SP with 01FFh
0020 : CE 80 00 ldx #$8000 ; load X with 8000h, PIA (DAC) addr
0023 : 6F 01 clr $01,x ; clear(00) addr X + 01h (8001, PIA DDR port A)
0025 : 6F 03 clr $03,x ; clear(00) addr X + 03h (8003, PIA DDR port B)
0027 : 6F 02 clr $02,x ; clear(00) addr X + 02h (8002, port B input)
0029 : 86 FF ldaa #$FF ; load A with FFh (1111 1111)
002B : A7 00 staa $00,x ; store A in addr X + 00h (8000, port A output)
002D : 86 3C ldaa #$3C ; load A with 3Ch(0011 1100)
002F : A7 01 staa $01,x ; store A in addr X + 01h (8001)
0031 : 86 37 ldaa #$37 ; load A with 37h(0011 0111)(28h 0010 1000)
0033 : A7 03 staa $03,x ; store A in addr X + 03h (8003)
;*************************************; ;IRQ main loop start ;*************************************;
0035 : B6 80 02 ldaa $8002 ;load A with PIA B
;*************************************; ;SYNTH2 - modified ; rem'd a bcc prior to com DAC ; rem'd an ldaa #$FE to store in 1A ;*************************************;
0038 : 97 1A staa $1A ;store A in addr 1A - def:0xFE LFO to env
003A : 86 C0 ldaa #$C0 ;load A immed 0xC0 (1100 0000) - pitch/frequency start
003C : C6 10 ldab #$10 ;load B immed 0x10 (0001 0000) - loop duration/cycles
003E : 20 00 bra $0040 ;branch next (+00)
0040 : 97 19 staa $19 ;store A in addr 19
0042 : 86 FF ldaa #$FF ;load A immed 0xFF (1111 1111)
0044 : B7 80 00 staa $8000 ;store A to DAC (SOUND)
0047 : D7 15 stab $15 ;store B in addr 15
; LOOP1
0049 : D6 15 ldab $15 ;load B with addr 15
; LOOP2
004B : 96 0A ldaa $0A ;load A with addr 0A
004D : 44 lsra ;logical shift right (0 into b7, b0 into C)
004E : 44 lsra ;logical shift right
004F : 44 lsra ;logical shift right
0050 : 98 0A eora $0A ;exclusive OR A with addr 0A into A
0052 : 44 lsra ;logical shift right
0053 : 76 00 09 ror $0009 ;rotate right addr 0009 (C into b7, b0 into C)
0056 : 76 00 0A ror $000A ;ror addr 000A
0059 : 73 80 00 com $8000 ;DAC invert (SOUND) complement 1s
; GOTO1
005C : 96 19 ldaa $19 ;load A with addr 19
; LOOP3
005E : 4A deca ;decrement A
005F : 26 FD bne $005E ;branch != 0 to LOOP3
0061 : 5A decb ;decrement B
0062 : 26 E7 bne $004B ;branch != 0 to LOOP2
0064 : 96 19 ldaa $19 ;load A with addr 19
0066 : 9B 1A adda $1A ;add A + addr 1A into A
0068 : 97 19 staa $19 ;store A into addr 19
006A : 26 DD bne $0049 ;branch !=0 to LOOP1
006C : 20 C7 bra $0035 ;branch always to IRQ
;*************************************; ;end ;*************************************;





Williams Boot Sound Mods

WiLL-i-ROMS fringe set album cover

Williams Boot sound assembly code (edited to 250 bytes) routines RESET, NMI, PARAM1, CALCOS, UTIL1, SYNTH1 on a 6800 and 6810 piggybacked to a System 7 DAC chip on a Williams sound board. Original parameters (p1-p7, ct): 28 01 00 08 81 02 00 FF FF are changed for each track with suitable values. (all tracks @ 320kbps)

Zip wav files 14mb