AppleIIAsm-Collection/source/disk20_minidisk_A/T.SUBT16.SUB.MIN
nathanriggs 82d0e74c1a 0.3.1 updates
some minor bugfixes, directory shuffling, added demo and utility disks
2019-01-26 21:02:17 -05:00

32 lines
629 B
Plaintext

SUBT16
PLA
STA RETADR
PLA
STA RETADR+1
PLA
STA :SUBT
PLA
STA :SUBT+1 ; SUBTRAHEND
PLA
STA :MINU
PLA
STA :MINU+1 ; MINUEND
LDA :MINU
SEC
SBC :SUBT
TAY ; LOW BYTE
STY RETURN
LDA :MINU+1
SBC :SUBT+1
TAX ; HIGH BYTE
STX RETURN+1
LDA #2
STA RETLEN
LDA RETADR+1
PHA
LDA RETADR
PHA
RTS
:MINU DS 2
:SUBT DS 2