The text of a manual · part 5 of 7
TPSK Printer Series 24 & 12V User Manual, pages 41 to 50
Pages 41 to 50 of 67
The original document is the PDF (1.9 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.
For the Axiohm TPSK
Page 41
TRANSMIT STATUS Transmits the status specified by n. This is a batch mode command which transmits the response after all prior data in the reception buffer has been processed. There may be a time lag between the printer receiving this command and transmitting the response, depending on the reception buffer status. ASCII Hexadecimal Decimal Value of n
GS r n 1D 72 n 29 114 n 4, 52
= Flash memory User Sector status
The status bytes to be transmitted are described in the following two tables. Flash memory User Sector Status (n = 4 or n = 52) Bit Off/On Hex Decimal Status for Transmit Status 0 Undefined. 1 Undefined. 2 Off 00 0 Not Used. Fixed to off 3 Off 00 0 Logo(s) defined. On 08 8 No logo defined. 4 Off 00 0 Not used. Fixed to off. 5 Undefined 6 Off 00 0 Not used. Fixed to off. 7 Undefined. Exceptions When n is out of the specified range, the command is ignored. SET SENSOR THRESHOLD Synopsis: This command configures the sensors (except Flapper sensor, see page detection threshold. ASCII GS s m n Hexadecimal 1D 73 m n Decimal 29 115 m n m = sensor select Operand: n = threshold value Limit: Decimal m=6; m=8; m=9 0 n 255 Hex: m=06; m=08; m=09 00 ≤ n ≤ FF Default: Decimal: n = 102 Hex: n = 66 Description: This command will store the sensor detection threshold in non-volatile memory. Note: This command must be followed by a reset. m Decimal
Hex
6 8 9
06 08 09
TPSK 12 & 24 V User’s Manual
“GS s” OPERAND DEFINITION Sensor Connecto Sensor r Low Paper Opto jam Hyst opto jam Page 40 / 66
Mechanism -
Reference: FDE 31 08 972 Issue Z
Page 42
SEND PRINTER SOFTWARE VERSION The printer returns 8 bytes containing the boot and flash software version. The first 4 bytes returned are an ASCII string for the boot version. The second 4 bytes are an ASCII string for the flash version. Example: the printer returns 1.07 1.15 This means the boot version is 1.07 and the flash version is 1.15. ASCII Hexadecimal Decimal
US V 1F 56 31 86
RETURN SRAM SIZE Returns the size of SRAM on board, on one byte as number of 64 Kbytes sectors. ASCII Hexadecimal Decimal
GS BS 1D 08 29 08
SRAM sizes 4 kb (internal RAM only) 128 kb (w/extension)
0 2
TRANSMIT SELECTED A/D CHANNEL Returns the size of SRAM on board, on one byte as number of 64 Kbytes sectors. ASCII Hexadecimal Decimal
GS l m 1D 6C m 29 108 m
Returns the voltage. * m = 0 x 08 Sends an octet of between 0 and 255 = value measured on the A-D converter = AD measure Voltage (V) = 0.11274 x AD measure Example: AD measure = 213 =>Voltage = 24.01V AD measure = 186 => Voltage = 21.00V * m = 0 x 09 Sends an octet of between 0 and 255 = value measured on the temperature converter = AD measure RTH = 100 / ((255 / AD measure) - 1) Temp (°C) = (3950 / (ln (RTH / 30) + 13.255)) - 273 Example: AD measure = 60 => Temp = 24.43°C AD measure = 27 => Temp = 47.47°C
Note: tolerance not taken into consideration and calculation not precise TPSK 12 & 24 V User’s Manual
Page 41 / 66
Reference: FDE 31 08 972 Issue Z
Page 43
5.10 Real time commands The Real Time commands provide an application interface to the printer even when the printer is not handling other commands. Real Time Status Transmission: DLE (Hex 10) Sequence Real Time Request to Printer: DLE (Hex 10) Sequence Real Time Printer Status Transmission The original Printer Status commands, Transmit Printer Status (Hex 1B 76, ASCII ESC v) are placed in the printer’s data buffer as they are received and handled by the firmware in the order in which they were received. If the paper exhausts while printing data that was in the buffer ahead of the status command, the printer goes busy at the communication interface and suspends processing the data in the buffer until paper is reloaded. This is true for all error conditions: thermal print head overheating, etc. In addition, there is no way to restart the printer after a paper jam or other error. The Real Time commands are provided to overcome these restrictions.
RULES FOR USING REAL TIME COMMANDS Three situations must be understood when using real time commands: 1) The printer executes the Real Time command upon receiving it and will transmit status regardless of the condition of the host being ready to receive or not. 2) The printer transmits status whenever it recognizes a Real Time Status Transmission command sequence, even if that sequence happens to occur naturally within the data of another command, such as graphics data. In this case the sequence will be processed both ways: as a real time command and as the graphics data it is intended to be when the graphics command is executed from the buffer. The result is that the host might receive status messages it has not requested. 3) If the printer is in error condition, meaning that the communication interface is likely to be busy, the host must be able to send the real time commands regardless of this busy state at the interface. Otherwise those commands wouldn’t be received and processed.
TPSK 12 & 24 V User’s Manual
Page 42 / 66
Reference: FDE 31 08 972 Issue Z
Page 44
MOVING DATA THROUGH THE BUFFER Applications should not let the buffer filled up with Real Time commands when the printer is detected busy at the communication interface. A busy condition can be determined by bit 3 of the response to DLE EOT 1. Other responses to DLE EOT n can determine the reason for a particular busy condition. Although the printer responds to Real Time commands when it is busy, it will place them into the buffer following the other data already there. When the printer is only busy because the buffer is full (meaning it cannot print data as fast as it can receive them), then data continue to be processed out of the buffer (approximately at the print speed), the Real Time commands will eventually get flushed out. When the printer is busy due to an error condition, then data stops being processed off the buffer (until the error condition is cleared) In both cases the buffer can be filled with Real Time commands; it will be quicker in the case of an error condition. To avoid this situation, the application must determine the cause of a busy condition and take appropriate action with sending the Real Time commands to avoid filling the buffer. There is a minimum of 256 bytes available in the printer buffer when it turns busy.
BUSY LINE AND FAULT CONDITIONS If the printer is in error condition (cover is open, out of paper…), the printer will turn busy immediately. It will then stay busy and stop processing data out of the reception buffer until the error condition is cleared. It will respond to the Real Time commands as described below.
TPSK 12 & 24 V User’s Manual
Page 43 / 66
Reference: FDE 31 08 972 Issue Z
Page 45
REAL TIME RECOVERY FROM FAULT This command will select the recovery mode when the printer detects a fault condition. Any fault condition that prevents the printer from printing requires one of these commands to allow printing to resume. DLE Sequence DLE ENQ n 10 05 n 16 5 n
ASCII Hexadecimal Decimal
Operand Limit n = recovery mode Decimal: n Hex: n “DLE ENQ” OPERAND DEFINITION n
Decimal
2
Hex
02
Fault recovery mode
Recovers from a fault after clearing the reception and print buffers. Print settings that are normally preserved from line to line, such as character height and width, are still preserved with this operand.
Notes: • •
•
This command will attempt recovery from any fault that prevents printing, including jams and paper out. Recovering from a print head over temperature condition is only accomplished by waiting until the print head has returned to its operating temperature range. This command will be ignored until manual intervention has occurred to clear the fault condition. The indication of manual intervention for clearing paper out, paper jams, cutter fault, consists of opening and closing the clamshell door.
TPSK 12 & 24 V User’s Manual
Page 44 / 66
Reference: FDE 31 08 972 Issue Z
Page 46
REAL TIME STATUS TRANSMISSION Transmits in real time the selected one byte printer status. It is specified by n according to the following parameters. DLE Sequence DLE EOT n 10 04 n 16 4 n
ASCII Hexadecimal Decimal
Value of n
DLE Sequence 1 = Transmit printer status 2 = Transmit communication interface busy status 3 = Transmit error status 4 = Transmit receipt paper status
Exceptions
The command is ignored if n is out of range.
Related Information 1 = Transmit Printer Status Bit
Status
Hex
Decimal
Function
0 1 2 3
Off On On Off On
00 02 04 00 08
0 2 4 0 8
4 5 6 7
On
10
16
Off
00
0
Fixed to Off. Fixed to On. Fixed to On. Not busy at the communication interface. Printer is Busy at the communication interface. Fixed to On. Undefined. Undefined. Fixed to Off.
TPSK 12 & 24 V User’s Manual
Page 45 / 66
Reference: FDE 31 08 972 Issue Z
Page 47
2 = Transmit communication interface Busy Status Bit
Status
Hex
Decimal
Function
0 1 2
Off On Off On Off On On Off On Off On Off
00 02 00 04 00 08 10 00 20 00 40 00
0 2 0 4 0 8 16 0 32 0 64 0
Fixed to Off. Fixed to On. Cover closed. Cover open. Paper feed button is not pressed. Paper feed button is pressed. Fixed to On. Printing not stopped due to paper condition. Printing stopped due to paper condition. No error condition. Error condition exists in the printer. Fixed to Off.
3 4 5 6 7
3 = Transmit Error Status Bit
Status
Hex
Decimal
Function
0 1 2
Off On UP Down OK JAM On Off On Off
00 02 00 04 00 08 10 00 20 00
0 2 0 4 0 8 16 0 32 0
Fixed to Off. Fixed to On. Flapper on Paper Path
On
40
64
Off
00
0
3 4 5 6
7
TPSK 12 & 24 V User’s Manual
Opto JAM Fixed to On. No unrecoverable error. Unrecoverable error occurred. Thermal print head temperature and power supply voltage are in range. Thermal print head temperature or power supply voltage is out of range. Fixed to Off
Page 46 / 66
Reference: FDE 31 08 972 Issue Z
Page 48
4 = Transmit Receipt Paper Status Bit
Status
Hex
Decimal
Function
0 1 2
Off On Off On Off On On Off On Off On Off
00 02 00 04 00 08 10 00 20 00 40 00
0 2 0 4 0 8 16 0 32 0 64 0
Fixed to Off Fixed to On Paper not low Paper low Paper not low Paper low Fixed to On Paper present Paper out Paper present Paper out Fixed to Off
3 4 5 6 7
TPSK 12 & 24 V User’s Manual
Page 47 / 66
Reference: FDE 31 08 972 Issue Z
Page 49
5.11 Bar code commands These commands format and print bar codes.
SELECT PRINTING POSITION OF HRI CHARACTERS Prints HRI (Human Readable Interface) characters above or below the bar code. ASCII Hexadecimal Decimal
GS H n 1D 48 n 29 72 n
Value of n Printing position
0 = Not printed 1 = Above the bar code 2 = Below the bar code 3 = Both above and below the bar code Default
0 (Not printed)
SELECT PITCH OF HRI CHARACTERS Select font used to print HRI characters. ASCII Hexadecimal Decimal
GS f n 1D 66 n 29 102 n
Value of n
0 = Standard Pitch at 12.7 CPI 1 = Compressed Pitch at 16.9 CPI
Default
1 (Standard Pitch at 16.9 CPI)
SELECT BAR CODE HEIGHT Sets the bar code height to n dots or n/203 inch (n/8 mm). ASCII Hexadecimal Decimal
GS h n 1D 68 n 29 104 n
Value of n Number of dots Range of n 1-255 Default
216
TPSK 12 & 24 V User’s Manual
Page 48 / 66
Reference: FDE 31 08 972 Issue Z
Page 50
SELECT BAR CODE WIDTH Sets the bar code module to n/203 inch (n/8 mm). ASCII Decimal
GS w n 1D 77 n 29 119 n
Value of n
1 2, 3, 4, 5,6
Default n=3
Formulas n/203 inch (n/8 mm).
Hexadecimal
PRINT BAR CODE Selects the bar code type and prints a bar code for the ASCII characters entered. If the width of the bar code exceeds one line, the bar code is not printed. There are two variations to this command. The first variation uses a NULL character to terminate the string; the second uses a byte at the beginning of the string that determines the string length. Bar codes can be aligned left, centered, or aligned right using the Align Positions command (1B 61). The check digit is calculated for UPC and JAN (EAN) codes if it is not sent from the host computer. Sixcharacter zero-suppressed UPC-E tags are generated from full 11 or 12 characters sent from the host computer according to standard UPC-E rules. Start/Stop characters are added for Code 39 if they are not included. First Variation GS k m d1…dk NUL Hexadecimal 1D 6B m d1…dk NUL Decimal 29 107 m d1 dk NUL (0 = End of command) ASCII
Second Variation GS k m n d1…dn 1D 6B m n d1…dn 29 107 m n d1…dn
Exceptions The command is only valid at the beginning of a line - Illegal data will cancel the command.
TPSK 12 & 24 V User’s Manual
Page 49 / 66
Reference: FDE 31 08 972 Issue Z