Ref: "ProgGuide1_7.docx"
Page 19 of 26
Document Revision: “1.7”
Document Date: “11 Sep. 2013”
Codes Transmitted
The printer automatically transmits XON and XOFF bytes when the buffer status changes, as follows:
XON
11H
Start transmission
Meaning: The buffer is ready to receive data.
Transmitted after a reset, or when the data buffer empties to only 1/4 full.
XOFF
13H
Stop transmission
Meaning: The buffer is not ready to receive data.
Transmitted when the data buffer becomes 3/4 full, or before a controlled entry into sleep mode.
In addition the printer can transmit a special STATUS byte, either on request, or optionally when
individual status conditions change state:
The commands ESC,"u",n and ESC,"v" request the STATUS byte be transmitted at the time that the
command is interpreted. (N.B. The buffer is never reported as empty when these commands are
used, as it contains at least this command at the time of transmission).
The command GS,ENQ requests the STATUS byte be transmitted immediately on receipt of the
command, even if the buffer contains large amounts of data yet to be interpreted and/or printed.
The GS,"a",n command specifies individual bits of the STATUS byte which should be monitored, and
result in the STATUS byte being automatically transmitted if a change of state is detected.
[STATUS]
Status Report
The STATUS byte is encoded bitwise:
bit 0 Head Up Sensor Active?
[0= head OK
1= head up
]
bit 1 Mechanism running
[0= stopped
1= running
]
bit 2 Data buffer completely empty?
[0= not empty 1= empty
]
bit 3 Paper Out Sensor Active?
[0= paper OK
1= paper out
]
bit 4 Reserved
[
]
bit 5 Spooling mode?
[0= normal
1= spooling
]
bit 6 Error
[0= no error
1= error present ]
bit 7 Always Set
[
Always 1
]
The command GS,"I",n is also a request for information to be transmitted at the time that the
command is interpreted (i.e. not in ‘real-time’). For details of the valid values for n, and the resultant
transmitted information see the QUERYING INTERNAL CONFIGURATION INFORMATION section
below.
If an error condition exists, then the usual single STATUS byte is followed by a second error
identification byte. This second byte is only sent if bit6 of the STATUS byte is set. The values of the
error ID byte are as follows:
Value
Error type
80H
Mechanism Voltage (Vmech) above upper limit
7FH
Mechanism Voltage (Vmech) below lower limit
40H
Mechanism Head Temperature above upper limit
07H
Cutter Blade stuck out - probably jammed (ATB102 only)
06H
Cutter Blade stuck in or no cutter found (ATB102 only)
Other values are either not defined or represent internal controller hardware errors.
N.B.
The ATB102 and Ap1200 differ in the use of bits 0 and 3 of the STATUS
byte. These two printers report the "Paper Out" status via bit 0. The ATB102
(only) also provides for an additional "Head Up" input which is reported via
bit 3. The Ap1200 has no provision for a “Head Up” sensor.