1
0
mirror of https://github.com/cc65/cc65.git synced 2024-07-10 23:29:05 +00:00
cc65/libsrc/cbm610/kbhit.s
cuz a7042ddbe4 Complete redesign of the CBM610 support.
Use wrappers to call the kernal in bank 15 instead of implementing kernal
functionality within the cc65 libs (eats performance but is much smaller and
simpler).
Improved startup/shutdown code allows a return to the system bank without
calling the BASIC cold start vector.


git-svn-id: svn://svn.cc65.org/cc65/trunk@2793 b7a2c559-68d2-44c3-8de9-860c34a00d81
2003-12-20 23:13:26 +00:00

31 lines
410 B
ArmAsm

;
; Ullrich von Bassewitz, 2003-12-20
;
; int kbhit (void);
;
.export _kbhit
.importzp sysp0
.import return0, return1
.include "cbm610.inc"
.proc _kbhit
ldx IndReg
lda #$0F
sta IndReg
ldy #$D1 ; Number of keys in kbd buffer
lda (sysp0),y
stx IndReg
bne L1
jmp return0
L1: jmp return1
.endproc