
Configuration as a Modbus Master
MVI56-MCM
♦
ControlLogix Platform
Modbus Communication Module
ProSoft Technology, Inc.
Page 37 of 159
July 24, 2008
Label Description
Enable = 1
Causes the module to send the command every time it goes through
the command list.
IntAddress = 16480
Places the data read from the slave device into the module at address
16480. IntAddress 16480 of the module memory will be copied into the
tag MCM.DATA.ReadData[30] (bit16480 / 16 = register 1030).
Count = 16
Reads 16 consecutive registers from the slave device.
Node = 1
Issues the Modbus command to node 1 on the network.
Func = 2
Issues a Modbus Function code of 2 to Read Input Coils.
DevAddress = 80
Function Code 2, DevAddress of 80 will read address 10081
Along with a count of 16, this command reads 10081 to 10096.
4.3.5 Write Single Coil 0xxxx (Modbus Function Code 5)
Used to write a Coil of a slave device, these are single bit addresses within a
Modbus slave device. The IntAddress field of this command is defined down to
the bit level within the module memory, and should come from an area of
memory that has been defined within the MCM.DATA.WriteData area (this is
configured within MCM.CONFIG.ModDef.
Below is a sample command to write Modbus addresses 0513 of node 1 on the
Modbus network, only when the data associated with the IntAddress has
changed.
Label Description
Enable = 2
Causes the module to send the command only when the data within the
IntAddress field of the module has changed.
IntAddress = 160
Will write the data to the slave device when the value at WriteData[10].0
has changed. Because this is a bit level command, the IntAddress field
must be defined down to the bit level.
Count = 1
Will write a single bit to the device (FC5 will 1 support a count of 1).
Node = 1
Issues the Modbus command to node 1 on the network.
Func = 5
Issues a Modbus Function code of 5 to write a single coils.
DevAddress = 512
Function Code 5, DevAddress of 512 will read address 0513