EasyManua.ls Logo

Inovance H3U Series - Page 611

Inovance H3U Series
737 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
610
9
9 Communication9.4.4 Programming Method for Communication Among Multiple PLCs Through Modbus Protocols
Note:
When the system accesses 32-bit registers of C200 to C255 through Modbus protocols, one register should
be regarded as two because the space occupied by a 32-bit register doubles that occupied by a 16-bit
register. For example, if registers of C205 to C208 will be read or written, the Modbus address is 0xF70A
(0xF700 + 10), and the number of registers is 8 (4 x 2).
The parameter number (0x06) to write a single register is inapplicable to 32-bit registers.
9.4.4 Programming Method for Communication Among Multiple PLCs
Through Modbus Protocols
For a system where two or more PLCs communicate with each other and run in parallel, programming
through Modbus protocols is easy and exible. For combinations of multiple devices (for example,
PLC+MDI), programming through Modbus protocols is convenient.
Modbus communication is in "one master+multiple slaves" mode. The master station initiates data
exchanges, and all slave stations passively receive and respond to requests. Communication programs
are mainly written in the master station. During communication programming for slave stations, you only
need to congure communication protocol, communication format, and station number, and process
communication data.
Example I: As shown in the following gure, the master PLC sends (D50 to D55, M10 to M17) to slave PLC 2,
and PLC 2 returns (D100 to D105, Y10 to Y17) to the master PLC; PLC 2 sends (D110 to D119, X0 to X17)
to the master PLC, and the master PLC returns (D60 to D69, M100 to M115) to PLC 2.
COM1 COM1
RS485,Modbus protocol
H2UH2U
Master Slave 1
COM1
COM0
H2U
Slave 2
D8126=H20
D8120=H89
D8126=H02
D8120=H89
D8121=K2
D8126=H02
D8120=H89
D8121=K1
COM0COM0
Slave PLC 1 Slave PLC 2
D100~D105ˈY10Y17
D110~D119ˈX0X17
Slave PLC 2
D50~D55ˈM10M17
D60~D69ˈ
M100~M115
Programming method
When conguring COM1 of the master PLC, select a Modbus master station protocol, set the baud rate to
9600 bps, and select the 8N2 format. The master PLC exchanges (reads and writes) data.
X, Y, and M bit variables are integrated into D variables, and then exchanged in batches within a range
of consecutive D variables. Master and slave PLCs combine and parse variables. In this way, data is
exchanged efciently and programming is easy.
When variables M10 to M17 of the master station are integrated into D56, the master station will send
seven D variables: D100 to D106. When variables X0 to X17 of a slave station are integrated into D120, the
master station will read 11 D variables: D110 to D120.
During programming for the master station with Modbus instructions, data is exchanged efciently, and less
registers are occupied.
Congure COM1 through AutoShop. Select the Modbus-RTU master station protocol, set baud rate to 9600
bps, set the data length to 8-bit, set the odd/even parity check to none, and set the number of stop bits to 2.

Table of Contents

Other manuals for Inovance H3U Series

Related product manuals