There are easier ways of dumping your screen
.. and ERIC CRISP knows one of them
OUR friendly Editor walked up to me the other day and stated:
"I want to dump my screen!". "Fine", I responded,
"the tip's just down the road".
"No!" he said, "I want to dump it on the printer".
"Won't the printer get its ribbon squashed?"
"Idiot!" he screamed, "I want to be able to play
a game like Asteroid Miner and then dump the screen onto a printer!"
"Ah!" I sighed, "you want a program that responds
to a particular key and saves the screen display even though another
program was running at the time, so that the display can be dumped
to a printer later - probably with that superb screen dump we
featured in the January issue".
"Yes", wept our weary Editor.
A few hours later his dream had come true in the form of the
two programs listed on this page.
Program I is in assembler and contains three separate routines.
The set interrupt program (lines 40 to 140) changes the IRQ
vector to include the key test routine in the interrupt.
The key test routine (lines 180 to 300) tests to see if the
_ key has been pressed.
If it has not been pressed it returns to the normal interrupt
If it was pressed, the return from interrupt address on the
stack is altered before returning to the normal interrupt handling
At the end of the interrupt control is transferred to the loader
routine instead of the program being run when the interrupt occurred.
The loader routine (lines 320 to 540) sets up a zero text window,
clears the buffers, sets up KEY0, puts function key 0 into the
keyboard buffer and executes a *BASIC command.
Data for KEY0 and *BASIC is on lines 570 and 590 and the CALL
on the last line calls up the set interrupt routine.
Program II, which is "chained" in by the loader program,
is in Basic and simply *SAVE s the whole of a Mode 2 screen onto
disc. At this point it is advisable to press the Break key to
reset the pointers and variables in memory.
The screen display can be loaded back into memory by *LOAD "SCREEN".
If this is done from within a screen dump program, it is possible
to then dump this to a printer.
This package was written for a disc system and will not work
on a tape-only system.
Care was taken in fitting the program into areas of memory that
are not generally used by games programs -part of the cassette
filing system used for the BPUT and BGET from &380 to &3AF,
and the printer buffer from &880 to &8BD.
If the program being used accesses these areas as well a system
crash is almost certain.
The area of memory used from &900 for the set interrupt
rountine is only used for initialisation and can be safely overwritten.
The key chosen to initiate the screen save is not normally used
in games and it will be all right in most cases. If a different
key is required then the CMP instruction on line 190 of the key
test routine can be changed.
The number &A8 (168 in decimal) for key "_" is
127+41, where 41 is the negative inkey value shown as -41 on page
275 of the User Guide.
To use this utility, simply save both programs on a disc. Make
sure the Basic program is called "SCDUMP". Load the
assembler program and run it.
The computer is then ready to receive the game program or whatever
it is. This can be on either tape or disc.
When the game is running, press the chosen key and the screen
should be saved as it stands as "SCREEN" on the disc.
*RENAME it as necessary.
The utility may not work if the other program changes the interrupt
or uses the same areas of memory.
10 *SAVE"SCREEN"3000 8000
20 VDU 6
30 MODE 7
40 PRINT "SCREEN SAVED"
50 PRINT "DO NOT SAVE ANOTHER SCREEN ON THIS DISC UNLESS
YOU RENAME THIS SCREEN DUMP OR IT WILL BE OVERWRITTEN"
60 PRINT "THE SCREEN DUMP IS CALLED 'SCREEN'. TO RELOAD THE
SCREEN TYPE :- *LOAD SCREEN"