stop the printer. This will allow you to print to the end of the
sheet, and even beyond if you are not careful. The codes to con-
trol the paper-out detector, along with the other codes that we
have just learned are in the following table.
Table 5-1
Some miscellaneous commands
Function 1 Control code
Sound bell 1 CHRU7J
1 Master reset 1 (ESC) “a”
I Off line 1 CHRW
On line CHR$il
Paper-out detector off WC)
Paner-out detector on (ESC)
I Move mint head back one sDace I CHRW
Delete last character sent
Cancel text in print buffer
I Print “slash zero”
0
CHR$(127)
CHR$(24)
I (ESC) “-‘I 1
,
I Print “normal zero”
Immediate-print on
Immediate-print off
1 (ESC)’ “-“0
(ESC) “i”1
(ESC) “i”0
n Backspace, delete, and cancel text
Backspace (CHR$@)) “backs up” the printhead so that you
can print two characters right on top of each other. Each time
your printer receives a backspace it moves the printhead one
character to the left, instead of to the right. You can strike over
multiple letters by sending more than one backspace code.
Delete (CHR$(127)) also “backs up” one character, but then it
“erases” the previous character (it’s erased from your printer’s
buffer, not from the paper).
Cancel text (CHR$(24)) deletes all the text in the print buffer;
that is, in the line before the delete text command. Since your
printer prints one line of text at a time, only that line will be
deleted.
The following program shows how these codes works.
10 LPRINT "BACKSPACE DOES NOT";
20 LPRINT CHR$(8>;CHR$(8);CHR$(8);
30 LPRINT ~I=== WORK"
40 LPRINT "DELETE DOES NOT";
50 LPRINT CHR$(127);CHR$(127);CHR$(l27);