Modbus master responsibilities, Soe_data contents – Rockwell Automation T8xxx Trusted Communications Interface User Manual

Page 66

Advertising
background image

Trusted

TM

Communication Interface T8151B

Issue 21 Apr 10

PD-T8151B

66

While in the IDLE state, the service will wait until it receives one or more events. The events are
encoded into the appropriate data blocks, with the first data block at the start of the SOE_DATA area.
The service will continue to receive events and place them sequentially in data blocks in the
SOE_DATA until there are no more events in the queue, or the maximum number of data blocks has
been reached.

The service will then record the number of data blocks available in the SOE_DATA area in the
NUM_BLKS register followed by incrementing the value of the SEQ_NO register. This marks the
beginning of the XFER state.

While in the XFER state, the service will ignore new events, keeping them on the queue until the next
time the IDLE state is entered.

The service will examine the SEQ_NO, ACK_SEQ, NUM_BLKS, and ACK_BLKS registers to
determine when the XFER state has completed, and a new IDLE state has begun. The XFER state
will be complete only when the SEQ_NO and ACK_SEQ are equal, and the NUM_BLKS and
ACK_BLKS are equal.

7.5. Modbus Master Responsibilities

The master will examine the SEQ_NO and ACK_SEQ registers to determine when the IDLE state is
over and a new XFER state has begun. The XFER state will have begun only when the SEQ_NO and
ACK_SEQ are not equal, and the NUM_BLKS and ACK_BLKS are not equal.

The master will then read each of the blocks in the SOE_DATA area as specified in the NUM_BLKS
register. The master may do this one block at a time or in block groups, up to the limits imposed either
by the size of the SOE_DATA area, or by the limitations of the MODBUS read command. The master
may also read all blocks in the SOE_DATA area, ignoring those that do not contain valid data for this
sequence.

Once the blocks have been read, the master writes the value in NUM_BLKS to the ACK_BLKS
register, then the value in SEQ_NO to the ACK_SEQ register. This will end the XFER state, and mark
the beginning of the next IDLE state.

7.6. SOE_DATA Contents

The data blocks read from the SOE_DATA area will contain either Time-stamp or Variable information.
For each sequence, a Time-stamp block with a REASON code of 4 (data event) will proceed the first
Variable block. Subsequent Variable blocks will use the time-stamp from the preceding Time-stamp
block. Note that it is possible to have a single Time-stamp block followed by any number of Variable
blocks. In such a case, all of the variables share the same time-stamp. It is also possible to have a
Time-stamp block preceding each Variable block. In such a case, each variable is associated with a
unique time-stamp. Because a Time-stamp block is present before the first Variable block of a
sequence, it is possible for 2 Variable blocks transferred in different sequences to share a time-stamp
that was derived from 2 separate (but equal) Time-stamp blocks.

There is no guarantee that the time-stamps contained in subsequent Time-stamp blocks will be in
order.

Advertising