Peeker

Author(s): Gene G. Buza
Publication: Synchro-Sette
Pub Details: Synchro-Sette v2 n11 (Volume 2, Issue 11)
Date: December 1983
Pages: 14
Peeker heading art, hand at a peephole
Peeker heading art, hand at a peephole

– PROGRAMS TO EXAMINE MEMORY

Here are two short programs that allow you to examine the ROM and RAM memory locations of the 1000 and 2000 series computers. They start by asking you for the STARTING ADDRESS and then display the contents of that memory location and the next 21 locations.

The left column represents the address in decimal, the middle column represents the CODE number residing in that address and the right column represents the character that the CODE represents. If the CODE falls into an area that does not define a character or keyboard command or function, the right column will receive a blank space, otherwise the program might bomb.

The memory addresses start with ROM routines, then RAM information that is directed by ROM. This is followed by the program in memory. Then comes the screen memory map and finally the variables.

If you are scanning the screen or variables area, you may notice that the CODE character may not coincide with the CODE number. This is because it has changed in the small time that it took to write them onto the screen.

Attach this program to a program you have and scan the program memory area to see exactly how BASIC interprets a listing. The program lines are after the CODE for ENTER (118 on the 1000 and 13 on the 2068). Make sure you renumber it so that it doesn’t interfere with existing program lines.

TS-1000 VERSION

 10 SLOW
100 CLS
110 PRINT " INPUT STARTING ADDRESS ::"
120 INPUT SA
130 FAST
140 LET A=0
150 LET S=SA
160 SCROLL
170 PRINT S;TAB 8;PEEK S;TAB 16;
180 IF PEEK S<67 OR PEEK S>128 AND PEEK S<>195 THEN PRINT CHR$ PEEK S
190 LET A=A+1
200 LET S=S+1
210 IF A=22 THEN GOTO 300
220 GOTO 150
300 PAUSE 40000
310 CLS
320 LET A=0
330 GOTO 160

TS-2068 VERSION

100 CLS
110 INPUT " INPUT STARTING ADDRESS :::";SA
120 LET A=0: LET S=SA
130 PRINT S;TAB 8;PEEK S;TAB 16;
140 IF PEEK S<33 THEN PRINT : GO TO 160
150 PRINT CHR$ PEEK S
160 LET A=A+1: LET S=S+1
170 GO TO 130

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