EasyManuals Logo

Siemens Simatic S7 Series System Manual

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
Page #433 background imageLoading...
Page #433 background image
Libraries
9.3 Modbus library instructions
S7-200 SMART
System Manual, 09/2015, A5E03822230-AC
433
Modbus RTU slave protocol
Modbus slave protocol instructions use the following resources from the CPU:
The MBUS_INIT instruction initializes the Modbus slave protocol and dedicates the
assigned CPU port (0 or 1), for Modbus slave communication.
When a CPU port is used for Modbus communication, it cannot be used for any other
purpose, including communications with an HMI.
Modbus slave instructions affect all of the SM locations associated with a Freeport
communications on the port assigned by the MBUS_INIT instruction.
Modbus slave instructions program size
Modbus slave instructions use 3 subroutines and 2 interrupts.
Modbus slave instructions require 2113 bytes of program space for the two slave
instructions and support routines.
The variables for the Modbus slave instructions require a 786 byte block of V memory.
The starting address for this block is assigned by the user and is reserved for Modbus
variables.
Note
To change the CPU communication port from Modbus back to PPI so that you can
communicate with an HMI device, set the mode parameter of the
MBUS_INIT
instruction to a zero (0).
9.3.1.2
Initialization and execution time for Modbus protocol
Modbus RTU master protocol:
The master protocol requires a small amount of time every
scan to execute the MBUS_CTRL instruction. The time will be about .2 milliseconds when
the MBUS_CTRL is initializing the Modbus master (first scan), and about 0.1 milliseconds
on subsequent scans.
The scan time is extended when the MBUS_MSG instruction executes a request. Most of
the time is spent calculating the Modbus CRC for the request and response. The CRC
(Cyclic Redundancy Check) insures the integrity of the communications message. The
PLC scan time is extended by about 86 microseconds for each word in request and in the
response. A maximum request/response (read or write of 120 words) extends the scan
time to approximately 10.3 milliseconds. A read request extends the scan mainly when
the response is received from a slave, and to a lesser extent when the request is sent. A
write request extends the scan mainly when the data is sent to a slave, and to a lesser
extent when the response is received.

Table of Contents

Other manuals for Siemens Simatic S7 Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens Simatic S7 Series and is the answer not in the manual?

Siemens Simatic S7 Series Specifications

General IconGeneral
CPUVaries by model (e.g., S7-300, S7-400, S7-1200, S7-1500)
Communication InterfacesPROFIBUS, PROFINET, Ethernet, MPI
ProgrammingTIA Portal, STEP 7
Programming LanguagesLAD, FBD, STL, SCL, GRAPH
I/O ModulesDigital, Analog, Specialty modules available
Operating Temperature0°C to 60°C (standard models)
MountingDIN rail mounting
Operating Voltage24V DC or 120/230V AC (varies by model)
Protection ClassIP20 (standard models)
MemoryVaries depending on the S7 model. Includes work memory (RAM) for program execution, load memory (EEPROM or Flash) for program storage, and system memory for operating system functions. Memory sizes range from kilobytes to megabytes.

Related product manuals