aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--checkmem.s8
1 files changed, 6 insertions, 2 deletions
diff --git a/checkmem.s b/checkmem.s
index 06c7917..90d21db 100644
--- a/checkmem.s
+++ b/checkmem.s
@@ -21,6 +21,11 @@ msglen = * - msg - 1
S: .byte "S:",0
init:
+ lda RAMSIZ
+ cmp #$c0
+ php
+ sta RAMTOP
+
ldx #6*$10 ; CLOSE #6
lda #CLOSE
sta ICCOM,x
@@ -40,8 +45,7 @@ init:
sta ICBAH,x
jsr CIOV
- lda RAMTOP
- cmp #$c0
+ plp
bcc have_cart
; if ramtop is $c000 or higher, we're OK, just exit.