Poke Graphics

Developer(s): Len Harmon
Date: 1983
Type: Program
Platform(s): ZX81, TS 1000
Tags: Graphics

An etch-a-sketch that draws by POKEing a black square (code 128) into the display file instead of using PRINT. Line 10 finds the start of the display file from the system variable DF_CC. Steer with the arrow keys 5 (left), 6 (down), 7 (up) and 8 (right); each key moves one character position and leaves a trail. BREAK to exit.

The program needs a full display file (16K RAM), and it does not check the edges of the screen: if you move off the screen, the POKEs land outside the display, and this can crash the computer.

Published in Syntax April 1983 (Poke Graphics).

Related Articles

Speed up graphics and save memory by using POKE.

Image Gallery

Source Code

  10 LET A=PEEK 16398+256*PEEK 16399
  20 POKE A,128
  30 IF INKEY$="5" THEN LET A=A-1
  40 IF INKEY$="6" THEN LET A=A+33
  50 IF INKEY$="7" THEN LET A=A-33
  60 IF INKEY$="8" THEN LET A=A+1
  70 GOTO 20

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.