beautypg.com

Spectrum Controls 1769sc-HART Modules User Manual

Page 113

background image

Chapter 7: Enabling and Using HART on the 1769sc-IF4IH0

User's Manual 0300215-03 Rev. A

7-45

The 1 byte Device Type code is allocated and controlled by the manufacturer. The 3 byte
Device Identifier is similar to a serial number in that each device manufactured with the
same Device Type Code must have a different Device Identifier. The IF4IH
automatically pulls for the device specific codes using the Auto-acquisition process. The
device specific codes that are acquired using this process can be seen in Table 2.

Command

The command byte contains an integer (0 to hex FF or decimal 257) that represents one
of the HART commands. Code 254 is defined as an expansion code and is followed by
another byte allowing more than 256 different commands to be defined if necessary. The
received command code is echoed back by the slave device in its reply.

There are three categories of commands: universal commands, which all HART devices
must implement; common practice commands, which should be used if the particular
function is provided; and device specific commands, which are for functions more or less
unique to a particular slave device.

Byte Count

The byte count portion of the message contains an integer value representing the number
of bytes that form the remainder of this message excluding the checksum. In other
words, the byte count determines the length of the data and status.

Status

Status is included only in reply messages from a slave. It consists of two bytes of bit-
coded information. The first byte indicates communication errors, if any. Otherwise if
communication was good, this byte may indicate the status of the received command
such as a busy device, or a command not recognized. The second status byte indicates
the operational state of the slave device. A properly operating slave device will have
both status bytes set to logical zero. The meaning of the individual status bits can be
found in Appendix D.

Data

This portion of the HART message contains the data, if any, for the command. Not all
commands or responses contain data. For those that do, up to 25 bytes can be included.
Data may be in the form of unsigned integers, floating point numbers, or ASCII character
strings. The number of bytes of data and the data format used for each item are specified
for each HART command.

Checksum

The checksum byte contains the exclusive-or (longitudinal parity) of all the bytes that
precede it in the message starting with the Start Character. This provides a further check
on transmission integrity, beyond the parity check on the 8 bits of each individual byte.

7.5.2

Sending a HART Command to a Field Device via Pass-through

Now that you're familiar with the bits and pieces that make up a HART message, the next
step will be to formulate a message and successfully send the message to the field device
using the pass-through command. The first step is to formulate the message and populate
the source tag If4ih0PassThruReqTX. This tag is used in the ladder sample shown in
Figure 7-10.