Modbus TCP Sinamics v1 0 en
Modbus TCP Sinamics v1 0 en
Legal information
Use of application examples
Application examples illustrate the solution of automation tasks through an interaction of several
components in the form of text, graphics and/or software modules. The application examples are
a free service by Siemens AG and/or a subsidiary of Siemens AG (“Siemens”). They are non-
binding and make no claim to completeness or functionality regarding configuration and
equipment. The application examples merely offer help with typical tasks; they do not constitute
customer-specific solutions. You yourself are responsible for the proper and safe operation of the
products in accordance with applicable regulations and must also check the function of the
respective application example and customize it for your system.
Siemens grants you the non-exclusive, non-sublicensable and non-transferable right to have the
application examples used by technically trained personnel. Any change to the application
examples is your responsibility. Sharing the application examples with third parties or copying the
application examples or excerpts thereof is permitted only in combination with your own products.
The application examples are not required to undergo the customary tests and quality inspections
of a chargeable product; they may have functional and performance defects as well as errors. It is
your responsibility to use them in such a manner that any malfunctions that may occur do not
result in property damage or injury to persons.
Disclaimer of liability
Siemens shall not assume any liability, for any legal reason whatsoever, including, without
limitation, liability for the usability, availability, completeness and freedom from defects of the
application examples as well as for related information, configuration and performance data and
any damage caused thereby. This shall not apply in cases of mandatory liability, for example
under the German Product Liability Act, or in cases of intent, gross negligence, or culpable loss of
life, bodily injury or damage to health, non-compliance with a guarantee, fraudulent
non-disclosure of a defect, or culpable breach of material contractual obligations. Claims for
damages arising from a breach of material contractual obligations shall however be limited to the
Siemens AG 2017 All rights reserved
foreseeable damage typical of the type of agreement, unless liability arises from intent or gross
negligence or is based on loss of life, bodily injury or damage to health. The foregoing provisions
do not imply any change in the burden of proof to your detriment. You shall indemnify Siemens
against existing or future claims of third parties in this connection except where Siemens is
mandatorily liable.
By using the application examples you acknowledge that Siemens cannot be held liable for any
damage beyond the liability provisions described.
Other information
Siemens reserves the right to make changes to the application examples at any time without
notice. In case of discrepancies between the suggestions in the application examples and other
Siemens publications such as catalogs, the content of the other documentation shall have
precedence.
The Siemens terms of use (https://support.industry.siemens.com) shall also apply.
Security information
Siemens provides products and solutions with industrial security functions that support the secure
operation of plants, systems, machines and networks.
In order to protect plants, systems, machines and networks against cyber threats, it is necessary
to implement – and continuously maintain – a holistic, state-of-the-art industrial security concept.
Siemens’ products and solutions constitute one element of such a concept.
Customers are responsible for preventing unauthorized access to their plants, systems, machines
and networks. Such systems, machines and components should only be connected to an
enterprise network or the internet if and to the extent such a connection is necessary and only
when appropriate security measures (e.g. firewalls and/or network segmentation) are in place.
For additional information on industrial security measures that may be implemented, please visit
https://www.siemens.com/industrialsecurity.
Siemens’ products and solutions undergo continuous development to make them more secure.
Siemens strongly recommends that product updates are applied as soon as they are available
and that the latest product versions are used. Use of product versions that are no longer
supported, and failure to apply the latest updates may increase customer’s exposure to cyber
threats.
To stay informed about product updates, subscribe to the Siemens Industrial Security RSS Feed
at: http://www.siemens.com/industrialsecurity.
Table of contents
Legal information ......................................................................................................... 2
1 Introduction ........................................................................................................ 4
1.1 Overview............................................................................................... 4
1.2 Mode of operation ................................................................................ 4
1.3 Components used ................................................................................ 4
2 Engineering ........................................................................................................ 5
2.1 Configuration ........................................................................................ 5
2.2 Operation .............................................................................................. 7
3 Additional information ...................................................................................... 9
3.1 Background .......................................................................................... 9
3.2 Fieldbus monitoring time .................................................................... 11
4 Appendix .......................................................................................................... 12
4.1 Service and Support ........................................................................... 12
4.2 Application Support ............................................................................ 13
4.3 Links and Literature ............................................................................ 13
4.4 Change documentation ...................................................................... 13
Siemens AG 2017 All rights reserved
1 Introduction
1.1 Overview
Since SINAMICS firmware version 4.8 the communication protocol Modbus TCP is
supported by S120, G130 and G150. The application example describes the
communication settings from a SINAMICS S120.
S7-1516F 1 6ES7516-3FN00-0AB0
CU310-2 1 6SL3040-1LA01-0AA0
2 Engineering
2.1 Configuration
Prerequisite for further steps is the successful commissioning of the drive. The
document (follow the link) offers a brief guide to commissioning a sample project
with a simple SINAMICS S120 drive train. By following the instructions in this
document, a beginner will need only a few minutes to engineer and configure the
sample project and start up the motor.
https://support.industry.siemens.com/cs/ww/en/view/109740023
1. For drive object control unit (DO1), set p2030 = 13 (Modbus TCP).
Siemens AG 2017 All rights reserved
In the STARTER commissioning tool, check the list of drive object p0978.
The screenshot below is showing a correct configuration
Siemens AG 2017 All rights reserved
8. Save the settings in the STARTER commissioning tool and carry out a POWER ON.
2.2 Operation
For the operation of the application example, the content of this Section is
absolutely necessary. In SIOS you can download the example project.
TCON
(default: 3456)
partnerPort UInt Partner port number, see system function
TCON. (default: 502)
partnerIP IP_V4 Partner IP address from the drive
// Connection parameter
//-----------------------------------------------------------
Modbus_Communication
"typeModbus_Config" configuration
3 Additional information
3.1 Background
Modbus-TCP-Client
The "MB_CLIENT" instruction from the S7-1500 communicates as a Modbus TCP
client via the local interface. With the "MB_CLIENT" instruction, you establish a
connection between the client (S7-1500) and the server (drive), send Modbus
requests, receive responses and control connection termination of the Modbus
TCP client.
For details please look at description of system function MB_CLIENT.
Drive Profile
PROFIdrive is the standard profile for SINAMICS drive technology in conjunction
with the PROFIBUS and PROFINET communication systems. A uniform basic
state machine is defined for all application classes in PROFIdrive. It is used to
bring the drive to a dedicated operating state or switch off the drive in a defined
manner.
The following figure shows the basic state machine (general state diagram) of a
Siemens AG 2017 All rights reserved
PROFIdrive drive. The blue blocks represent drive axis states S1 to S5 and the
arrows indicate the state transitions that are possible between them. In case of
competing state transitions, priorities are defined by the number of red points
shown. The conditions for the state transitions to the yellow boxes are the
individual control commands, which are transferred from the controller to the drive
axis in the control word with bit coding.
In the example function block, the state machine was implemented in the
"Modbus_Communication" FB as an example. This example implantation is not
exhaustive, but only serves as a test function.
NOTE A detail overview about the assigning Modbus register to the parameters is listed
in the SINAMICS S120 function manual under the chapter 11.4 "Communication
via MODBUS TCP".
https://support.industry.siemens.com/cs/ww/en/view/109740020
Control data
40100 Control word (see SINAMICS S120/150 Process data 1
R/W
List Manual, function diagram 2442)
40101 Main setpoint R/W Process data 2
40102 STW 3 R/W Process data 3
40103 STW 4 R/W Process data 4
40104 PZD 5 R/W Process data 5
4010… PZD … R/W Process data …
40109 PZD 10 R/W Process data 10
Status data
40110 Control word (see SINAMICS S120/150 Process data 1
R
List Manual, function diagram 2452)
40111 Main actual value R Process data 2
40112 ZSW 3 R Process data 3
40113 ZSW 4 R Process data 4
40114 PZD 5 R Process data 5
4011… PZD … R Process data …
40119 PZD 10 R Process data 10
Drive data
40324 2
Reference speed R/W P2000
40400 Failure number, Index 0 R r0947 [0]
40408 Alarm number R r2110 [0]
40409 Actual alarm code R r2132
2) These registers are not supported for linear motors as the unit and value range differ from normal rotary
drives.
4 Appendix
4.1 Service and Support
Industry Online Support
Do you have any questions or need assistance?
Siemens Industry Online Support offers round the clock access to our entire
service and support know-how and portfolio.
The Industry Online Support is the central address for information about our
products, solutions and services.
Product information, manuals, downloads, FAQs, application examples and videos
– all information is accessible with just a few mouse clicks at:
https://support.industry.siemens.com
Technical Support
The Technical Support of Siemens Industry provides you fast and competent
support regarding all technical queries with numerous tailor-made offers
– ranging from basic support to individual support contracts. You send queries to
Technical Support via Web form:
www.siemens.com/industry/supportrequest
Siemens AG 2017 All rights reserved
Service offer
Our range of services includes the following:
Plant data services
Spare parts services
Repair services
On-site and maintenance services
Retrofitting and modernization services
Service programs and contracts
You can find detailed information on our range of services in the service catalog:
https://support.industry.siemens.com/cs/sc