Maximize Display File for MC

Author(s): John Guineau
Publication: Syntax
Pub Details: Syntax/Syntax ZX80 v3 n9 (Volume 3, Issue 9)
Date: September 1982
Pages: 5-6

I upgraded my ZX81 to 2K of RAM. Lately I have been interested in programming machine code displays. The problem is that since my machine has only 2K RAM it always sets up a minimal display file. (See ch.27 p.129 in the BASIC manual.) To do any kind of MC display you cannot have a minimal display file. I used to use a short routine that would PLOT a line up the right side of the screen. This “opened” the display and allowed a MCD. This was slow and tiresome to do.

I remembered the BASIC manual states that if you had more memory you could POKE RAMTOP lower than 3.25K to fool CLS into setting up a minimal display file. So I figured why not go the other way, that is, POKE RAMTOP higher than 3.25K to fool CLS into a full display. It worked! I have used my computer for a while this way and no crashes or problems whatsoever.

The procedure for POKEing RAMTOP is somewhat different than the manual states: once you power up, POKE 16389,78 and then CLS. Wait for a moment and voila, cursor and a full display. (To verify this, try POKE 16520,6.)

Remember, a full display will occupy 793 bytes of RAM. This may be no good for 1K machines. Also if you execute a NEW you must re-POKE RAMTOP to get a full display again. You can switch between minimal or full display file by POKEing RAMTOP at any time during programming. I use POKE 16389,72 for a minimal display and POKE 16389,78 for a full display.