
CIP Services and User-created Tags
Chapter 2
Rockwell Automation Publication 1756-PM020F-EN-P - January 2019
57
In this example, the first and second members have the same offset. This is
typical of how BOOL members are mapped into UDTs. The first member is
the host member for the data described by the second member. The second
member, which is the visible member, is seen in the Logix Designer
application Data Monitor.
See also
This description applies only to UDTs, not Module-Defined,
Add-On-Defined or Predefined structures.
BOOLs in UDTs are typically mapped to a previous SINT (whose name
begins with the prefix ZZZZZZZZZZ)
in the structure data stream. This
SINT does
not
appear in the Logix Designer application Data Monitor view.
With SINT host members, if more than eight contiguous BOOLs are defined,
multiple adjacent SINTs are created to hold them. The bits are mapped into
each SINT beginning with bit 0 thru bit 7 for contiguous BOOLS. If BOOLS
are defined non-contiguously in a UDT, they are mapped to more than one
host member. The Member Offset in the Template identifies where the host
SINT is located and the bit order of the BOOL in the SINT is determined by
the order of the bit in the structure. The host member is sent on the wire
when the tag is accessed, but the visible BOOL is only present in the
structure definition to enumerate the value and is not part of what is sent on
the wire.
Logix BOOL arrays are multiples of BOOL[32] and are implemented as a
DWORD array.
To better understand structure encoding, see the information on structured
Logix 5000 Controllers Import/Export Manual
publication
See also
This example illustrates reading a structure to understand how data transmits.
This example also shows the value for the accessed tag.
The
MachineSummary
structured tag is a STRUCT_B type tag. The
members of the
MachineSummary
tag have these values:
•
pilot_on = 1
•
hourlyCount[0] = 0x00
•
hourlyCount[1] = 0x01
•
hourlyCount[2] = 0x02
•
…
More about BOOLS in UDTs
Step 4: Determine the data
packing of the members of
a structure when accessed
as a whole