small keyboard reading fixes

This commit is contained in:
FeralChild64 committed 2019-10-17 17:41:50 +02:00
1 parent a7cb7eb52e
commit f9e3b57a79
14 files changed
+57 -26

No files matched your search

+30
View File
@@ -0,0 +1,30 @@
//
// Well-known Kernal routine, described in:
//
// - http://sta.c64.org/cbm64kbdfunc.html
//
read_kb_buf:
// Check for a key
lda NDX
bne !+
// Nothing in keyboard buffer to read
sec
rts
!:
lda KEYD
pha
phy_trash_a
jsr pop_keyboard_buffer
ply_trash_a
pla
clc
rts