mirror of
https://github.com/uffejakobsen/acme.git
synced 2024-06-15 12:29:32 +00:00
git-svn-id: https://svn.code.sf.net/p/acme-crossass/code-0/trunk@34 4df02467-bbd4-4a76-a152-e7ce94205b78
79 lines
711 B
Plaintext
79 lines
711 B
Plaintext
;ACME 0.95
|
|
|
|
!ifdef lib_6502_std_a !eof
|
|
lib_6502_std_a = 1
|
|
|
|
; labels and macros for plain 6502 processor
|
|
|
|
!address {
|
|
cpu_nmi = $fffa
|
|
cpu_reset = $fffc
|
|
cpu_irq = $fffe
|
|
}
|
|
|
|
; skip byte
|
|
!macro bit8 {
|
|
!byte $24 ; opcode of BIT $.. command
|
|
}
|
|
|
|
; skip word
|
|
!macro bit16 {
|
|
!byte $2c ; opcode of BIT $.... command
|
|
}
|
|
|
|
; increase 16-bit counter
|
|
!macro inc16 .t {
|
|
inc .t
|
|
bne +
|
|
inc .t + 1
|
|
+
|
|
}
|
|
|
|
; far branches
|
|
!macro bcc .t {
|
|
bcs +
|
|
jmp .t
|
|
+
|
|
}
|
|
!macro bcs .t {
|
|
bcc +
|
|
jmp .t
|
|
+
|
|
}
|
|
|
|
!macro beq .t {
|
|
bne +
|
|
jmp .t
|
|
+
|
|
}
|
|
|
|
!macro bne .t {
|
|
beq +
|
|
jmp .t
|
|
+
|
|
}
|
|
|
|
!macro bmi .t {
|
|
bpl +
|
|
jmp .t
|
|
+
|
|
}
|
|
|
|
!macro bpl .t {
|
|
bmi +
|
|
jmp .t
|
|
+
|
|
}
|
|
|
|
!macro bvc .t {
|
|
bvs +
|
|
jmp .t
|
|
+
|
|
}
|
|
|
|
!macro bvs .t {
|
|
bvc +
|
|
jmp .t
|
|
+
|
|
}
|