Application note
Integrated Modbus support
AN00198
ABB Motion control products
15
new.abb.com/motion
Example 3:
Client e190 wishes to write an integer value of 3 to a remote Modbus register (location 0x3B00) on a vision system supporting
operation as a Modbus TCP Server. The vision system has IP address 192.168.0.3 and is configured as Server ID 2 in the list of
connected devices…
MODBUSTCP16 (2, 0x3B00) = Int16(0x0003)
Function Int16(ByVal a As Integer) As Integer
Int16 = IIf(a > 0x7FFF, a - 0x10000, a)
End Function
Note the use of the custom Int16 function written in Mint to ensure the correct representation of signed 16 bit data.
Example 4:
Client e190 wishes to write a floating point value of 1.234 to NETFLOAT(1) on a remote MotiFlex e180 connected via Modbus
TCP. The MotiFlex e180 has IP address 192.168.0.2 and is configured as Server
ID 0 in the list of connected devices…
MODBUSTCPFLOAT(0,2) = 1.234
When the MicroFlex e190 or MotiFlex e180 drive is operating as a Modbus Server, Netdata events will only be raised whenever
the Modbus Client writes
modified
data to Netinteger / Netfloat locations 0 to 31.
Diagnostics
The web page built into the MicroFlex e190 and MotiFlex e180 drive products contains diagnostic information about Modbus
TCP and Modbus RTU Server (for e190) operation.
Launch the web page from the Mint Sidebar and select ‘Menu”.
The Server diagnostics page displays the current configuration and counters showing the number of successful and
unsuccessful Modbus TCP/RTU transactions (and also shows how many transactions of each Modbus function code type have
been actioned).