1
0
mirror of https://github.com/cc65/cc65.git synced 2024-11-19 06:31:31 +00:00
cc65/libsrc/creativision/psg.s
Greg King af3d4581d3 Moved Creativision's playsound() into a separate file.
It won't waste space in a cartridge if it isn't used.
2021-06-11 07:43:25 -04:00

31 lines
520 B
ArmAsm

; void __fastcall__ psg_outb (unsigned char b);
; void __fastcall__ psg_delay (unsigned char b);
; void psg_silence (void);
.export _psg_outb, _psg_silence, _psg_delay
.include "creativision.inc"
;* Let BIOS output the value.
_psg_outb := BIOS_POKE_PSG
_psg_silence := BIOS_QUIET_PSG
_psg_delay:
tay
l1: lda #200
l2: sbc #1
bne l2
lda #200
l3: sbc #1
bne l3
dey
bne l1
rts