fix cpeekc/cpeekcolor/cpeekrevers/cpeeks for atmos, replaces what is in #532
This commit is contained in:
22
libsrc/atmos/cpeekrevers.s
Normal file
22
libsrc/atmos/cpeekrevers.s
Normal file
@@ -0,0 +1,22 @@
|
||||
;
|
||||
; 2017-06-08, Greg King
|
||||
;
|
||||
; unsigned char cpeekrevers (void);
|
||||
;
|
||||
; Atmos version
|
||||
;
|
||||
|
||||
.export _cpeekrevers
|
||||
|
||||
.import setscrptr
|
||||
.importzp ptr2
|
||||
|
||||
|
||||
_cpeekrevers:
|
||||
jsr setscrptr ; Set ptr2 and .Y to the cursor's address
|
||||
lda (ptr2),y ; Get char
|
||||
and #$80 ; get reverse bit
|
||||
asl a
|
||||
tax ; ldx #>$0000
|
||||
rol a ; return boolean value
|
||||
rts
|
||||
Reference in New Issue
Block a user