Unfortunately, this process is also different for each computer system. We’ll give the procedure for a couple of systems here; if your system is neither of them, use the procedure as a model. Consult your computer’s manual to determine if you can do the same on your system.

A fourth approach is to change the printer driver program in your system. This requires a knowledge of machine language and of the way your computer works. If you don’t have this knowledge, your computer dealer may be able to help you or suggest someone who can.

We show a sample printer driver below (following the examples of POKEing codes). The idea is to pass the codes issued by a BASIC program directly to the printer.

POKEing codes

The TRS-80™ Model I version of the CHR$ function does not correctly pass on the values of 0, 10, 11, and 12. Zero is a particular problem as it is very important to the ESCape codes of the LX-80 printer.

These codes can be sent directly to the printer by POKEing them to a special memory location where they are immediately forwarded to the printer. The format is:

POKE 14312, N

where N is the decimal value of the code you wish to send to the printer. This works fine as long as the printer is ready to receive the data when you are ready to send it. On the Model I, the printer’s readiness is assured if location 14312 contains a decimal 63.

It is best to first test to see if the printer is ready with:

100 IF I’E:RK( 1431%)<>63 THEN 100

This puts the program into a continuous loop until the printer is ready to receive data. If data is sent while the printer is “out to lunch,” it will be lost.

To show how similar these commands can be from system to system, here is the same concept implemented on the Apple® II Plus:

100 IF PEEK(49601)>127 ‘I’fIEN 100

200 POKE 49296, N

F-9