Siemens SIMATIC S7-1200 Manual page 77

Hide thumbs Also See for SIMATIC S7-1200:
Table of Contents

Advertisement

Execute all MB_SLAVE instructions from a cyclic interrupt OB.
The Modbus instructions do not use communication interrupt events to control the
communication process. Your program must poll the MB_MASTER or MB_SLAVE
instructions for transmit and receive complete conditions.
If a port is to respond as a slave to a Modbus master, then that port cannot be used by
MB_MASTER. Only one instance of MB_SLAVE execution can be used with a given port.
Likewise, If a port is to be used to initiate Modbus master requests, that port cannot be used
by MB_SLAVE . One or more instances of MB_MASTER execution can be used with that
port.
If your program operates a Modbus slave, then MB_SLAVE must poll (execute periodically)
at a rate that allows it to make a timely response to incoming requests from a Modbus
master.
If your program operates a Modbus master and uses MB_MASTER to send a request to a
slave, then you must continue to poll (execute MB_MASTER) until the response from the
slave is returned.
Easy Book
Manual, 11/2009, A5E02486774-01
6.2 PtP, USS, and Modbus communication protocols
The MB_SLAVE instruction allows your user program to
communicate as a Modbus slave. A Modbus RTU master can issue
a request and then your program responds via MB_SLAVE
execution.
Inserting the MB_SLAVE instruction creates an instance data block.
Use this DB name as the MB_DB parameter on the
MB_COMM_LOAD instruction.
Easy to communicate between devices
77

Advertisement

Table of Contents
loading

Table of Contents