Add empty tape reader checking

This commit is contained in:
CrazyEttin 2022-08-15 17:19:57 +03:00
parent ec3cf94c06
commit 509c10cc70
1 changed files with 8 additions and 1 deletions

View File

@ -561,8 +561,15 @@ read: load r0, svstrt
load r0, svstrt + 1
store chrsto + 2, r0
;Read and store a character
;Read a character
chread: load r1, fffd
;Check for empty tape reader
xor r2, r2
brneq r1, r2, chrsto
load r1, sub
;Store a character
chrsto: store buffer + 100, r1
;Check for the save end