diff --git a/games/peasant/ssi263_simple_speech.s b/games/peasant/ssi263_simple_speech.s index 01f58ad1..5ef7c120 100644 --- a/games/peasant/ssi263_simple_speech.s +++ b/games/peasant/ssi263_simple_speech.s @@ -44,9 +44,9 @@ ssi263_speech_init: lda #ssi263_speech_irq - sta $3ff + sta $ffff ; set defaults @@ -84,6 +84,8 @@ ssi263_speech_init: ssi263_speech_shutdown: sei + jsr ssi263_disable + rts @@ -195,6 +197,26 @@ no_oflo: speech_end: + jsr ssi263_disable + +end_interrupt: + + pla + tay ; restore Y + pla + tax ; restore X + + pla ; restore A + +interrupt_smc: +; lda $45 ; restore A (II+/IIe) + + plp ; restore flags + + rti ; return from interrupt + + +ssi263_disable: ; If at the end, turn everything off ; Toggle CTL while DR set to disable A/!R @@ -222,21 +244,7 @@ speech_end: ldx #VIA6522_IER2 jsr ssi263_write_chip -end_interrupt: - - pla - tay ; restore Y - pla - tax ; restore X - - pla ; restore A - -interrupt_smc: -; lda $45 ; restore A (II+/IIe) - - plp ; restore flags - - rti ; return from interrupt + rts speech_busy: .byte $00 speech_playing: .byte $00