42
Implementing Global Data
As indicated above, three global data configuration items exist for each point in
the point database: a “get” node, a “get” offset, and a “put” offset. If a given
point is intended to be accessed only via standard MSTR write and read
commands (MSTR functions 1 and 2, respectively), then both the “get” and
“put” offsets should be set to “DISABLED”. Standard MSTR read and write
commands can then be used to access the point by targeting its “Modbus Slave
Register” assignment.
If global data is to be used, however, then one of the global data selections
must be enabled by programming it with an offset value (in the case of a “put”),
or with a node address and an offset value (in the case of a “get”). If the point
is to be written to by another device on the Modbus Plus network, then the
MBP-100 must be configured to “get” data from that selected device’s global
data block. If the point’s value is to be broadcast to the network, however, then
the MBP-100 will “put” the point’s value into its own global data block, where
other network nodes can “get” the data if desired. It is even possible to
configure a specific point to both “get” and “put” global data (in effect
performing global data “relaying”).
Because the gateway can be configured to retrieve global data from any offset
(offset values 0-31) from any node (address values 1-64), very powerful peer-
to-peer networking configurations can be created that entirely bypass the need
for a PLC “master” executing MSTR instructions. The only configuration
constraint with respect to global data is that “put” offsets must be unique. For
example, if point #9 has been assigned a “put” offset of 5 (meaning that this
point’s value will be placed in the 6
th
word from the start of the gateway’s global
data), and if point #13 is also assigned a “put” offset of 5, then only the value of
the point with the larger numerical index (in this case, point #13) would appear
at the duplicated offset. “Get” global data configuration has no such limitation:
it is perfectly acceptable for multiple points to consume data from the same
offset in a common node’s global data block. This type of configuration may be
particularly useful in synchronized systems, for example, where multiple points
(and their associated devices on other networks) follow a “leader” value being
broadcast by a single Modbus Plus node.
As a brief example of a global data implementation, Table 2 shows how 12
points in the point database might be configured for a specific application. Note
that some points are consuming global data, some points are producing global
data, and some points do not access global data at all (either they are not being
used for Modbus Plus access, or they are accessed only via “standard” MSTR
read or write commands).