1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-23 19:29:37 +00:00
cc65/libsrc/cbm610/pokesys.s
uz 53dd513176 This commit was generated by cvs2svn to compensate for changes in r2,
which included commits to RCS files with non-trunk default branches.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3 b7a2c559-68d2-44c3-8de9-860c34a00d81
2000-05-28 13:40:48 +00:00

39 lines
652 B
ArmAsm

;
; Ullrich von Bassewitz, 29.09.1998
;
; void pokebsys (unsigned Addr, unsigned char Val);
; void pokewsys (unsigned Addr, unsigned Val);
.export _pokebsys, _pokewsys
.import popsreg
.importzp sreg, tmp1
.include "zeropage.inc"
_pokebsys:
jsr popsreg ; Get the address
ldx IndReg
ldy #$0F
sty IndReg ; Switch to the system bank
ldy #$00
sta (sreg),y
stx IndReg
rts
_pokewsys:
stx tmp1 ; Save high byte
jsr popsreg ; Get the address
ldx IndReg
ldy #$0F
sty IndReg ; Switch to the system bank
ldy #$00
sta (sreg),y
iny
lda tmp1
sta (sreg),y
stx IndReg
rts