From 94f83ea43930ead4e5dab95e0b0a930d3722972a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Stephan=20M=C3=BChlstrasser?= Date: Thu, 12 Feb 2015 21:29:19 +0100 Subject: [PATCH] Replace zeropage variable with standard tmp variable. --- cfg/osic1p.cfg | 2 +- libsrc/osic1p/cgetc.s | 5 +++-- libsrc/osic1p/extzp.inc | 2 +- libsrc/osic1p/extzp.s | 3 +-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/cfg/osic1p.cfg b/cfg/osic1p.cfg index 4771639a6..10ce827fd 100644 --- a/cfg/osic1p.cfg +++ b/cfg/osic1p.cfg @@ -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 + $0005; + ZP: file = "", define = yes, start = $0002, size = $001A + $0004; RAM: file = %O, define = yes, start = %S, size = __HIMEM__ - __STACKSIZE__ - %S; } SEGMENTS { diff --git a/libsrc/osic1p/cgetc.s b/libsrc/osic1p/cgetc.s index b5a519667..ecd53b8d7 100644 --- a/libsrc/osic1p/cgetc.s +++ b/libsrc/osic1p/cgetc.s @@ -6,6 +6,7 @@ .include "osic1p.inc" .include "extzp.inc" + .include "zeropage.inc" ; Input routine from 65V PROM MONITOR, show cursor if enabled _cgetc: @@ -13,7 +14,7 @@ _cgetc: beq nocursor ldy CURS_X lda (SCREEN_PTR),y ; fetch current character - sta CURS_SAV ; save it + sta tmp1 ; save it lda #$A1 ; full white square sta (SCREEN_PTR),y ; store at cursor position nocursor: @@ -21,7 +22,7 @@ nocursor: pha ; save retrieved character lda cursor ; was cursor on? beq nocursor2 - lda CURS_SAV ; fetch saved character + lda tmp1 ; fetch saved character ldy CURS_X sta (SCREEN_PTR),y ; store at cursor position nocursor2: diff --git a/libsrc/osic1p/extzp.inc b/libsrc/osic1p/extzp.inc index 4aab34ff9..06498d1a6 100644 --- a/libsrc/osic1p/extzp.inc +++ b/libsrc/osic1p/extzp.inc @@ -4,4 +4,4 @@ ; ------------------------------------------------------------------------ - .globalzp CURS_X, CURS_Y, CURS_SAV, SCREEN_PTR + .globalzp CURS_X, CURS_Y, SCREEN_PTR diff --git a/libsrc/osic1p/extzp.s b/libsrc/osic1p/extzp.s index 95f9394dc..e54e2b306 100644 --- a/libsrc/osic1p/extzp.s +++ b/libsrc/osic1p/extzp.s @@ -13,8 +13,7 @@ CURS_X: .byte 0 CURS_Y: .byte 0 -CURS_SAV: .byte 0 SCREEN_PTR: .res 2 -; size 5 +; size 4 ; Adjust size of this segment in osic1p.cfg if the size changes -- 2.39.5