Code: Select all
Put: .MACRO chr ; character printing
LDA #chr ; tru ‘chr’
JSR PRINT
.ENDM
*=$1000
start:
CLC
Put 'A'
PRINT:
RTS
*=$fffc
.WORD startCode: Select all
Put: .MACRO chr ; character printing
LDA #chr ; tru ‘chr’
JSR PRINT
.ENDM
*=$1000
start:
CLC
Put 'A'
PRINT:
RTS
*=$fffc
.WORD startCode: Select all
Put: .MACRO chr ; character printing
LDA #chr ; tru ‘chr’
JSR PRINT
.ENDM
*=$1000
start:
CLC
Put 'A'
PRINT:
RTS
*=$fffc
.WORD startCode: Select all
put .macro .c ;print char
lda #.c ;.c is a local symbol, unknown...
jsr print ;outside of the macro invocation
.endmCode: Select all
.opt proc65c02,caseinsensitive,swapbinCode: Select all
puta: .MACRO A
.DB $DB,<.beta,>.beta
.RS A
.beta:
nop
.ENDMCode: Select all
puta: .MACRO A
.DB $DB,<.beta,>.beta
.RS A
.beta:
nop
.ENDMCode: Select all
blabla .MACRO
; If necessary, the macro should insert the appropriate number of NOPs here
STP
.DWORD $12345678 ;must be at ADDRESS /4
.ENDM Code: Select all
puta: .MACRO b
.a .=<* & $03
.IF .a==0
NOP
.ENDIF
.IF .a==2
NOP
NOP
NOP
.ENDIF
.IF .a==3
NOP
NOP
.ENDIF
.DB $DB,<.beta,>.beta
.RS b
.beta:
.ENDMCode: Select all
.rept {{4-{*@4}}*{{*@4}!=0}}
nop
.endr