Upgraded the cx16 library to the Commander X16 Kernal ROM's prerelease 39.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
;
|
||||
; 2020-01-08, Greg King
|
||||
; 2022-03-28, Greg King
|
||||
;
|
||||
; unsigned char kbhit (void);
|
||||
; /* Returns non-zero (true) if a typed character is waiting. */
|
||||
@@ -7,14 +7,11 @@
|
||||
|
||||
.export _kbhit
|
||||
|
||||
.include "cx16.inc"
|
||||
.import KBDBUF_PEEK
|
||||
|
||||
|
||||
.proc _kbhit
|
||||
ldy VIA1::PRA ; (KEY_COUNT is in RAM bank 0)
|
||||
stz VIA1::PRA
|
||||
lda KEY_COUNT ; Get number of characters
|
||||
sty VIA1::PRA
|
||||
tax ; High byte of return (only its zero/nonzero ...
|
||||
jsr KBDBUF_PEEK
|
||||
txa ; Low byte of return (only its zero/nonzero ...
|
||||
rts ; ... state matters)
|
||||
.endproc
|
||||
|
||||
Reference in New Issue
Block a user