aboutsummaryrefslogtreecommitdiff
path: root/src-68k/sound
diff options
context:
space:
mode:
authorJavier Degirolmo2012-08-14 22:49:32 -0300
committerJavier Degirolmo2012-08-14 22:49:32 -0300
commit6ab75ecb612fbbe2ec939bd758bbbe620e6d5040 (patch)
tree8122e6eeeacf4912b439dc77e48ea30181b48c01 /src-68k/sound
parent416f24632deee748d4789982262063bda598a1ef (diff)
Renamed Echo Tester directory from src-68k to tester
Diffstat (limited to 'src-68k/sound')
-rw-r--r--src-68k/sound/bgms.68k38
-rw-r--r--src-68k/sound/echo.68k263
-rw-r--r--src-68k/sound/list.68k230
-rw-r--r--src-68k/sound/sfxs.68k26
4 files changed, 0 insertions, 557 deletions
diff --git a/src-68k/sound/bgms.68k b/src-68k/sound/bgms.68k
deleted file mode 100644
index 4069628..0000000
--- a/src-68k/sound/bgms.68k
+++ /dev/null
@@ -1,38 +0,0 @@
-;****************************************************************************
-; BGM_Test
-; Generic BGM to test events
-;****************************************************************************
-
-BGM_Test:
- dc.b $FF
-
-;****************************************************************************
-; Some conversions
-;****************************************************************************
-
-BGM_Midnas:
- incbin "data/music/midnas.esf"
-BGM_Nelpel:
- incbin "data/music/nelpel.esf"
-BGM_Megajysays:
- incbin "data/music/megajysays.esf"
-BGM_Doomsday:
- incbin "data/music/doomsday.esf"
-
-;****************************************************************************
-; Several tests used for midi2esf
-;****************************************************************************
-
-BGM_PianoTest:
- incbin "data/music/test-piano.esf"
-BGM_SquSawTest2:
- incbin "data/music/test-squsaw-2ch.esf"
-BGM_SquSawTest1:
- incbin "data/music/test-squsaw-1ch.esf"
-BGM_PSGTest:
- incbin "data/music/test-psg.esf"
-BGM_DrumTest:
- incbin "data/music/test-drums.esf"
-BGM_FluteTest:
- incbin "data/music/test-flute.esf"
-
diff --git a/src-68k/sound/echo.68k b/src-68k/sound/echo.68k
deleted file mode 100644
index 1d02800..0000000
--- a/src-68k/sound/echo.68k
+++ /dev/null
@@ -1,263 +0,0 @@
-;****************************************************************************
-; Echo_Z80Request
-; Requests the Z80 bus
-;****************************************************************************
-
-Echo_Z80Request macro
- move.w #$100, ($A11100) ; Request Z80 bus
-@Echo_WaitZ80\@:
- btst.b #0, ($A11100) ; Did we get it yet?
- bne.s @Echo_WaitZ80\@ ; Keep waiting
- endm ; End of macro
-
-;****************************************************************************
-; Echo_Z80Release
-; Releases the Z80 bus
-;****************************************************************************
-
-Echo_Z80Release macro
- move.w #$000, ($A11100) ; Release Z80 bus
- endm ; End of macro
-
-;****************************************************************************
-; Echo_Z80Reset
-; Resets the Z80 and YM2612
-;****************************************************************************
-
-Echo_Z80Reset macro
- move.w #$000, ($A11200) ; Assert reset line
- rept $10 ; Wait until hardware resets
- nop ; ...
- endr ; ...
- move.w #$100, ($A11200) ; Release reset line
- endm ; End of macro
-
-;****************************************************************************
-; Echo_Init
-; Initializes Echo
-;
-; input a0.l ... Address of pointer list
-;****************************************************************************
-
-Echo_Init:
- movem.l d0/a0-a1, -(sp) ; Save registers
-
- Echo_Z80Reset ; May not work without this...
- Echo_Z80Request ; We need the Z80 bus
-
- move.b #$01, ($A01FFF) ; Command: load pointer list
-
- move.l a0, d0 ; Easier to manipulate here
- move.b d0, ($A01FFD) ; Store low address byte
- lsr.l #7, d0 ; Get high address byte
- lsr.b #1, d0 ; We skip one bit
- bset.l #7, d0 ; Point into bank window
- move.b d0, ($A01FFE) ; Store high address byte
- lsr.w #8, d0 ; Get bank byte
- move.w d0, d1 ; Parse 32X bit separately
- lsr.w #1, d1 ; Put 32X bit in place
- and.b #$7F, d0 ; Filter out unused bit from addresses
- and.b #$80, d1 ; Filter out all but 32X bit
- or.b d1, d0 ; Put everything together
- move.b d0, ($A01FFC) ; Store bank byte
-
- lea @Z80Program(pc), a0 ; Where Z80 program starts
- lea ($A00000), a1 ; Where Z80 RAM starts
- move.w #@Z80ProgSize-1, d0 ; Size of Z80 program (DBF adjusted)
-@LoadLoop: ; Go through all the program
- move.b (a0)+, (a1)+ ; Copy byte into Z80 RAM
- dbf d0, @LoadLoop ; Go for next byte
-
- Echo_Z80Reset ; Now reset for real
- Echo_Z80Release ; Let the Z80 go!
-
- movem.l (sp)+, d0/a0-a1 ; Restore registers
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo Z80 program
-; It should be located wherever Echo_ProgFile was defined
-;****************************************************************************
-
-@Z80Program: incbin "\Echo_ProgFile"
-@Z80ProgSize equ *-@Z80Program
- even
-
-;****************************************************************************
-; Echo_SendCommand
-; Sends an Echo command (no address parameter)
-;
-; input d0.b ... Echo command
-;****************************************************************************
-
-Echo_SendCommand:
- move.w d1, -(sp) ; Save register
-
- Echo_Z80Request ; We need the Z80 bus
-
-@Try:
- tst.b ($A01FFF) ; Check if Echo is ready
- beq.s @Ready ; Too busy?
- Echo_Z80Release ; Let Echo continue
- move.w #$FF, d1 ; Give it some time
- dbf d1, * ; ...
- Echo_Z80Request ; Get Z80 bus back
- bra.s @Try ; Try again
-
-@Ready:
- move.b d0, ($A01FFF) ; Write command ID
- Echo_Z80Release ; We're done with the Z80 bus
-
- move.w (sp)+, d1 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_SendCommandEx
-; Sends an Echo command (with address parameter)
-;
-; input d0.b ... Echo command
-; input a0.l ... Address parameter
-;****************************************************************************
-
-Echo_SendCommandEx:
- movem.l d0-d1, -(sp) ; Save register
-
- Echo_Z80Request ; We need the Z80 bus
-
-@Try:
- tst.b ($A01FFF) ; Check if Echo is ready
- beq.s @Ready ; Too busy?
- Echo_Z80Release ; Let Echo continue
- move.w #$FF, d1 ; Give it some time
- dbf d1, * ; ...
- Echo_Z80Request ; Get Z80 bus back
- bra.s @Try ; Try again
-
-@Ready:
- move.b d0, ($A01FFF) ; Write command ID
-
- move.l a0, d0 ; Easier to manipulate here
- move.b d0, ($A01FFD) ; Store low address byte
- lsr.l #7, d0 ; Get high address byte
- lsr.b #1, d0 ; We skip one bit
- bset.l #7, d0 ; Point into bank window
- move.b d0, ($A01FFE) ; Store high address byte
-
- lsr.w #8, d0 ; Get bank byte
- move.w d0, d1 ; Parse 32X bit separately
- lsr.w #1, d1 ; Put 32X bit in place
- and.b #$7F, d0 ; Filter out unused bit from addresses
- and.b #$80, d1 ; Filter out all but 32X bit
- or.b d1, d0 ; Put everything together
- move.b d0, ($A01FFC) ; Store bank byte
-
- Echo_Z80Release ; We're done with the Z80 bus
-
- movem.l (sp)+, d0-d1 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_PlaySFX
-; Plays a SFX
-;
-; input a0.l ... Pointer to SFX data
-;****************************************************************************
-
-Echo_PlaySFX:
- move.w d0, -(sp) ; Save register
- move.b #$02, d0 ; Command $02 = play SFX
- bsr Echo_SendCommandEx ; Send command to Echo
- move.w (sp)+, d0 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_StopSFX
-; Stops SFX playback
-;****************************************************************************
-
-Echo_StopSFX:
- move.w d0, -(sp) ; Save register
- move.b #$03, d0 ; Command $03 = stop SFX
- bsr Echo_SendCommand ; Send command to Echo
- move.w (sp)+, d0 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_PlayBGM
-; Plays a BGM
-;
-; input a0.l ... Pointer to BGM data
-;****************************************************************************
-
-Echo_PlayBGM:
- move.w d0, -(sp) ; Save register
- move.b #$04, d0 ; Command $04 = play BGM
- bsr Echo_SendCommandEx ; Send command to Echo
- move.w (sp)+, d0 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_StopBGM
-; Stops BGM playback
-;****************************************************************************
-
-Echo_StopBGM:
- move.w d0, -(sp) ; Save register
- move.b #$05, d0 ; Command $05 = stop BGM
- bsr Echo_SendCommand ; Send command to Echo
- move.w (sp)+, d0 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_ResumeBGM
-; Resumes BGM playback
-;****************************************************************************
-
-Echo_ResumeBGM:
- move.w d0, -(sp) ; Save register
- move.b #$06, d0 ; Command $06 = resume BGM
- bsr Echo_SendCommand ; Send command to Echo
- move.w (sp)+, d0 ; Restore register
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_GetStatus
-; Gets the current status of Echo
-;
-; output d0.w ... Echo status
-; Bit #0: SFX is playing
-; Bit #1: BGM is playing
-; Bit #15: command still not parsed
-;****************************************************************************
-
-Echo_GetStatus:
- moveq #0, d0
- Echo_Z80Request ; We need the Z80 bus
- move.b ($A01FF0), d0 ; Get the status flags
- tst.b ($A01FFF) ; Check if command still has to be parsed
- beq.s @NotBusy ; Any commands left to be parsed?
- bset.l #15, d0 ; If so, set the relevant flag
-@NotBusy:
- Echo_Z80Release ; Let the Z80 go!
- rts ; End of subroutine
-
-;****************************************************************************
-; Echo_ListEntry
-; Defines an entry in a pointer list
-;****************************************************************************
-
-Echo_ListEntry macro addr
- dc.b $80|((addr)>>8&$7F) ; High byte of address
- dc.b (addr)&$FF ; Low byte of address
- dc.b ((addr)>>15&$7F)|((addr)>>16&$80) ; Bank number
- endm
-
-;****************************************************************************
-; Echo_ListEnd
-; Ends a pointer list
-;****************************************************************************
-
-Echo_ListEnd macro
- dc.b $00 ; End of list mark
- even ; Just in case...
- endm
diff --git a/src-68k/sound/list.68k b/src-68k/sound/list.68k
deleted file mode 100644
index 10f7a42..0000000
--- a/src-68k/sound/list.68k
+++ /dev/null
@@ -1,230 +0,0 @@
-;****************************************************************************
-; PointerList
-; Pointer list used by Echo
-;****************************************************************************
-
-PointerList:
- Echo_ListEntry Instr_PSGFlat ; $00 [PSG] Flat PSG instrument
- Echo_ListEntry Instr_DGuitar ; $01 [FM] Distortion guitar
- Echo_ListEntry Instr_Snare ; $02 [PCM] Snare drum
- Echo_ListEntry Instr_Kick ; $03 [PCM] Bass drum (kick)
- Echo_ListEntry Instr_Strings ; $04 [FM] String ensemble
- Echo_ListEntry Instr_Bass ; $05 [FM] Standard bass
- Echo_ListEntry Instr_SoftPSG ; $06 [PSG] Soft PSG envelope
- Echo_ListEntry Instr_PianoPSG ; $07 [PSG] Piano PSG instrument
- Echo_ListEntry Instr_MidiPSG ; $08 [PSG] MIDI square lead
- Echo_ListEntry Instr_MidiPiano ; $09 [FM] MIDI piano
- Echo_ListEntry Instr_MidiLead1 ; $0A [FM] MIDI square lead
- Echo_ListEntry Instr_MidiLead2 ; $0B [FM] MIDI sawtooth lead
- Echo_ListEntry Instr_MidiFlute ; $0C [FM] MIDI flute
- Echo_ListEntry Instr_NepelPSG ; $0D [PSG] Nepel Four PSG instr.
- Echo_ListEntry Instr_MidiSynthBass ; $0E [FM] MIDI synth bass
- Echo_ListEntry Instr_MidiLead1F ; $0F [FM] MIDI square (filtered)
- Echo_ListEntry Instr_MidiLead2F ; $10 [FM] MIDI sawtooth (filtered)
- Echo_ListEntry Instr_Seashore ; $11 [PSG] Seashore
- Echo_ListEntry Instr_HitHat ; $12 [PSG] Hit-hat
- Echo_ListEntry Instr_PSGString ; $13 [PSG] PSG string
- Echo_ListEntry Instr_EGuitar ; $14 [FM] Electric guitar
- Echo_ListEnd
-
-;****************************************************************************
-; Instrument $00 [PSG]
-; Flat PSG instrument (no envelope)
-;****************************************************************************
-
-Instr_PSGFlat:
- dc.b $FE,$00,$FF
-
-;****************************************************************************
-; Instrument $01 [FM]
-; Distortion guitar
-;****************************************************************************
-
-Instr_DGuitar:
- incbin "data/fm/dguitar.eif"
-
-;****************************************************************************
-; Instrument $02 [PCM]
-; Snare drum
-;****************************************************************************
-
-Instr_Snare:
- incbin "data/pcm/snare.ewf"
-
-;****************************************************************************
-; Instrument $03 [PCM]
-; Bass drum
-;****************************************************************************
-
-Instr_Kick:
- incbin "data/pcm/kick.ewf"
-
-;****************************************************************************
-; Instrument $04 [FM]
-; String ensemble
-;****************************************************************************
-
-Instr_Strings:
- incbin "data/fm/string.eif"
-
-;****************************************************************************
-; Instrument $05 [FM]
-; Standard bass
-;****************************************************************************
-
-Instr_Bass:
- incbin "data/fm/bass.eif"
-
-;****************************************************************************
-; Instrument $06 [PSG]
-; "Soft" PSG envelope
-;****************************************************************************
-
-Instr_SoftPSG:
- dc.b $00,$01,$01,$02,$02,$02,$03,$03,$03,$03,$FE,$04,$FF
-
-;****************************************************************************
-; Instrument $07 [PSG]
-; Piano-like PSG instrument
-;****************************************************************************
-
-Instr_PianoPSG:
- dc.b $00,$01,$02,$03,$04,$04,$05,$05
- dc.b $06,$06,$07,$07,$08,$08,$08,$08
- dc.b $09,$09,$09,$09,$0A,$0A,$0A,$0A
- dc.b $0B,$0B,$0B,$0B,$0C,$0C,$0C,$0C
- dc.b $0C,$0C,$0C,$0C,$0D,$0D,$0D,$0D
- dc.b $0D,$0D,$0D,$0D,$0E,$0E,$0E,$0E
- dc.b $0E,$0E,$0E,$0E,$FE,$0F,$FF
-
-;****************************************************************************
-; Instrument $08 [PSG]
-; MIDI square wave instrument (GM81)
-;****************************************************************************
-
-Instr_MidiPSG:
- dc.b $00,$01,$02,$FE,$03,$FF
-
-;****************************************************************************
-; Instrument $09 [FM]
-; MIDI acoustic piano (GM01)
-;****************************************************************************
-
-Instr_MidiPiano:
- incbin "data/fm/piano.eif"
-
-;****************************************************************************
-; Instrument $0A [FM]
-; MIDI square wave instrument (GM81)
-;****************************************************************************
-
-Instr_MidiLead1:
- incbin "data/fm/square.eif"
-
-;****************************************************************************
-; Instrument $0B [FM]
-; MIDI sawtooth wave instrument (GM82)
-;****************************************************************************
-
-Instr_MidiLead2:
- incbin "data/fm/saw.eif"
-
-;****************************************************************************
-; Instrument $0C [FM]
-; MIDI flute instrument (GM74)
-;****************************************************************************
-
-Instr_MidiFlute:
- incbin "data/fm/flute.eif"
-
-;****************************************************************************
-; Instrument $0D [PSG]
-; Nepel Four PSG instrument
-;****************************************************************************
-
-Instr_NepelPSG:
- dc.b $05,$06,$FE,$07,$FF
-
-;****************************************************************************
-; Instrument $0E [FM]
-; MIDI synth bass (GM39)
-;****************************************************************************
-
-Instr_MidiSynthBass:
- incbin "data/fm/ebass.eif"
-
-;****************************************************************************
-; Instrument $0F [FM]
-; MIDI square wave instrument (GM81) (filtered)
-;****************************************************************************
-
-Instr_MidiLead1F:
- incbin "data/fm/squaref.eif"
-
-;****************************************************************************
-; Instrument $10 [FM]
-; MIDI sawtooth wave instrument (GM82) (filtered)
-;****************************************************************************
-
-Instr_MidiLead2F:
- incbin "data/fm/sawf.eif"
-
-;****************************************************************************
-; Instrument $11 [PSG]
-; Seashore
-;****************************************************************************
-
-Instr_Seashore:
- dcb.b 4, $0E
- dcb.b 4, $0D
- dcb.b 4, $0C
- dcb.b 4, $0B
- dcb.b 4, $0A
- dcb.b 4, $09
- dcb.b 4, $08
- dcb.b 4, $07
- dcb.b 4, $06
- dcb.b 60, $05
- dcb.b 4, $06
- dcb.b 4, $07
- dcb.b 4, $08
- dcb.b 4, $09
- dcb.b 4, $0A
- dcb.b 4, $0B
- dcb.b 4, $0C
- dcb.b 4, $0D
- dcb.b 4, $0E
- dc.b $FE, $0F, $FF
-
-;****************************************************************************
-; Instrument $12 [PSG]
-; Hit-hat
-;****************************************************************************
-
-Instr_HitHat:
- dc.b $00, $01, $02, $04, $06, $08, $0C
- dc.b $FE, $0F, $FF
-
-;****************************************************************************
-; Instrument $13 [PSG]
-; PSG string
-;****************************************************************************
-
-Instr_PSGString:
- dcb.b 4, $0E
- dcb.b 4, $0D
- dcb.b 4, $0C
- dcb.b 4, $0B
- dcb.b 4, $0A
- dcb.b 4, $09
- dcb.b 4, $08
- dc.b $FE, $07, $FF
-
-;****************************************************************************
-; Instrument $14 [FM]
-; Electric guitar
-;****************************************************************************
-
-Instr_EGuitar:
- incbin "data/fm/eguitar.eif"
-
diff --git a/src-68k/sound/sfxs.68k b/src-68k/sound/sfxs.68k
deleted file mode 100644
index ac969dc..0000000
--- a/src-68k/sound/sfxs.68k
+++ /dev/null
@@ -1,26 +0,0 @@
-;****************************************************************************
-; SFX_Test
-; Generic SFX to test events
-;****************************************************************************
-
-SFX_Test:
- dc.b $E8,$E9,$EA
- dc.b $28,$00,$48,$00
- dc.b $29,$08,$49,$00
- dc.b $2A,$08,$4A,$00
-
- dc.b $08,12,$09,24,$0A,36, $FE,$10, $18,$19,$1A, $FE,$10
- dc.b $08,12,$09,24,$0A,36, $FE,$10, $18,$19,$1A, $FE,$10
- dc.b $08,14,$09,26,$0A,38, $FE,$10, $18,$19,$1A, $FE,$10
-
- dc.b $FF
-
-;****************************************************************************
-; SFX_Beep
-; Beep SFX
-;****************************************************************************
-
-SFX_Beep:
- dc.b $EA,$1A,$4A,$00,$2A,$00
- dc.b $0A,2*36,$FE,4
- dc.b $FF