ATARI
TEXTDUMP
TEXTDUMP
Ralph Johnson
Here's a short, simple utility that quickly dumps a GRAPHICS 0 screen to a printer. It works with all 400/800, XL, and XE computers.
I've always wanted the capability to dump a copy of a text screen to my printer. I also wanted this capability available from BASIC. My efforts to find such a program were fruitless. So, the only solution was to write one myself.
There were several requirements I established: 1) It should be fast-written in machine language. 2) It should sit in a relatively safe location in memory, surviving system resets. 3) It should always be ready to do its job, whether called in direct mode or from within a program. 4) It should be easy to use.
The result is "Atari Textdump." You can make your own copy of Textdump by typing in the program listing below. It creates an AUTORUN.SYS file on disk that automatically loads Textdump into memory page 6 (address 1536) when you boot the system from that disk. To call the routine, make sure your printer is online and enter this statement:
A=USR(1536)
This works in both direct mode or within a program.
If you don't have a disk drive, or if you don't want Textdump to load as an AUTORUN.SYS file, delete lines 10-1000 in Program 1 and substitute this new line 10:
10 FOR A=1536 TO 1724:READ B:POKE
A,B:NEXT A
Again, you can call Textdump as described above in either direct or program mode. You can also convert this version of the program into a module for use in your own programs.
If you like, you can modify Textdump to print a smaller portion of the GRAPHICS 0 screen. Simply POKE the desired number of rows you want to dump into memory location 1613.
For instructions on entering this listing, please refer to "COMPUTEI's Guide to Typing In Programs" in this issue of COMPUTE!.
Atari Textdump
CL 10 CLOSE #1
PB 20 OPEN #1,8,0,"D:AUTORUN
.SYS"
EJ 30 FOR A=1 TO 6:READ B:PR
INT #1;CHR$(B);:NEXT A
IA 40 FOR A=1536 TO 1724:REA
D B:PRINT #1;CHR$(B);:
NEXT A
CP 50 CLOSE #1
CM 1000 DATA 255,255,0,6,188
,6
DG 1002 DATA 104,162,80,169,
3,157,66,3,169,8,157
,74,3,169,144
IN 1003 DATA 157,68,3,169,6,
157,69,3,169,0
GF 1004 DATA 141,143,6,157,7
3,3,169,255,157,72,3
,32,86,228,165
KC 1005 DATA 88,133,203,165,
89,133,204,162,0,160
BF 1006 DATA 0,24,177,203,10
5,32,157,147,6,232,2
4,165,203,105
EP 1007 DATA 1,133,203,165,2
04,105,0,133,204,173
,143
OB 1008 DATA 6,201,24,240,52
,224,40,240,4,224,40
,208,217,169
OL 1009 DATA 155,157,147,6,2
38,143,6,162,80,169,
9
NP 1010 DATA 157,66,3,169,14
7,157,68,3,169,6,157
,69,3,169,0
OL 1011 DATA 157,73,3,169,25
5,157,72,3,32,86
EJ 1012 DATA 228,162,0,224,0
,240,173,162,80,169,
12,157,66,3,32
BE 1013 DATA 86,228,96,0,80,
58,155,090,0
LA 1014 DATA 0,0,0,0,0,0,0,0
,0,0,0,0,0,0,0,0,0,0
,0,0,0,0,0,0,0
CI 1015 DATA 0,0,0,0,0,0,0,0
,0,0,0,0,155,0