Star Micronics NP-IO Printer User Manual


 
L
71
n Printing characters in the control code area
When you refer the Appendix C, you’ll find many characters
are printed in the control code area. (Remember that the low-
order control codes are the ASCII codes 0 through 31 plus 127,
and the high-order control codes are 128 through 159 plus 255.)
These codes don’t normally print characters on paper, rather
they cause the printer to change modes. To make them print as
normal characters requires an extra command. For example,
the command to “normalize” the high-order control codes is
(ESC) “6”. Try this program with the DIP switch 1-6 on.
i.
L
L
10
' Demo of characters in high-order control
code area
20 LPRINT CHR$(27);"6";
30 FOR I=128 TO 159
40 LPRINT CHR$(I);
50 NEXT I
60 LPRINT CJ.-lR$(27);"7"
70 END
i.
6..
c..
L.
That’s where the italic international characters have been
stored. So the (ESC) “6” command without the (ESC) “R”
gives you access to the international characters. The (ESC) “7”
turns these characters back into control codes.
The low-order control codes can also be defined, but not all of
them can be printed easily. The (ESC) “I” 1 command makes
them printable, and the (ESC) “I” 0 returns them to normal.
Just as the higher control codes hide the italic international
characters, the lower control codes hide the roman international
characters.
Let’s see how these commands work with the following pro-
gram:
10
' Demo of characters in control code area
20 LPRINT CHR$(27);"11";
30 FOR I=0 TO 6