Implemented a one-character buffer for kbhit() and cgetc().

If kbhit() detects that a key is pressed, it fetches and
buffers the character. If cgetc() detects a buffered character,
this one is returned instead of fetching one with the PROM
routine.
This commit is contained in:
Stephan Mühlstrasser
2015-02-21 20:24:58 +01:00
parent b1969ac16a
commit 222668c016
5 changed files with 27 additions and 6 deletions

View File

@@ -7,7 +7,7 @@ SYMBOLS {
}
MEMORY {
# for size of ZP see runtime/zeropage.s and c1p/extzp.s
ZP: file = "", define = yes, start = $0002, size = $001A + $0004;
ZP: file = "", define = yes, start = $0002, size = $001A + $0005;
RAM: file = %O, define = yes, start = %S, size = __HIMEM__ - __STACKSIZE__ - %S;
}
SEGMENTS {