Hi My brain melted sometime ago and since then i've forgotten how to write an XA compliant routine that i will then copy to zero page.
The routine will contain branches and most likely some self-mod-code.
Any suggestions?
XA formatted Zero Page Routine
Something like that perhaps ?
Code: Select all
#define ZERO_START $50
.zero
*=ZERO_START
ZeroStart
.(
lda #23
sta $bb80
rts
.)
ZeroEnd
.text
CopyToZero
.(
ldx #ZeroEnd-ZeroStart
.loop
lda ZeroStart,x
sta ZERO_START,x
dex
bcc .loop
rts
.)