Thread: Zx81
View Single Post
Old 10th Apr 2020, 10:00 pm   #236
julie_m
Dekatron
 
Join Date: May 2008
Location: Derby, UK.
Posts: 7,735
Default Re: Zx81

I remember someone created a VERIFY routine for the ZX81, but I'm afraid any copy I had is long since gone by now. The code simply sat in the usual REM statement in the first line of the program, and a successful SAVE could be VERIFYed by evaluating USR 16514.

It shouldn't actually be very hard to recreate, with access to the ZX81 ROM disassembly. You would have to base it on the LOAD routine in the ZX81 ROM; but instead of storing the byte read from tape into memory, just CP it against the byte at that location. Note the first few bytes of the file are system state, and could have changed since the program was SAVEd! It should be obvious from the code what is what. You can bomb out with an error code straight away in the event of a mismatch, or signal no error if you made it all the way to the end of the file.

If a 1K invaders game is going to be possible, you'll have to use nearly all the available RAM for the screen display and so pull optimisations like increasing the score in place in display memory and stomping on anything you aren't going to drop back to BASIC and need again.
__________________
If I have seen further than others, it is because I was standing on a pile of failed experiments.
julie_m is offline