Modbus tcp mapping examples, Modbus rtu master, Figure 58 - modbus tcp mapping table – Weidmuller WI-I/O-9-U2: Wireless Mesh I/O & Gateway User Manual V1.2.2 User Manual

Page 75

Advertising
background image

74

Modbus TCP Mapping Examples

Figure 57 - Modbus TCP Mapping table

The first mapping in Figure 57 - Modbus TCP Mapping table above shows the Modbus
Client (Master) is configured to read analog values from a device connected on the
LAN. The mappings function code is “Read” and is reading a count of 4 values
(Analogs) from the Ethernet address 192,168.0.17, Device ID #10, starting at address
30001, and then writing these values into its own local registers starting at 40501. The
server Port is 502, which is a standard Modbus TCP Port address and if the mapping
fails to communicate to the TCP server it will write a value of 1 into local register 508
indicating a communications failure.

The next mapping shows something similar however, instead of analog value they are
digital values

. The Function code is “Read” from IP address 192.168.0.17 and Device ID

#10. It will read 8 values starting from address 10001 and writing them to the local
address starting at 501. Again its using the same Server port of 502, and if the mapping
fails to communicate to the TCP server it will write a value of 1 into local register 507
indicating that mapping failed to communicate.

The third mapping is similar to the second however, instead of reading from the local
Ethernet subnet (LAN) it is reading from an IP address on the radio network, i.e. another
WI-I/O 9-U2

module. The Function code is “Read” from IP address 192.168.10.101 and

Device ID #1. It will read 4 values starting from address 10001 and writing them to the
local address starting at 509. A comms fail register is configured at local register 506

The last mapping is

configured to ‘Write’ the values from the local analog Input #1& 2

across to a TCP Server at IP address 192.168.0.17. It will write the values into the
Destination address 40001

&40002 at Device ID of 10. It’s using the TCP server port

502, is configured with a response time of 1000mSec and if it fails to communicate it will
turn on local register 505.

Modbus RTU Master

Modbus RTU functionality allows connections to Modbus RTU slave devices via the
RS232 or RS485 ports. Maximum number of mappings that can be configured is 100.

All Modbus Mappings are directed to/from the onboard I/O registers depending on
configuration (described below). The Modbus RTU Master polls the slave devices via
the serial port configured in the mappings.

Modbus RTU (serial) devices can also be polled if connected to remote WI-I/O 9-U2
serial ports. To enable this feature the remote WI-I/O 9-U2 serial port must be set to
‘Modbus RTU Master’ mode and the TCP mappings must reflect the correct Server IP
address and Port number of the remote WI-I/O 9-U2. Polling TCP Servers or RTU

Advertising