
Understanding PCL printer command syntax
Before using printer commands, compare these characters:
Lowercase l: | l | Uppercase O: | O |
Number one: | 1 | Number 0: | 0 |
Many printer commands use the lowercase letter l (l) and the number one (1), or the uppercase letter O (O) and the number zero (0). These characters might not appear on your screen as shown here. You must use the exact character and case specified for PCL printer commands.
The following illustration displays the elements of a typical printer command (in this instance, a command for page orientation).
Escape character | Value field (contains both | ||||
(begins escape | |||||
sequence) | alpha and numeric characters) | ||||
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| Uppercase letter | |
Category of command | (terminates escape | ||||
|
|
|
| sequence) |
Combining escape sequences
Escape sequences can be combined into one escape sequence string. There are three important rules to follow when combining code:
1For each escape sequence, the first two characters after the ? character must be the same.
2When combining escape sequences, change the uppercase (termination) character in each individual escape sequence to lowercase.
3The final character of the combined escape sequence must be uppercase.
The following escape sequence string would be sent to the printer to select legal paper, landscape orientation, and 8 lines per inch:
?&l3A?&l1O?&l8D
The following escape sequence sends the same printer commands by combining them into a shorter sequence:
?&l3a1o8D
170 Appendix D Printer commands | ENWW |