EasyManua.ls Logo

Siemens Simatic S7 Series

Siemens Simatic S7 Series
726 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...
Libraries
9.3 Modbus library instructions
S7-200 SMART
System Manual, 09/2015, A5E03822230-AC
447
The Error output contains the result of executing the instruction. This output is only valid if
Done is ON. If Done is OFF, the error parameter is not changed.
Table 9- 31 Example program of S7-200 SMART CPU operating as a Modbus slave
LAD
STL
Initialize the Modbus Slave protocol on
the first scan. Set the slave address to
1, set port 0 to 9600 baud with even
parity, all access to all I, Q and AI val-
ues, allow access to 1000 holding reg-
isters (2000 bytes) starting at VB0.
Network 1
LD SM0.1
CALL MBUS_INIT, 1, 1, 9600,
2, 0, 128, 32, 1000, &VB0,
M0.1, MB1
Execute the Modbus Slave protocol on
every scan.
Network 2
LD SM0.0
CALL MBUS_SLAVE, M0.2, MB2
See also
Modbus slave execution error codes (Page 448)

Table of Contents

Other manuals for Siemens Simatic S7 Series

Related product manuals