Control Code Functions
The following information is listed for each code function (where applicable and possible).
ASCII Mnemonic - The standard ASCII name for the control code.
Hex Code - The code's numeric equivalent in hexadecimal.
Purpose - The function(s) of the control code.
Expression - A sample program statement written in the BASIC programming language.
Comment - A description of exceptions or limitations to normal use.
Special Function Code - Control Code Header
A Special Function Code (SFC) is used to extend the control code protocol. The SFC is the
control code introducer (or header); it is the first input in the sequence of parameters. The
general control code sequence is:
(SFC)(parameter 1)(parameter 2)...(parameter n)
P-Series codes use SOH as the control code introducer. For example, to enable bold print in
the P-Series mode, use the P-Series SFC and the bold print control code character G:
ASCII:
SOH G
Similarly, Serial Matrix codes use ESC as the control code introducer. For example, to enable
bold print in the Serial Matrix mode, use the Serial Matrix SFC and the bold print control code
character G:
ASCII:
ESC G
NOTE: All ESC and SOH commands must be terminated by a ;" in a BASIC program
or by text following the command string. A paper motion command directly following a
special function code command may result in erroneous paper movement.
Attribute Set and Reset Codes
Certain print attributes are set and reset (turned on or off) by using the appropriate ESC or
SOH code sequence and the numbers 1 or 0. These may be either the hexadecimal code 01 and
00, or the ASCII code for the printable symbols of decimal 1 and 0 (hexadecimal code 31 and
30, respectively). Expanded Print, Super/Subscript Print, and Underline are attributes which
are set/reset in this fashion.
6-2
Hex:
01 47
Hex:
1B 47
BASIC:
CHR$(1);"G"
CHR$(27);"G"
BASIC:
Programming