Instrutech The Hornet IGM402 User Manual page 61

Hot cathode ionization vacuum gauge with dual convection
Table of Contents

Advertisement

Instruction Manual
Additional notes when using the BINARY protocol:
As previously noted we recommend using the ASCII instead of Binary protocol whenever possible. However, if you
must use the BINARY protocol, then there are a few things that should be noted when writing code to communicate
with the device.
1. The length of the message sent to the unit is always the same as the length of the response to the message
(although, individual commands have different lengths), i.e., length of response = length of command.
2. The messages sent to the unit and received from the unit are sent in hexadecimal, and not their character
representations. This means that a character based application such as Hyperterminal® cannot be used.
Applications such as these send a value such as zero as 30 hex, and not at 00 hex.
3. The start character for any message sent to the unit is a '!' or 21 hex.
4. The start character for any response to a message is a '*' or 2A hex.
5. The data part of the message sent to the unit does not matter. This portion of the message is ignored by the
receiving unit. It is recommended that these bytes be set to zero prior to sending the message to the unit.
6. The data part of the responses are NOT ASCII characters. These are actual variable values that are of type char,
float, or long. This shortens the messages and simplifies the code written by the customer by not having to
convert from ASCII characters to typed values and back again.
7. The Cyclic Redundancy Check (CRC) is calculated using the routine shown in the previous pages in
the User Manual. The length of the message is the number of bytes beginning at the "start" character, ending with
the last byte of the data, and does not include the byte that will contain the CRC. The checksum (CRC) is calculated
on all the characters in the command/response string excluding the CRC itself.
Example of actual data bytes sent and received for a 'READ IG PRESSURE ONLY' command:
(This is done with the filament off)
SENT:
Byte 0: '!' (0x21) (start character)
Byte 1: 1 (0x01) (address)
Byte 2: 2 (0x02) (command byte for READ IG PRESSURE)
Byte 3: 0 (0x00) (don't care units)
Byte 4: 0 (0x00) (don't care data 1)
Byte 5: 0 (0x00) (don't care data 2)
Byte 6: 0 (0x00) (don't care data 3)
Byte 7: 0 (0x00) (don't care data 4)
Byte 8: 183 (0xB7) (CRC)
RECEIVED:
Byte 0: '*' (0x2A) (start character)
Byte 1: 1 (0x01) (address)
Byte 2: 2 (0x02) (command byte for READ IG PRESSURE)
Byte 3: 0 (0x00) (units; 0 = Torr, 1 = PASCALS, 2 = mBAR)
Byte 4: 0 (0x00) (floating point byte 1)
Byte 5: 0 (0x00) (floating point byte 2)
Byte 6: 0 (0x00) (floating point byte 3)
Byte 7: 0 (0x00) (floating point byte 4)
Byte 8: 148 (0x94) (CRC)
InstruTech
IGM402 Hornet
section 8.1
of
Page 59

Advertisement

Table of Contents
loading

Table of Contents