From 874929a0859db895bbf521e4a4b88180ff0313ca Mon Sep 17 00:00:00 2001 From: Kelvin Sherlock Date: Wed, 14 Apr 2021 22:53:46 -0400 Subject: [PATCH] use the power of external constants to generate a block count. --- boot.S | 5 +++-- vt52.S | 7 +++++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/boot.S b/boot.S index 73bb2b4..883ea05 100644 --- a/boot.S +++ b/boot.S @@ -10,7 +10,7 @@ * org $0800 ORG equ $6000 -MAX_BLOCK equ 6 +*MAX_BLOCK equ 6 SLOT equ $00 @@ -20,6 +20,7 @@ BUFFER equ $44 BLOCK equ $46 ext main + ext MAXBLOCKS boot mx %11 @@ -86,7 +87,7 @@ boot inc BUFFER+1 inc BUFFER+1 lda BLOCK - cmp #MAX_BLOCK+1 + cmp #MAXBLOCKS bcc :read bra :ok diff --git a/vt52.S b/vt52.S index bdc2fbe..9a04ab0 100644 --- a/vt52.S +++ b/vt52.S @@ -4,6 +4,9 @@ xc rel + +START equ * + * vt52 emulator. * not supported - graphics, screen hold. * @@ -834,6 +837,10 @@ cursor_int rtl +END equ * +MAXBLOCKS equ END-START+511/512+2 + ent MAXBLOCKS + * lst on * sym on sav vt52.L