diff options
author | B. Watson <yalhcru@gmail.com> | 2016-02-17 23:47:59 -0500 |
---|---|---|
committer | B. Watson <yalhcru@gmail.com> | 2016-02-17 23:47:59 -0500 |
commit | 3abf7993ce2d2deb1c0596f3404b2bfa27324564 (patch) | |
tree | 67b4cb01fb3b303a14edf41f6ffa56243d33af3a /conio/cgetc.s | |
parent | b2f7604ac51db075201ea0aa40d002d3d5e7e071 (diff) | |
download | taipan-3abf7993ce2d2deb1c0596f3404b2bfa27324564.tar.gz |
make the cursor behave *much* better, via custom conio function
Diffstat (limited to 'conio/cgetc.s')
-rw-r--r-- | conio/cgetc.s | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/conio/cgetc.s b/conio/cgetc.s new file mode 100644 index 0000000..d1ae705 --- /dev/null +++ b/conio/cgetc.s @@ -0,0 +1,31 @@ +; +; Christian Groessler, November-2002 +; +; get a char from the keyboard +; char cgetc(void) +; + + .include "atari.inc" + .export _cgetc + .import KEYBDV_handler + .import cursor,mul40 + +_cgetc: + lda #12 + sta ICAX1Z ; fix problems with direct call to KEYBDV +.ifdef __ATARIXL__ + jsr KEYBDV_handler +.else + jsr @1 +.endif + ldx #0 + rts + +.ifndef __ATARIXL__ +@1: lda KEYBDV+5 + pha + lda KEYBDV+4 + pha + rts +.endif + |