Справочное Руководство для Intermec 1555

Скачать
Страница из 178
Interactive Programming Mode
4-13
4
Product-to-host acknowledgment timeouts
The wait time for the high-level acknowledge from the product (ACC, NAC, ASI 
. . . ) depends on the time required for internal communication with the 
submodule(s) or execution of the internal setup command task.
The timeout for the “ACC” response from the product is short (less than 100 mS) 
for the IMC barcode decode function. It can be considerably longer (up to 5 
seconds) for other functions (e.g., IMC “data buffer clear” command).
The timeout for an ASI response from the RF submodule can be a maximum of 1 
second. If there is no response after this period, the ASI response will be sent to 
the host with parameter 0x00 to indicate “no response from submodule.”
The high-level acknowledge timeout for setup commands can be a maximum of 3 
seconds depending on the setup command function.
Checksum Calculation
The checksum is a calculated value that is used to test data integrity. Errors can occur 
when data is transmitted or when it is written to disk. One means of detecting such 
errors is the use of a checksum. A value is calculated for a given block of data by 
sequentially combining all the bytes of data with a series of arithmetic or logical 
operations. After the data is transmitted or stored, a new checksum is calculated and 
compared with the original one. If the checksums match, the transmission or storage 
was ensured to be virtually error free. If they do not match, an error occurred.
To determine the frame’s checksum value
1.
Calculate the weighted sum of each value in the frame except STX, CHK, and 
ETX (weight decreases by one for each successive value).
2.
Calculate the modulo 65536 on the result of step 1.
3.
Assign the hex value obtained (checksum) formatted over two bytes (CHK1 = 
most significant byte, followed by CHK2 = least significant byte).
4.
Apply the proprietary DLE if required on the data, CHK1, and CHK2, but not on 
the delimiters.
Table 4-11 shows an example for DATA = 12345678.
 
Table 4-11  Frame Example with DATA = 12345678 
Frame
STX
Type
Data
FM
CHK
ETX
Hex 
Value
0x7F  0x01
0x31
0x32
0x33 0x34
0x35
0x36
0x37
0x38
0x01
 0x8E7
0x7F