Simatic comunicaciones e

185
Configurations for Communication Communication with Automation Systems Planning - Configuring - Referencing

Transcript of Simatic comunicaciones e

Configurations for Communication

Communication with Automation Systems Planning - Configuring - Referencing

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 2/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Preamble

Introduction Nowadays, the communication possibilities between automation systems are a core demand and necessity, even in the case of systems of the lower performance class. Due to the large variety of communication processors, protocols and user interfaces in the SIMATIC homogenous system world (i.e. only SIMATIC systems communicate with each other) and particularly in the heterogeneous system world (i.e. SIMATIC systems communicate with “third party” automation systems) this topic is extremely complex. Basic knowledge of the principles behind protocol mechanisms, protocols utilizable with the bus systems, as well as their properties, are just as im-portant as the concrete implementation of a solution approach on the basis of proven application samples.

Specific problems with the communication tasks From the user’s or planner’s viewpoint, the following questions may often arise when planning the communication solutions: 1. Which Bus System is available as platform for the planned automation

solutions? 2. Which Protocol can be efficiently employed for the planned task on this

bus system and will be supported by the systems to be connected? 3. How will these Protocols be used to achieve effectively the desired

automation solution? 4. Which further mechanisms are required to solve the given task effi-

ciently?

Objective of this document The reader is enabled to face the concrete problems within the planning and configuration phase in two steps: 1. The main document which

prepares and clearly displays the basic information about possible bus systems and protocols being essential for the user.

2. A collection of the applications, which are complete within themselves, which takes up typical communication problems and offers praxis-oriented solutions by using chosen protocols and further communication mechanisms.

The applications are prepared in a way that, on the one hand, the problem-oriented utilization and the embedding of the used protocols in the own user program are shown concretely and, on the other hand, further neces-sary program mechanisms required for solving the problems are explained.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 3/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Addressed group of persons This document and the attached applications as a whole provides both ba-sic knowledge as well as example solutions. This teaching material is cre-ated e.g. for users …

• Who want to familiarize themselves with the complex topic “Communication for Automation Systems“ more intensely.

• Who need a bus- and protocol oriented overview of all possible constellations within the SIMATIC

• Who need a glossary for the topic “Communication with SIMATIC“ User with these demands may be, e.g.:

• Starters of the SIMATIC communication

• Technically oriented marketing advisors who want to use this teaching material for their presale or planning phase

• Project planners / developers, who are looking for testes modules as basis for their own advancement.

Structure of this document This document is divided into the 4 following parts:

Table 1-1 Part Title with brief description

1 Communication structures in the SIMATIC S7 This chapter gives you an overview of the structural design and the mechanisms of the communication within the SIMATIC.

2 Bus-orientated selection aid of applicable protocols This chapter is intended as selection aid and jump distributor in the protocol summary.

3 Description of the available protocols This chapter comprises a collection of summaries trying to explain in a short and com-parable form the individual protocols.

4 A glossary on term explanation As a conclusion, the terms used in the main document are explained more detailed.

Using the hyperlinks This document has been structured by means of hyperlinks to keep the structure of the main document as linear as possible. Each subchapter includes a return jump point to return the next higher level of the hierarchy. The highest level will be reached as soon as chapter 2 Bus-oriented Se-lection Aid of Usable Protocols has been reached. A hyperlink is marked by means of a blue written and underlined text:

Back to the bus-oriented selection aid of usable protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 4/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Working with this Document There are two ways to use this document

• The pragmatic start The user can read the document as of the first chapter and obtain an overview of the available interfaces and the applicable protocols.

• The problem-oriented start By means of a concrete problem, a solution for a communication task is sought here.

The following steps are performed: Table 1-2

Step Description

1 The start into the document is the “Bus-oriented Selection Aid of Usable Protocols”. Here you can find an overview of the viewed bus systems and their case constellations which can be opened via hyperlinks.

2 On the side opened via the selected hyperlink branch, the available detail constellation is to be carried out or the detail constellation has already been reached.

3 Each detail constellation is represented by an overview of approx. 4 pages. It contains:

○ An overview of the connection case on hand ○ An overview of the possible hardware constellations and

the protocol used therein ○ An overview of the properties of the usable protocols as

well as ○ An estimate of the performance of the used protocol, if

available, as well as an overview of the application samples available for this bus or for the protocol.

4 In the protocol overview, each of the stated protocols can be branched via hyperlinks. This opens a protocol summary outlin-ing the protocol on a further approx. 4 pages.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 5/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Warranty, Liability and Support

We do not accept any liability for the information contained in this docu-ment. Any claims against us - based on whatever legal reason - resulting from the use of the examples, information, programs, engineering and perform-ance data etc., described in this document shall be excluded. Such an ex-clusion shall not apply in the case of mandatory liability, e.g. under the German Product Liability Act (“Produkthaftungsgesetz”), in case of intent, gross negligence, or injury of life, body or health, guarantee for the quality which goes to the root of the contract (“wesentliche Vertragspflichten”). of a product, fraudulent concealment of a deficiency or breach of a condition However, claims arising from a breach of a condition which goes to the root of the contract shall be limited to the foreseeable damage which is intrinsic to the contract, unless caused by intent or gross negligence or based on mandatory liability for injury of life, body or health. The above provisions do not imply a change in the burden of proof to your detriment. The Configurations are not binding and do not claim to be complete regard-ing the circuits shown, equipping and any eventuality. They do not repre-sent customer-specific solutions. They are only intended to provide support for typical applications. You are responsible in ensuring that the described products are correctly used. These Configurations do not relieve you of the responsibility in safely and professionally using, installing, operating and servicing equipment. When using these Configurations you recognize that Siemens cannot be made li-able for any damage/claims beyond the liability clause described above. We reserve the right to make changes to these Configurations at any time without prior notice. If there are any deviations between the recommenda-tions provided in these Configurations and other Siemens publications - e.g. Catalogs - then the contents of the other documents has priority.

Copyright© 2004 Siemens A&D. It is not permissible to transfer or copy these Configurations or excerpts of them without first having prior authorization from Siemens A&D in writing.

For questions about this document please use the following e-mail-address: [email protected]

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 6/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table of Contents

1 Communication Structures in the SIMATIC............................................. 8 1.1 Internal communication structures (paths) ................................................... 8 1.2 External communication structures (paths).................................................. 9 1.3 Bus systems............................................................................................... 10 1.3.1 Two-point connection ................................................................................. 11 1.3.2 Multipoint connection ................................................................................. 11 1.3.3 Overview of the bus systems available in SIMATIC................................... 12 1.4 Communication display in the SIMATIC family .......................................... 13 1.4.1 The S7-200 family ...................................................................................... 13 1.4.2 The S7-300/400 family ............................................................................... 15 1.4.3 WinAC-Basis/RTX...................................................................................... 17 1.4.4 WinAC-Slot................................................................................................. 18 2 Bus-oriented Selection Aid of Usable Protocols .................................. 20 2.1 MPI bus ...................................................................................................... 21 2.1.1 CPU connection external ........................................................................... 22 2.1.2 CPU connection internal ............................................................................ 26 2.2 PROFIBUS................................................................................................. 29 2.2.1 PB CPU – CP connection .......................................................................... 30 2.2.2 PB CP-CP connection................................................................................ 36 2.2.3 PB CPU – CPU connection........................................................................ 42 2.2.4 PC Broadcast / Multicast............................................................................ 47 2.3 Industrial Ethernet ...................................................................................... 51 2.3.1 IE CPU – CP connection............................................................................ 52 2.3.2 IE CP – CP connection .............................................................................. 56 2.3.3 IE CPU – CPU connection ......................................................................... 61 2.3.4 IE Broadcast / Multicast ............................................................................. 64 2.4 Serial Interface ........................................................................................... 67 2.4.1 PtP- connection.......................................................................................... 69 2.4.2 PtP Multicast / Broadcast ........................................................................... 73 2.5 SIMATIC backplane bus ............................................................................ 76 2.5.1 Backplane connection ................................................................................ 77 3 Protocol Description................................................................................ 81 3.1 Protocols within SIMATIC S7 ..................................................................... 82 3.1.1 Global data................................................................................................. 84 3.1.2 S7 basic communication (MPI, PB_DP)..................................................... 88 3.1.3 S7 communication (IE, PB, MPI)................................................................ 98 3.2 Industrial Ethernet .................................................................................... 110 3.2.1 ISO Transport protocol............................................................................. 112 3.2.2 TCP protocol ............................................................................................ 116 3.2.3 ISO on TCP protocol ................................................................................ 120 3.2.4 UDP Protocol ........................................................................................... 125 3.3 PROFIBUS............................................................................................... 130

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 7/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3.1 FDL protocol............................................................................................. 132 3.3.2 DP protocol .............................................................................................. 140 3.3.3 FMS protocol............................................................................................ 148 3.4 Serial Protocols ........................................................................................ 153 3.4.1 Protocol RK512 ........................................................................................ 155 3.4.2 Procedure 3964(R)................................................................................... 158 3.4.3 Free ASCII protocol.................................................................................. 160 3.4.4 Modbus protocol....................................................................................... 162 3.4.5 Data highway protocol.............................................................................. 172 4 Compendium / Glossary........................................................................ 178

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 8/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

1 Communication Structures in the SIMATIC

Introduction The following chapter deals with the basic principles and concepts of the communication within the SIMATIC environment required for the data ex-change within or between the automation devices.

1.1 Internal communication structures (paths)

Introduction The automation system SIMATIC is based on a modular system of modules of different functionalities. To use this system in its modularity, a control mechanism is required via which all parts of the system can communicate with each other. Within the SIMATIC, this task is realized by means of a backplane bus.

General display of the backplane bus systems

Figure 1-1 The backplane bus system is structured as follows:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 9/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 1-1

Bus system Task

Communication bus (K-bus)

The communication bus (also K-bus) has the task to manage the acyclic data exchange to: • CPs

• IP / FMs and

• Other CPUs A bus system is available here which also allows for connections between the stations without using the CPU.

P-bus (I/O bus) The P-bus (I/O-bus) is responsible for the data exchange between CPU and the centralized I/O. Here, it is possible to access data or to transfer data which are stored in the I/O area of the CPs or IP / FMs.

1.2 External communication structures (paths)

Introduction One of the core functionalities in today’s automation world is to coordinate different automation systems with each other. This coordination is made via an up-to-date exchange of data between the individual systems. To connect the systems with each other, communication paths are required enabling even the overcoming of larger distances. These communication paths present themselves in the form of standardized interfaces offering services for data transfer.

General presentation of the external communication structure

Figure 1-2 The external communication structure can be divided as follows:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 10/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 1-2

Interface Description

CPU-internal interface

CPU-internal interfaces are directly at the CPU. There they are either directly connected to the associated internal bus (e.g. MPI) or directly connected to a proc-essor of the CPU. A direct connection has the advantage that:

• Restrictions by the backplane bus will be avoided

• thus providing a certain performance advance.

External interfaces

The external communication interfaces are usually within the station racks or in an expansion rack as a communication module. Some of the communication modules can also be used in the distributed, not intelligent units. A connection of these modules to each other or to a CPU is either made:

• Via the communication bus

• or the I/O bus. (Decentralized I/O is also as-signed to the I/O)

1.3 Bus systems

Introduction The interfaces offered in the SIMATIC family are divided in their physical types of connection into the following groups:

• Two-point connections or

• Multipoint connections. To provide a simple distinctive possibility the main differences of both types of connection are shown here: Table 1-3

Two-point connection Multipoint connection

1 connection partner for each inter-face

n connection partner for each inter-face

Small distances bridgeable (approx. 10 – 1000 m)

Larger distances bridgeable (much longer than 100 km)

Small protocol effort with comparable data transmission security

High protocol effort with comparable data transmission security

High deterministics High deterministics only via high protocol effort

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 11/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

1.3.1 Two-point connection

Two-point connection or peer-to-peer connections are direct connections be-tween 2 end points.

Figure 1-3 Peer-to-peer connections are often designed as serial connections. In case of serial connections, standardized interfaces like RS 232, TTY (20mA) or RS 422/RS485 are usually used. The protocols used here are, for example, ASCII, RK512 or the 3964 R protocol.

1.3.2 Multipoint connection

In case of multipoint connections, several stations are connected with each other via a joint transmission medium in order to exchange data.

Figure 1-4

The multipoint connection is the classic case of a bus system. Two or more stations use the same transmission medium. For example twisted two-wire circuits, tri-axial cables or duplex fiber-optic cables can be used as a transmission medium. Bus systems can be set up as

• Bus / line structures

• Tree structures

• Star structures or

• Ring structures.

Main document e-Infoshop Communication using automation systems

Rev. A - Endgültig 12.04.2004 12/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

1.3.3 Overview of the bus systems available in SIMATIC

In the following table some of the main properties of protocols available in SIMATIC are compared with each other.

Table 1-4

Bus system Transmission Rates Number of stations

Maximum network size

Redundancy ability Connection technol-ogy

Bus medium

MPI 187.5 kBit/s – 12 MBit/s

32 (126) 50 m/el. segment otherwise see PROFIBUS

No (with OLM: Yes) RS 485, optical fiber Shielded TP, optical fiber

PROFIBUS 9.6 kBit/s – 12 MBit/s

126 9.6 km elect. >90 km optical

Yes RS 485, optical fiber Shielded TP, optical fiber

Industrial Ethernet

10 MBit/s – 1 Gbit/s

Over 1000 2.5 km elect. about 200 km optical

Yes AUI, 9 pin Sub D, RJ45

Tri-axial cable, shielded TP, optical

fiber, WiFi ASI-Bus 167 kBits/sec 1 Master

31 / 62 Slaves 500 m with Repeater

and Extender No ASI interface line with

penetration technique ASI interface line

Serial PtP 300 Bit/s – 115.2 kBit/sec

Without special driver2

V 24 : 10m TTY : 1.000m X 27 : 1.200m

No RS 232 C (V.24), 20 mA (TTY),

RS 422/485 (X 27)

V 24 cable, shielded TP, TTY cable

Master/Slave 300 Bit/sec – 76.8 kBit/sec TTY up to

19.2 kBit/sec

247 max. 32 per RS 485

segment

V 24 : 10m TTY : 1.000m X 27 : 1.200m

No RS 232 C (V.24), 20 mA (TTY),

RS 422/485 (X 27)

V 24 cable, shielded TP, TTY cable

Data highway 300 Bit/sec – 76.8 kBit/sec TTY up to

19.2 kBit/sec

32 V 24 : 10m TTY : 1.000m X 27 : 1.200m

No RS 232 C (V.24), 20 mA (TTY), RS 422 (X 27)

V 24 cable, shielded TP, TTY cable

SIMATIC backplane bus

187.5 kBit/s or 10.5 MBit/sec

Rack-dependent Rack size No SIMATIC backplane bus connector

SIMATIC backplane bus

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 13/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

1.4 Communication display in the SIMATIC family

Introduction The following chapter shows the communication possibilities of the individ-ual controller families. In this connection, the individual system families are described together with their communication module families.

1.4.1 The S7-200 family

The following communication possibilities are available for the S7-200 fam-ily:

Figure 1-5

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 14/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 1-5

Module Description

CPU interface The following three operating modes are possible with the CPU-owned interfaces:

• As a PPI interface with PPI protocol fo

• As an MPI interface with MPI slave functions for CPU / CPU communication and HMI applications

• As a freely programmable, serial interface supporting the ASCII protocol.

The desired operating mode can be set for the CPU. Up to two interfaces can be available for each PU.

Serial interface (EM 241)

The only serial expansion module of the S7-200 being available so far is the EM241. It offers a modem interface. The application range of this module is remote diagnostics and the PC communication or the message transmission via SMS / pager. The module offers the PPI protocol or a Modbus slave support.

Industrial Ethernet inter-faces

(CP 243-1 / CP 243-1 IT)

The Ethernet CPs 243-1 or 243-1 IT are designed for connecting the S7-200 to the Ethernet. These allow for a direct connection of controllers of the S7-300 / S7-400 family as well as of PCs for programming or HMI functions. Moreover, the IT version is able to allow for direct access to the controller via a built-in HTTP-Server functionality or FTP func-tions. In addition, a limited E-Mail client function enables sending messages.

ASI master interface (CP 243-2)

The CP 243-2 is an AS-I master of the specification 2.1. It can be used for connecting up to 62 AS-I slaves. A direct processing of analog values is possible

PROFIBUS interface (EM 277)

The expansion module EM277 is used as a valuable DP slave interface for the PROFIBUS. Programming as well as S7 Server functions can be operated simultaneously via this module.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 15/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

1.4.2 The S7-300/400 family

The following communication possibilities are available for the S7-300 / S7-400:

Figure 1-6

Table 1-6

Module Description

CPU interfaces Depending on the type, the CPU offers 3 different internal inter-faces:

• MPI interface for programming functions or for HMI functions or for a simple connection between controllers.

• PROFIBUS DP (also MPI/DP) interface for connecting de-central field devices, HMI systems or usable as program-ming interface.

• Industrial Ethernet / PROFInet interface for connecting PRO-FInet networks, suitable as programming interface or as connection of HMI systems

Serial interface (e.g. CP 440,

CP 340 / CP 441-1, CP 341 / CP 441-2)

There are various different serial interfaces available for the S7-300 / S7-400. Available interfaces are:

• RS 232C, • TTY or • RS 422/485

These interfaces can be applied either individually or as a combina-tion (in case of CP 441-2). For transferring user data the following protocols are used:

• 3964 (R), • ASCII • RK 512 protocol • Loadable protocol driver like Modbus or Data

Highway DF1.

Not all of the protocols are supported by modules.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 16/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Module Description

PROFIBUS interfaces (e.g. CP 342-5 /

CP 443-5 Extended, IM467, CP 343-5 / CP 443-5 Basic)

The following protocols can be used with the PROFIBUS interface: • FDL protocol • S7 protocol • DP protocol • FMS protocol

Here, only combinations with the DP or FMS protocol are offered by the individual CPs. The interface module has exclusively been de-signed for the DP protocol.

Industrial Ethernet (z.B. CP 343-1/

CP 443-1, CP 343-1 IT / CP 443-1 IT,

CP 444, CP 343-1 PN)

The interfaces of the Industrial Ethernet offer the highest transmis-sion rate of the interfaces introduced here. They can also be used for cost-effective connections of third-party systems or old systems. The supported protocols are:

• ISO transport (restricted) • ISO on TCP (RFC 1006) • TCP • UDP • PROFInet • FTP • HTTP • SMTP (only sending) • MAP

Not all of the protocols are supported by modules.

ASI Master (z.B. CP 343-2)

Via the AS-I bus it is possible to connect directly simple actuators or sensors of specification 2.1. This version can be used for connect-ing up to 62 AS-I slaves.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 17/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

1.4.3 WinAC-Basis/RTX

The following communication possibilities are available for the WinAC-Basis/RTX:

Figure 1-7

Table 1-7

Module Description

MPI interfaces (e.g. CP 5611)

The MPI interface represents primarily a programming interface. Furthermore, it is designed as a dynamic data interface for the ex-change with S7 micro-controllers as well as for the data communica-tion to an HMI application.

PROFIBUS interfaces (e.g. CP 5611,

CP 5613)

The PROFIBUS interface of the WinAC is used as PROFIBUS DP master or as communication interface with other S7 systems via the S7 protocol. HMI function is additionally possible. There are no other PROFIBUS standard protocols available in the system.

Industrial Ethernet inter-faces

(e.g. CP 1611, CP 1613)

The Industrial Ethernet interface of the WinAC is suitable for ex-changing larger data amounts with other S7 systems. It can also be used to program the controller or operate via HM systems.

Special features of the WinAC-Basis/RTX With its position as a mere Soft PLC, the WinAC Basis takes a special status among the S7 controllers. Via the additional software package ”In-dustrial Data Bridge” it is also able to use indirectly other communication protocols by means of the OPC server. However, out of all the standard functions the WinAC-Basis/RTX is only fixed to the DP and S7 communica-tion.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 18/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

It is necessary to install the Simatic Net Software for using the communica-tion services.

1.4.4 WinAC-Slot

The following communication possibilities are available for the WinAC-Slot:

Figure 1-8

Table 1-8

Module Description

CPU-internal interface

The WinAC-Slot offers (CPU 412 or CPU 416) two internal inter-faces in both versions:

• An MPI / DP interface and

• A DP interface

Both interfaces can be used as DP master interface. The MPI / DP interface can be used either as MPI or DP interface for remote pro-gramming, or for connecting to other S7 controllers or for HMI appli-cations, without having to use another CP.

MPI interfaces (e.g. CP 5611)

The MPI interface represents primarily a programming interface. Furthermore, it can be used as a dynamic data interface for the exchange with S7 micro-controllers as well as for the application as data interface for micro-HMI applications.

PROFIBUS interfaces (e.g. CP 5611,

CP 5613)

The PROFIBUS interface of the WinAC is used as PROFIBUS DP master or as communication interface with other S7 systems via the S7 protocol. HMI function is additionally possible. There are no other PROFIBUS standard protocols available in the system.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 19/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Module Description

Industrial Ethernet inter-faces

(e.g. CP 1611, CP 1613)

The Industrial Ethernet interface of the WinAC is suitable for ex-changing larger data amounts with other S7 systems. It can also be used to program the controller or operate via HM systems.

Special features of the WinAC-Slot The WinAC-Slot is a mixture of a mere HW controller and a Soft-PLC. By using the Slot CPU as hardware plug-in card (PCI or ISA format) it works out the PLC program independently from the PC CPU. By means of the software package “T-Kit“, an additional software data interface is available enabling a direct data exchange with PC applications.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 20/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2 Bus-oriented Selection Aid of Usable Protocols

Introduction In the following chapter the communication protocols available for this case are shown by means of communication constellations. In addition all possi-ble protocols are differentiated by using defined core criteria which can be protocol-specific or bus-specific and programming-specific.

Contents of the selection aid

Table 2-1

Bus system Constellation Description

CPU connection external

CPU connection between two stations MPI Bus

CPU connection internal

CPU connection within a rack without using the backplane bus

PB CPU – CP connection

PROFIBUS communication between the central processing unit and communication processor

PB CP – CP connection

PROFIBUS communication between communication processors

PB CPU – CPU connection

PROFIBUS communication between cen-tral processing units

PROFIBUS

PB Broadcast / Multi-cast

PROFIBUS communication with multicast / broadcast functionality

IE CPU – CP connec-tion

Industrial Ethernet communication be-tween the central processing unit and communication processor

IE CP – CP connection Industrial Ethernet communication be-tween communication processors

IE CPU – CPU connection

Industrial Ethernet communication be-tween central processing units

Industrial Ethernet

IE Broadcast / Multicast

Industrial Ethernet communication with multicast / broadcast functionality

PtP- connection PtP connection between two stations Serial interface PtP Multicast / Broad-

cast PtP communication with multicast / broad-cast functionality

SIMATIC backplane bus

Backplane bus con-nection

Backplane bus communication between two stations

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 21/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.1 MPI bus

Introduction The following chapter shows successively all possible hardware constella-tions enabling a data transfer via the MPI bus.

Detailed bus description

You will find a detailed bus description of the bus system discussed here in the document “Selection criteria for networks and services”. http://support.automation.siemens.com/WW/view/en/21045102

Structure of the chapter The chapter MPI bus deals with the following 2 hardware constellations:

Table 2-2

Constellation Description

CPU connection external

The CPU connection between two individual control-lers.

CPU connection internal

CPU connection within a rack without using the back-plane bus

Overview of the constellations Each constellation is described by means of the following 4 information units:

• Description of the connection case

• The matrix of the hardware constellations

• The core information of the available protocols

• An overview of the available sample applications for this constellation

Advantages of this consideration This consideration enables the purposive selection of the hardware constel-lation and out of this the selection of the applicable protocol. All possible hardware constellations within the SIMATIC S7 family will be viewed in each constellation. The following overview of protocols enables a direct selection by comparing the functionalities of the applicable protocols.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 22/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.1.1 CPU connection external

Connection case The task is to exchange data between two stations assigned to the same MPI bus.

Hardware scheme This hardware constellation is made up as follows:

Bild 2-1

Both stations, station 1 and station 2, consist of one CPU respectively. They are built up physically separated from each other. And both stations are coupled via the joint MPI bus. The data are to be transferred via this connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 23/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the possible protocols.

Table 2-3

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC-Basis/RTX (as of V 4.0)

S7-200 X (only PPI connection pos-

sible)

S7 basis communication (partner 2 as server via XPUT / XGET)

S7 communication (partner 2 as server) S7 basis communication (partner 2 as server via XPUT / XGET)

S7 communication (partner 2 as server) S7 basis communication (partner 2 as server via XPUT / XGET)

S7 communication

S7-300 X S7 basis communication global data

S7 basis communication S7 communication (partner 1 as client partner 2 as server) global data

S7 basis communication S7 communication (partner 1 as client partner 2 as server) global data

S7 communication

S7-400 X S7 basis communication global data

S7 basis communication S7 communication global data

S7 basis communication S7 communication global data

S7 communication

WinAC-Slot X S7 basis communication global data

S7 basis communication S7 communication global data

S7 basis communication S7 communication global data

S7 communication

WinAC Basis/RTX (ab V 4.0)

X X S7 communication S7 communication S7 communication

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 24/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the MPI bus protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-4

S7 basic communication S7 communication ProtocolService

Criterion XPUT / XGET XSEND / XRECV BSEND / BRCV USEND / URCV PUT / GET

Global data

Data range 1 - 84 bytes 1 -76 bytes 1 – 32768 (S7-300) / 65535 (S7-400) bytes

1 – 165 bytes 1 – 165 bytes 1 - 22 bytes (S7-300) / 1 - 64 bytes (S7-400)

Consistency Only guaranteed when sending

Yes Throughout the whole length 8 bytes throughout the whole length

Yes

Acknowledgement mechanism

Operating system of the controller Level 7 implemented

Operating system of the controller Operating system of the controller

Connected stations 1 – 1 unidirectional 1 – 1 bidirectional

1 – 1 bidirectional

1 – 1 unidirectional 1-1 / 1-n bidirectional

Configuration type Non-configured connection Bilaterally configured Unilaterally config-ured

Bilaterally configured

Connection type Dyn. / stat connection Client / Server

Dyn. / stat connection Client / Client

Stat connection Client / Client Stat. connection Client / Server

Stat connection Client / Client

Data connec-tion suitable

for:

Small data amounts Medium to large data amounts

Small data amounts Smallest data amounts

Perf

orm

ance

Evaluation In case of static connections

In case of dynamic connections

Configuration effort None Low Medium Pogramming effort Medium Medium Medium

Connection of old systems (S5 ) / third party systems

No No No

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 25/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is partly made on the basis of the available measurements resulting from the com-munication examples in the Application Portal and partly on the basis of previous experiences when using protocols.

Application samples For this constellation, “CPU connection external via MPI”, there are several pre-coded examples which are available in the Application Portal.

Table 2-5 Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20987358

This application is an automatic test program to exchange data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data ex-change between the stations. The application can recognize occurring mistakes and can react pur-posively (predetermined).

Client server communication between WinAC Basis and S7.200 station via S7 communication (PUT/GET) Entry-ID: 20987586

This Application describes the synchronization of substations via a server station. When requested, the server station transfers up to 3 different data records to the substations.

N to 1 synchronization of data in the MPI net-work via S7 basic communication (X_SEND/ X_RCV) Entry-ID: 19017849

This Application describes the synchronization of a system of four S7 300 stations. Triggered by means of a digital input, three S7 station send data via a dynamic connection to a defined mas-ter.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 26/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.1.2 CPU connection internal

Connection case The task is to exchange data between two stations which are arranged in the same rack and assigned to the same MPI bus.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-2 The stations consist of two CPUs with the respective I/O modules. They are both set up in the same rack. Both stations are additionally coupled via the joint MPI bus, apart from the mutually used communication bus. The data are to be transferred via the MPI bus connection.

Note The configuration on hand is a special case. The described configuration is usu-ally carried out via the backplane bus connection which can be used, too.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 27/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the possible protocols.

Table 2-6

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC-Basis/RTX (ab V 4.0)

S7-200 S7-300 S7-400 S7 basis communication

S7 communication global data

WinAC-Slot WinAC Basis/RTX (ab V 4.0)

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 28/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the MPI bus protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-7

S7 basic communication S7 communication ProtocolService

Criterion XPUT / XGET XSEND / XRECV BSEND / BRCV USEND / URCV PUT / GET

Global data

Data range 1 - 84 bytes 1 -76 bytes 1 – 32768 (S7-300) / 65535 (S7-400) bytes

1 – 165 bytes 1 – 165 bytes 1 - 22 bytes (S7-300) / 1 - 64 bytes (S7-400)

Consistency Only guaranteed when sending

Yes Throughout the whole length 8 bytes throughout the whole length

Yes

Acknowledgement mechanism

Operating system of the controller Level 7 Implemented

Operating system of the controller Operating system of the controller

Connected stations 1 – 1 unidirectional 1 – 1 bidirectional

1 – 1 bidirectional

1 – 1 unidirectional 1-1 / 1-n bidirectional

Configuration type Non-configured connection Bilaterally configured Unilaterally config-ured

Bilaterally configured

Connection type Dyn. / stat connection Client / Server

Dyn. / stat connection Client / Client

Stat connection Client / Client Stat. connection Client / Server

Stat connection Client / Client

Data connec-tion suitable

for:

Small data amounts Medium to large data amounts

Small data amounts Smallest data amounts

Perf

orm

ance

Evaluation In case of static connection

In case of dynamic connection

Configuration effort None Low Medium Pogramming effort Medium Medium Medium

Connection of old systems ( S5 ) / third party systems

No No No

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 29/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is partly made on the basis of the available measurements resulting from the com-munication examples in the Application Portal and partly on the basis of previous experiences when using protocols.

Application samples For this constellation, “CPU connection external via MPI”, there are several pre-coded examples which are available in the Application Portal.

Table 2-8 Application title/ Entry-ID Description

N to 1 synchronization of data in the MPI net-work via S7 basic communication (X_SEND/ X_RCV) Entry-ID: 20989875

This Application describes the synchronization of a system of four S7 300 stations. Triggered by means of a digital input, three S7 station send data via a dynamic connection to a defined mas-ter.

Back to the bus-oriented selection aid

2.2 PROFIBUS

Introduction The following chapter shows successively all possible hardware constella-tions enabling a data transfer via the PROFIBUS.

Detailed bus description

You will find a detailed bus description of the bus system discussed here in the document “Selection criteria for networks and services”. http://support.automation.siemens.com/WW/view/en/21045102

Structure of the chapter The chapter PROFIBUS deals with the following 4 hardware constellations:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 30/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 2-9

Constellation Description

PB CPU – CP connection PROFIBUS communication between the central processing unit and communication processor

PB CP – CP connection PROFIBUS communication between communica-tion processors

PB CPU – CPU connection PROFIBUS communication between central proc-essing units

PB Broadcast / Multicast PROFIBUS communication with multicast / broad-cast functionality

Overview of the constellations Each constellation is described by means of the following 4 information units:

• Description of the connection case

• The matrix of the hardware constellations

• The core information of the available protocols

• An overview of the available sample applications for this constellation

Advantages of this consideration This consideration enables the purposive selection of the hardware constel-lation and out of this the selection of the applicable protocol. All possible hardware constellations within the SIMATIC S7 family will be viewed in each constellation. The following overview of protocols enables a direct selection by comparing the functionalities of the applicable protocols.

2.2.1 PB CPU – CP connection

Connection case The task is to exchange data between two stations assigned to the same PROFIBUS.

Hardware scheme This hardware constellation is made up as follows:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 31/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Figure 2-3 Both stations, station 1 and station 2, consist of one CPU respectively. Sta-tion 2 uses a communication processor for the connection to PROFIBUS. The data are to be transferred via this PROFIBUS connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 32/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the possible protocols.

Table 2-10

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 S7 basis communication (station 1 DP master, station 2 DP slave) DP communication

S7 basis communication (station 1 DP master, station 2 DP slave) S7 communication DP communication

S7 basis communication (station 1 DP master, station 2 DP slave) S7 communication DP communication

S7 communication / DP communication

S7-300 DP communication S7 communication / DP communication

S7 communication / DP communication

S7 communication / DP communication

S7-400 S7 communication S7 communication S7 communication WinAC-Slot S7 communication S7 communication S7 communication WinAC Basis/RTX (ab V 4.0)

S7 communication S7 communication S7 communication

= nicht anwendbar

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 33/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the PROFIBUS protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-11

S7 basic communication S7 communication ProtocolSevice

Criterion IPUT / IGET BSEND / BRCV USEND / URCV PUT / GET

DP communication

Data range 1 - 84 bytes / 1 - 94 bytes 1 – 32768 (S7-300) / 65535 (S7-400) bytes

1 – 165 bytes 1 – 165 bytes 1 – 244 bytes inputs / 1 – 244 bytes outputs

Consistency Only guaranteed when sending Throughout the whole length 8 bytes throughout the whole length

Between 122 bytes and whole length

Acknowledgement mechanism

Operating system of the controller Level 7 implemented

Operating system of the controller In the PROFIBUS ASIC implemented mechanism + level 7 implementation

via the user program Connected stations 1 – 1

bidirectional 1 – 1

bidirectional 1 – 1 unidirectional 1-1 bidirectional

Configuration type Non-configured connection Bilaterally configured Unilaterally configured Bilaterally configured Connection type Dyn. / stat connection Client / Server Stat connection Client / Client Stat. connection Client

/ Server Stat. connection Client / Server

Data connec-tion suitable

for:

Small data amounts Medium to large data amounts

Small data amounts Small data amounts

Perf

orm

ance

Evaluation In case of static connection

In case of dynamic connection

Configuration effort None Low Medium Pogramming effort Medium Medium Medium

Connection of old systems ( S5 ) / third party systems

No No Yes

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 34/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols. Some representative comparison values as an illustration:

Table 2-12

Protocol Data

S7 communication BSEND / BRECEIVE

DP communication

Approx. 200 bytes

Approx. 95 ms Approx. 79 ms from master to slave*Approx. 39 ms from slave to master*

* The measured value for the DP protocol is based on a measurement with implemented level 7 acknowl-edgement via the user program of 2 stations. The typical DP cycle time is 3 ms.

These measurements are based on the following general requirements:

• Baudrate 1.5 MBit/s

• Busprofil standard

• Two stations at the bus.

Application samples For this constellation, CPU – CP connection via PROFIBUS, the following pre-coded examples have been created which are available in the Applica-tion Portal.

Table 2-13

Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20987358

This application is an automatic test program to exchange data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data ex-change between the stations. The application can recognize occurring mistakes and can react pur-posively (predetermined).

Routing of data records reaching over the sub-network via a gateway CPU with S7 communi-cation (BSEND/BRECEIVE) Entry-ID: 20983154

By means of a fully programmed example, this application shows an implementation of a func-tioning routing of data records. Via a gateway station, configurable data are sent from one sta-tion to the other predefined station which is on another network.

Client / server communication with (I) Slaves via S7 basic communication (I_PUT/ I_GET) Entry-ID: 20987910

The Application on hand offers a simple, quick and practical learning startup into the cli-ent/server specifications of the I_PUT/ I_GET S7 basic communication service and shows how to deal with the configuration and user interfaces in the SIMATIC.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 35/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application title/ Entry-ID Description

Data connection between separate DP systems via DP communication

This application deals with a cost-effective trans-fer of data between two DP masters by using a DP slave CP 342-5. The DP additionally receives a data acknowledgement, which will be evaluated via the application.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 36/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.2.2 PB CP-CP connection

Connection case The task is to exchange data between two stations assigned to the same PROFIBUS.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-4 Both stations, station 1 and station 2, respectively consist of a CPU with a connected PROFIBUS communication processor. The data are to be trans-ferred via this PROFIBUS connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 37/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the possible protocols.

Table 2-14

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 (Here only server or slave)

S7 communication (loadable PBK functions) DP communication

S7 basis communication (station 1 DP master, station 2 DP slave) S7 communication DP communication

S7 basis communication (station 1 DP master, station 2 DP slave) S7 communication DP communication

S7 communication / DP communication

S7-300 S7 communication (loadable PBK functions) FMS communication FDL communication DP communication

S7 communication (per client/server) FMS communication FDL communication DP communication

S7 communication / DP communication

S7 communication / DP communication

S7-400 S7 communication (loadable PBK functions) FMS communication FDL communication DP communication

S7 communication (per client/server) FMS communication FDL communication DP communication

S7 communication / DP communication

S7 communication / DP communication

WinAC-Slot S7 communication (loadable PBK functions)

S7 communication S7 communication S7 communication

WinAC Basis/RTX (ab V 4.0)

S7 communication (loadable PBK functions)

S7 communication S7 communication S7 communication

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 38/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the PROFIBUS protocols On the following pages you will find an overview stating the properties of the applicable protocols. You can evaluate these protocols by means of the selected core properties.

Table 2-15

S7 basic communication S7 communication ProtocolSevice

Criterion IPUT / IGET BSEND / BRCV USEND / URCV PUT / GET

DP communication

Data range 1 - 84 bytes / 1 - 94 bytes 1 – 32768 (S7-300) / 65535 (S7-400) bytes

1 – 165 bytes 1 – 165 bytes 1 – 244 bytes inputs / 1 – 244 bytes outputs

Consistency Only guaranteed when sending Throughout the whole length 8 bytes throughout the whole length

Between 122 bytes and whole length

Acknowledgement mechanism

Operating system of the controller Level 7 implemented

Operating system of the controller In the PROFIBUS ASIC implemented mechanism + level 7 implementation

via the user program Connected stations 1 – 1

bidirectional 1 – 1

bidirectional 1 – 1 unidirectional 1-1 bidirectional

Configuration type Non-configured connection Bilaterally configured Unilaterally configured Bilaterally configured Connection type Dyn. / stat connection Client / Server Stat connection Client / Client Stat. connection Client

/ Server Stat. connection Client / Server

Data connec-tion suitable

for:

Smallest data amounts Medium to large data amounts

Small data amounts Small data amounts

Perf

orm

ance

Evaluation In case of static connections

In case of dynamic connections

Configuration effort None Low Medium Pogramming effort Medium Medium Medium

Connection of old systems ( S5 ) / third party systems

No No Yes

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 39/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Part 2 of the table

Table 2-16

FDL FMS Protocol Service

Criterion SDA SDN READ WRITE REPORT

Data range 1 -240 bytes 1 – 236 bytes 1 – 237 bytes PDU size*

1 – 233 bytes PDU size*

1 – 233 bytes PDU size*

Consistency Throughout the whole length Throughout the whole length 8 bytes throughout the whole length

Acknowledgement mechanism

Level 4 is implemented

--- Level 7 Implemented

---

Connected stations 1 – 1 bidirectional

1 – 1 bidirectional1 – n unidirectional

1 – 1 bidirectional

1 – 1 bidirectional 1 – n unidirectional

Configuration type Configured connection Bilaterally configured Connection type Stat connection Client / Client Stat connection Client / Client Stat connection

Client / Client Server / Client

Data connec-tion suitable

for:

Small data amounts Medium data amounts Small data amounts

Perf

or-

man

ce

Evaluation

Configuration effort Low Medium High Pogramming effort Medium High

Connection of old systems ( S5 ) / third party systems

Yes Yes

*= In case of FMS, it is important to consider the usable variable description rather than the one of the usable PDU size. By using structures, up to 76 structure elements can be packed up to a package and this package needs only a small amount of variable descriptions. (In this connection see manual: SIMATIC NET NCM S7 for PROFIBUS / FMS) In case of S7 and depending on the used CP, the amount of the variable description is built up as follows:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 40/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 2-17

Variable descriptions in the S7 S7-300 S7-400

Server variable descriptions 256 512 Partner variable descriptions 256 2640

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols. Some representative comparison values as an illustration:

Table 2-18

Protocol Data

S7 communication BSEND / BRECEIVE

FDL Service SDA

DP communication

Approx. 200 bytes

Approx. 95 ms Approx. 32 ms Approx. 79 ms from master to slave*

Approx. 39 ms from slave to master*

* The measured value for the DP protocol is based on a measurement with implemented level 7 acknowl-edgement via the user program of 2 stations. The typical DP cycle time is 3 ms.

These measurements are based on the following general requirements:

• Baudrate 1,5 MBit/s

• Bus profile standard

• Two stations at the bus

Application samples For this constellation, PROFIBUBS CP to CP connection, the following pre-coded examples have been created which are available in the Application Portal.

Table 2-19

Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20987358

This application is an automatic test program to exchange data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data ex-change between the stations. The application can recognize occurring mistakes and can react pur-posively (predetermined).

Data transfer via an FDL connection with SDA via AG_SEND / AG_RECV Entry-ID: 20987711

This application shows as to how a data transfer, which can transfer any data amount up to a maximum DB size, can be realized via a PROFIBUS and by using the FDL protocol. This transfer is made on acknowledged basis on level 2 and additionally on level 7 which has been realized within the application.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 41/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application title/ Entry-ID Description

Routing of data records reaching over the sub-network via a gateway CPU with S7 communi-cation (BSEND/BRECEIVE) Entry-ID: 20983154

By means of an fully programmed example, this application shows an implementation of a func-tioning routing of data records. Via a gateway station, configurable data are sent from one sta-tion to other, predefined stations being on an-other network.

Client / server communication with (I) Slaves via S7 basic communication (I_PUT/ I_GET) Entry-ID: 20987910

The Application on hand offers a simple, quick and practical learning startup into the cli-ent/server specifications of the I_PUT/ I_GET S7 basic communication service and shows how to deal with the configuration and user interfaces in the SIMATIC.

Data connection between separate DP systems via DP communication Entry-ID: 20987807

This application deals with a cost-effective trans-fer of data between two DP masters by using a DP slave CP 342-5. The DP additionally receives a data acknowledgement, which will be evaluated via the application.

Client server communication between WinAC Basis and S7 200 station via S7 communication (PUT/GET) Entry-ID: 20987586

This Application describes the synchronization of substations via a server station. When requested, the server station transfers up to 3 different data records to the substations.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 42/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.2.3 PB CPU – CPU connection

Connection case The task is to exchange data between two stations assigned to the same PROFIBUS.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-5 Both stations, station 1 and station 2, consist of one CPU respectively. The PROFIBUS is respectively connected to the integrated PROFIBUS inter-face of the stations. The data are to be transferred via this connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 43/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-20

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 (Here only server or slave)

S7 basis communication DP communication

S7 basis communication S7 communication (Client/Server) DP communication

S7 basis communication S7 communication (DP communication

S7 communication / DP communication

S7-300 S7 basis communication DP communication

S7 basis communication DP communication S7 communication (Client/Server)

S7 communication / DP communication

S7 communication / DP communication

S7-400 S7 basis communication DP communication

S7 basis communication S7 communication (DP communication

S7 communication / DP communication

S7 communication / DP communication

WinAC-Slot S7 communication / DP communication

S7 communication S7 communication

WinAC Basis/RTX (ab V 4.0)

S7 communication S7 communication S7 communication

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 44/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the PROFIBUS protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-21

S7 basic communication S7 communication ProtocolSevice

Criterion IPUT / IGET BSEND / BRCV USEND / URCV PUT / GET

DP communication

Data range 1 - 84 bytes / 1 - 94 bytes 1 – 32768 (S7-300) / 65535 (S7-400) bytes

1 – 165 bytes 1 – 165 bytes 1 – 244 bytes inputs / 1 – 244 bytes outputs

Consistency Only guaranteed when sending Throughout the whole length 8 bytes throughout the whole length

Between 122 bytes and whole length

Acknowledgement mechanism

Operating system of the controller Level 7 implemented

Operating system of the controller In the PROFIBUS ASIC implemented mechanism + level 7 implementation

via the user program Connected stations 1 – 1

bidirectional 1 – 1

bidirectional 1 – 1 unidirectional 1-1 bidirectional

Configuration type Non-configured connection Bilaterally configured Unilaterally configured Bilaterally configured Connection type Dyn. / stat connection Client / Server Stat connection Client / Client Stat. connection Client

/ Server Stat. connection Client / Server

Data connec-tion suitable

for:

Smallest data amounts Medium to large data amounts

Small data amounts Small data amounts

Perf

orm

ance

Evaluation In case of static connections

In case of static connections

Configuration effort None Low Medium Pogramming effort Medium Medium Medium

Connection of old systems ( S5 ) / third party systems

No No Yes

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 45/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols. Some representative comparison values as an illustration:

Table 2-22 Text

Protocol Data

S7 communication BSEND / BRECEIVE

DP communication

Approx. 200 bytes

Approx. 95 ms Approx. 79 ms from master to slave*Approx. 39 ms from slave to master*

* The measured value for the DP protocol is based on a measurement with implemented level 7 acknowl-edgement via the user program of 2 stations. The typical DP cycle time is 3 ms.

These measurements are based on the following general requirements:

• Baudrate 1.5 MBit/s

• Bus profile standard

• Two stations at the bus.

Application samples For this constellation, CPU – CP connection via PROFIBUS, the following pre-coded examples have been created which are available in the Applica-tion Portal.

Table 2-23

Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20983154

This application is an automatic test program to exchange data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data ex-change between the stations. The application can recognize occurring mistakes and can react pur-posively (predetermined).

Routing of data records reaching over the sub-network via a gateway CPU with S7 communi-cation (BSEND/BRECEIVE) Entry-ID: 20983154

By means of a fully programmed example, this application shows an implementation of a func-tioning routing of data records. Via a gateway station, configurable data are sent from one sta-tion to the other predefined station which is on another network.

Client / server communication with (I) Slaves via S7 basic communication (I_PUT/ I_GET) Entry-ID: 20987910

The Application on hand offers a simple, quick and practical learning startup into the cli-ent/server specifications of the I_PUT/ I_GET S7 basic communication service and shows how to deal with the configuration and user interfaces in the SIMATIC.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 46/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application title/ Entry-ID Description

Data connection between separate DP systems via DP communication Entry-ID: 20987807

This application deals with a cost-effective trans-fer of data between two DP masters by using a DP slave CP 342-5. The DP additionally receives a data acknowledgement, which will be evaluated via the application.

Client server communication between WinAC Basis and S7 200 station via S7 communication (PUT/GET) Entry-ID: 20987586

This Application describes the synchronization of substations via a server station. When requested, the server station transfers up to 3 different data records to the substations.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 47/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.2.4 PC Broadcast / Multicast

Connection case The task is to exchange data between any amounts of stations assigned to the same PROFIBUS.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-6 All stations, Station 1, Station 2 up to Station n, consist of respectively one CPU as well as a corresponding PROFIBUS communication processor. The PROFIBUS is connected to the respective PROFIBUS interface of the communication processor. Via this connection the data are to be trans-ferred from one station to all communication partners which can be ac-cessed.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 48/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-24

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 S7-300 FDL communication

(service FDL SDN Multi or Broadcast) FMS communication (FMS Broadcast)

FDL communication (service FDL SDN Multi or Broadcast) FMS communication (FMS Broadcast)

S7-400 FDL communication (service FDL SDN Multi or Broadcast) FMS communication (FMS Broadcast)

FDL communication (service FDL SDN Multi or Broadcast) FMS communication (FMS Broadcast)

WinAC-Slot WinAC Basis/RTX (as of V 4.0)

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 49/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the PROFIBUS protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-25

FDL FMS Protocol Service

Criterion SDN REPORT

Data range 1 – 236 bytes 1 – 233 bytes PDU size* Consistency Throughout the whole length 8 bytes throughout the whole

length Acknowledgement

mechanism --- ---

Connected stations 1 – n unidirectional 1 – n unidirectional Configuration type Configured connection Bilaterally configured Connection type Stat connection Client / Client Stat connection

Client / Client Server / Client

Data connec-tion suitable

for:

Small data amounts Small data amounts

Perf

or-

man

ce

Evaluation

Configuration effort Medium High Pogramming effort Medium High

Connection of old systems ( S5 ) / third party systems

Yes Yes

*= In case of FMS, it is important to consider the usable variable description rather than the one of the usable PDU size. By using structures, up to 76 structure elements can be packed up to a package and this package needs only a small amount of variable descriptions. (In this connection see manual: SIMATIC NET NCM S7 for PROFIBUS / FMS)

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 50/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 51/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.3 Industrial Ethernet

Introduction The following chapter shows successively all possible hardware constella-tions enabling a data transfer via the Industrial Ethernet.

Detailed bus description

You will find a detailed bus description of the bus system discussed here in the document “Selection criteria for networks and services”. http://support.automation.siemens.com/WW/view/en/21045102

Structure of the chapter The chapter Industrial Ethernet deals with the following 4 hardware con-stellations:

Table 2-26

Constellation Description

IE CPU-CP connection Industrial Ethernet communication between a central processing unit and a communication processor

IE CP-CP connection Industrial Ethernet communication between two communication processors

IE CPU-CPU connection Industrial Ethernet communication between two cen-tral processing units

IE Broadcast / Multicast Industrial Ethernet communication with multicast / broadcast functionalities

Overview of the constellations Each constellation is described by means of the following 4 information units:

• Description of the connection case

• The matrix of the hardware constellations

• The core information of the available protocols

• An overview of the available sample applications for this constellation

Advantages of this consideration This consideration enables the purposive selection of the hardware constel-lation and out of this the selection of the applicable protocol. All possible hardware constellations within the SIMATIC S7 family will be viewed in each constellation. The following overview of protocols enables a direct selection by comparing the functionalities of the applicable protocols.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 52/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.3.1 IE CPU – CP connection

Connection case The task is to exchange data between two stations connected via the Ethernet.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-7 Station 1 consists of a CPU which is directly connected to the Ethernet via an Ethernet Interface. Station 2 consists of CPU with the corresponding Ethernet communication processor. The data are to be transferred via this connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 53/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-27

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 S7 communication S7-300 S7 communication S7-400 S7 communication WinAC-Slot S7 communication WinAC Ba-sis/RTX (ab V 4.0)

S7 communication

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 54/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Overview of the properties of the Industrial Ethernet protocols With the following overview you can evaluate the properties of the applicable pro-tocols by means of chosen core properties.

Table 2-28 S7 communication Protocol

Service

Criterion BSEND / BRCV USEND / URCV PUT / GET

Data range 1 – 32768 / 65535 bytes 1

1 – 440 bytes 1 – 400 bytes

Dyn. data length Yes

Consistency Throughout the whole length 8 bytes throughout the whole length

Acknowledgement mechanism

Level 7 implemented

Operating system of the controller

Connected stations 1 – 1 bidirectional

1 – 1 unidirectional

Configuration type Bilaterally configured

Unilaterally config-ured

Connection type Stat connection Client / Client

Stat. connection Client / Server

Data connection suitable for:

Medium to large data amounts

Small data amounts

Perf

or-

man

ce

Evaluation Suitable for routing Yes

Configuration effort Low

Pogramming effort Medium

Connection of old systems ( S5 ) / third

party systems

No / No

Evaluating the performance of the used protocols The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols. Some representative comparison values as an illustration:

Table 2-29

Protocol Data

S7 communication BSEND / BRECEIVE

Approx. 200 bytes

Approx. 95 ms

These measurements are based on the following general requirements:

• Baudrate 100 MBit/s, full duplex

• Crossover cabling

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 55/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application samples For this constellation, CPU – CP connection via Industrial Ethernet, the fol-lowing pre-coded examples have been created which are available in the Application Portal.

Table 2-30

Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20987358

This application is an automatic test program to ex-change data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data exchange between the stations. The application can recognize occurring mistakes and can react purposively (predetermined).

Routing of data records reaching over the subnetwork via a gateway CPU with S7 communication (BSEND/BRECEIVE) Entry-ID: 20983154

By means of a fully programmed example, this appli-cation shows an implementation of a functioning routing of data records. Via a gateway station, con-figurable data are sent from one station to the other predefined station which is on another network.

Client server communication between WinAC Basis and S7 200 station via S7 communica-tion (PUT/GET) Entry-ID: 20987586

This Application describes the synchronization of substations via a server station. When requested, the server station transfers up to 3 different data records to the substations.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 56/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.3.2 IE CP – CP connection

Connection case The task is to exchange data between two stations containing an Ethernet CP.

Hardware scheme This hardware constellation is made up as follows:

CPU-1 CPU-2

Station1 Station2

IE

DBWxy DBWxy

CP IExCP IEx

Figure 2-8 Both systems, Station 1 and station 2, respectively consist of a CPU with the corresponding Ethernet communication processor. The data are to be transferred between both systems via this connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 57/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. Further information on possible protocols is available on the next page.

Table 2-31

Station1Station2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (as of V 4.0)

S7-200 S7 communication S7 communication (loadable PBK functions)

S7 communication S7 communication S7 communication

S7-300 S7 communication S7 communication (loadable PBK functions) ISO transport protocol TCP protocol ISO on TCP protocol UDP protocol

S7 communication ISO transport protocol TCP protocol ISO on TCP protocol UDP protocol

S7 communication S7 communication

S7-400 S7 communication S7 communication (loadable PBK functions) ISO transport protocol TCP protocol ISO on TCP protocol UDP protocol

S7 communication ISO transport protocol TCP protocol ISO on TCP protocol UDP protocol

S7 communication S7 communication

WinAC-Slot S7 communication S7 communication (loadable PBK functions)

S7 communication S7 communication S7 communication

WinAC Basis/RTX (ab V 4.0)

S7 communication S7 communication (loadable PBK functions)

S7 communication S7 communication S7 communication

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 58/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the Industrial Ethernet protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-32 S7 Communication Protocol

Service

Criterion

ISO Transport Protocol

ISO on TCP Protocol

TCP Protocol UDP Protocol

BSEND/ BRCV

USEND / URCV PUT / GET

Data range 1 – 8192 bytes 1 – 8192 bytes 1 – 8192 bytes 1 – 2048 bytes 1 – 32768 / 65535 bytes 1

1 – 440 bytes 1 – 400 bytes

Dyn. data length Yes Yes No Yes Yes

Consistency Throughout the whole length

Throughout the whole length

Throughout the whole length

Throughout the whole length

Throughout the whole length 8 bytes throughout the whole length

Acknowledgement mechanism

Level 4 implemented

Level 4 implemented

Level 4 implemented

--- Level 7 implemented

Operating system of the controller

Connected stations 1 – 1 bidirectional

1 – 1 bidirectional

1 – 1 bidirectional 1 – x broadcast only

sending

1 – 1 unidirectional/ bidirectional

1 – n multicast bidirec-tional

1 – x broadcast only sending

1 – 1 bidirectional

1 – 1 unidirectional

Configuration type Unilaterally / bilaterally configured

Unilaterally / bilaterally configured

Unilaterally / bilaterally configured

Unilaterally / bilaterallyconfigured

Bilaterally configured

Unilaterally config-ured

Connection type Stat connection Client / Client

Stat connection Client / Client

Stat connection Client / Client

Stat connection Client / Client

Stat connection Client / Client

Stat. connection Client / Server

Data connection suitable for:

Small – medium data amounts

Small – medium data amounts

Small – medium data amounts

Small data amounts Medium to large data amounts

Small data amounts

Perf

or-

man

ce

Evaluation Suitable for routing No Yes Yes Yes Yes

Configuration effort Low Low Low Medium Low

Pogramming effort Medium Medium High Medium, when acknowl-edging high

Medium

Connection of old systems ( S5 ) / third

party systems

Yes / No Yes (conditional) 2 / Yes (conditional)

Yes (conditional) 2 / Yes Yes (conditional) 2 / Yes No / No

1 : Depending on the used controller ; 2 : When using the CP 1430 TCP

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 59/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Evaluation of the performance by means of the available applications The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols. A representative comparison value as an illustration:

Table 2-33

Protocol Data

ISO on TCP protocol UDP protocol S7 communication with theservice “BSEND / BRECV“

2048 bytes Approx. 90 ms Approx. 105 ms Approx. 700 ms * The measured value for the UDP is based on a measurement with implemented level 7 acknowledgement via the user program of 2 stations.

These measurements are based on the following general requirements:

• Used bus profile: 100 MBit full duplex

• Connection via a connection, except the UDP result, as a partially defined connection is used as an acknowledgement mechanism of both partner stations.

• The acknowledgement mechanisms of level 4 or 7 are used; in this case, a simple acknowledgement mechanism has been subsequently implemented into the program for the UDP protocol.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 60/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application samples For this constellation, CPU – CP connection via Industrial Ethernet, the fol-lowing pre-coded examples have been created which are available in the Application Portal.

Table 2-34 Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20987358

This application is an automatic test program to ex-change data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data exchange between the stations. The application can recognize occurring mistakes and can react purposively (predetermined).

Comparison of data transfer via one and via four parallel ISO-on-TCP connections on Industrial Ethernet Entry-ID: 20987359

This Application deals with a comparison between the sending of a variable data record via one or four Ethernet connections.

Master-slave communication via Ethernet with UDP using multicast and unspecified connections Entry-ID: 20983558

This application shows how to realize an acknowl-edged data transfer to a number of bus stations (stations) which are variable and dynamically changeable during runtime via Industrial Ethernet and UDP without having to modify the configuration / programming for each station. The master generates multicast messages; the reception of these mes-sages is acknowledged by the slaves by means of unspecified connections.

Routing of data records reaching over the subnetwork via a gateway CPU with S7 communication (BSEND/BRECEIVE) Entry-ID: 20983154

By means of a fully programmed example, this appli-cation shows an implementation of a functioning routing of data records. Via a gateway station, con-figurable data are sent from one station to the other predefined stationwhich is on another network.

Client server communication between WinAC Basis and S7 200 station via S7 communica-tion (PUT/GET) Entry-ID: 20987586

This Application describes the synchronization of substations via a server station. When requested, the server station transfers up to 3 different data records to the substations.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 61/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.3.3 IE CPU – CPU connection

Connection case The task is to exchange data between two stations respectively containing an on-board Ethernet interface.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-9 Both systems, Station 1 and station 2, respectively consist of a CPU with integrated Ethernet communication interface. The data are to be transferred between both systems via this connection.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 62/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-35

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 S7-300 S7 communication S7-400 WinAC-Slot WinAC Basis/RTX (as of V 4.0)

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 63/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Overview of the properties of the Industrial Ethernet protocols With the following overview you can evaluate the properties of the applicable pro-tocols by means of chosen core properties.

Table 2-36 S7 communication Protocol

Service

Criterion BSEND / BRCV USEND / URCV PUT / GET

Data range 1 – 32768 / 65535 bytes 1

1 – 440 bytes 1 – 400 bytes

Dyn. data length Yes

Consistency Throughout the whole length 8 bytes throughout the whole length

Acknowledgement mechanism

Level 7 implemented

Operating system of the controller

Connected stations 1 – 1 bidirectional

1 – 1 unidirectional

Configuration type Bilaterally configured

Unilaterally config-ured

Connection type Stat connection Client / Client

Stat. connection Client / Server

Data connection suitable for:

Medium to large data amounts

Small data amounts

Perf

or-

man

ce

Evaluation Suitable for routing Yes

Configuration effort Low

Pogramming effort Medium

Connection of old systems ( S5 ) / third

party systems

No / No

Evaluating the performance of the evaluated protocols The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal and of previous experiences when using protocols. Some representative comparison values as an illustration:

Table 2-37

Protocol Data

S7 communication BSEND / BRECEIVE

Approx. 200 bytes

Approx. 95 ms

These measurements are based on the following general requirements:

• Baudrate 100 MBit/s, full duplex

• Crossover cabling

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 64/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.3.4 IE Broadcast / Multicast

Connection case The task is to exchange data between two or several stations respectively containing an Ethernet interface.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-10 Each of these systems, Station 1, Station 2 up to Station n, respectively consists of a CPU as well as an Ethernet communication processor. Via these connections between the different systems, a transmitter should transfer data to all other systems.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 65/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-38

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 S7-300 UDP protocol

(UDP multicast) UDP protocol (UDP multicast)

S7-400 UDP protocol (UDP multicast)

UDP protocol (UDP multicast)

WinAC-Slot WinAC Basis/RTX (as of V 4.0)

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 66/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Overview of the properties of the Industrial Ethernet protocols With the following overview you can evaluate the properties of the applicable pro-tocols by means of chosen core properties.

Table 2-39 Protocol

Criterion UDP Protocol

Data range 1 – 2048 bytes

Dyn. data length Yes

Consistency Throughout the whole length

Acknowledgement mechanism

---

Connected stations 1 – n multicast bidirectional1 – x broadcast only sending

Configuration type Unilaterally / bilaterally configured

Connection type Stat connection Client / Client

Data connection suitable for:

Small data amounts

Perf

or-

man

ce

Evaluation Suitable for routing Yes

Configuration effort Medium

Pogramming effort Medium, when acknowledg-ing high

Connection of old systems ( S5 ) / third

party systems

Yes (conditional) 2 / Yes

Evaluation of the performance by means of the available applications The evaluation of the performance statement of the above table is made on the basis of the available measurements resulting from the communication examples in the Application Portal. A representative comparison value as an illustration:

Table 2-40

Protocol Data

UDP protocol

2048 bytes Approx. 105 ms * The measured value for the UDP is based on a measurement with implemented level 7 acknowledgement via the user program of 2 stations.

These measurements are based on the following general requirements:

• Used bus profile: 100 MBit full duplex

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 67/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application samples For this constellation, multicast/broadcast communication via Industrial Ethernet, the following pre-coded examples have been created which are available in the Application Portal.

Table 2-41

Application title/ Entry-ID Description

Master-slave communication via Ethernet with UDP using multicast and unspecified connections Entry-ID: 20983558

This application shows how to realize an acknowl-edged data transfer to a number of bus stations (stations) which are variable and dynamically changeable during runtime via Industrial Ethernet and UDP without having to modify the configuration / programming for each station. The master generates multicast messages; the reception of these mes-sages is acknowledged by the slaves by means of unspecified connections.

Back to the bus-oriented selection aid

2.4 Serial Interface

Introduction The following chapter shows successively all possible hardware constella-tions enabling a data transfer via the serial interfaces.

Detailed bus description

You will find a detailed bus description of the bus system discussed here in the document “Selection criteria for networks and services”. http://support.automation.siemens.com/WW/view/en/21045102

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 68/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Structure of the chapter The chapter Serial Interfaces deals with the following two hardware constel-lations:

Table 2-42

Constellation Description

PtP connection PtP connection between two stations PtP multicast / broadcast PtP communication with multicast / broadcast func-

tionality

Overview of the constellations Each constellation is described by means of the following 4 information units:

• Description of the connection case

• The matrix of the hardware constellations

• The core information of the available protocols

• An overview of the available sample applications for this constellation

Advantages of this consideration This consideration enables the purposive selection of the hardware constel-lation and out of this the selection of the applicable protocol. All possible hardware constellations within the SIMATIC S7 family will be viewed in each constellation. The following overview of protocols enables a direct selection by comparing the functionalities of the applicable protocols.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 69/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.4.1 PtP- connection

Connection case The task is to exchange data between two stations connected via a serial interface.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-11 Both stations, station 1 and station 2, respectively consist of a CPU and communication processor with serial interface. Both stations are physically connected with each other by means of the same type of serial interface of the respective DP via an adequate connection cable. The data are trans-ferred via the available interface variants and the protocol driver available for it.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 70/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-43

Station 1 Station 2

S7-200 RS 485(RS 232), modem

S7-300 RS 232, TTY, RS 422/485

S7-400 RS 232, TTY, RS 422/485

S7-200 Free ASCII protocol Free ASCII protocol Modbus (via modem)

Free ASCII protocol Modbus (via modem)

S7-300 Free ASCII protocol ASCII 3964(R) RK512 loadable driver (e.g.: Mod-bus, Data Highway)

ASCII 3964(R) RK512 loadable driver (e.g.: Modbus, Data Highway)

S7-400 Free ASCII protocol ASCII 3964(R) RK512 loadable driver (e.g.: Mod-bus, Data Highway)

ASCII 3964(R) RK512 loadable driver (e.g.: Mod-bus, Data Highway)

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 71/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the serial protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-44

Modbus ProtocolCriterion

ASCII RK 512 3964(R)

Master Slave

Data Highway

Data range 1 – 1024 bytes 1 – 1024 bytes 1 – 1024 bytes 1 – 255 bytes 4 – 1024 / 4096 bytes (300/400)

Connected stations 1 – 1bidirectional 1 – 1bidirectional 1 – 1bidirectional 1 – 1bidirectional 1 – 1bidirectional

S7-200 1.2 kBit/s – 38.4 kBit/s1 No No No Yes (via modem)

No

S7-300 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s

S7-400 300 Bit/s – 115.2 kBit/s 300 Bit/s – 115.2 kBit/s 300 Bit/s – 115.2 kBit/s 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s RS2

32

Bridgeable distance 15 m 15 m 15 m 15 m 15 m

S7-200 No No No No No

S7-300 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s

S7-400 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s 300 Bit/s – 19.2 kBit/s

20m

A T

TY

Bridgeable distance 1000m 1000m 1000m 1000m 1000m

S7-200 300 Bit/s – 38.4 kBit/s No No No No

S7-300 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s2 300 Bit/s – 76.8 kBit/s2 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s

S7-400 300 Bit/s – 115.2 kBit/s 300 Bit/s – 115.2 kBit/s2 300 Bit/s – 115.2 kBit/s2 300 Bit/s – 76.8 kBit/s 300 Bit/s – 76.8 kBit/s RS4

22 /

RS4

85

Bridgeable distance 1200 m 1200 m 1200 m 1200 m 1200 m

Data connection suitable for:

Small – medium data amounts Small – medium data amounts Small – medium data amounts Small data amounts Small – medium data amounts

Perf

orm

ance

Evaluation

Configuration effort Low Low Low High Medium

Pogramming effort Medium Medium Medium High Medium

Connection of old systems ( S5 ) / third

party systems

Yes / Yes Yes / Yes Yes / Yes Yes / Yes Yes / Yes

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 72/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

1 ) Can be achieved when using the PC/PPI cable. 2 ) RS485 is not applicable here.

Evaluation of the performance The evaluation of the performance statement of the above table is made on the basis of the experiences relating to these protocols.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 73/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.4.2 PtP Multicast / Broadcast

Connection case

The task is to exchange data from one station to several stations connected via a serial interface.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-12 The stations, Station 1, Station 2 up to Station n, respectively consist of one CPU as well as a serial communication processor. All stations are physi-cally connected with each other via the serial interface. The data are trans-ferred via the respectively available interface variants and the available pro-tocol driver.

Note: Possible interfaces Only the interfaces of type RS 485 / 422 can be used for multi-point applications without any further technical installation.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 74/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-45

Station 1 Station 2 - n

S7-200 RS 485 SS

S7-300 RS 232, TTY, RS 422/485

S7-400 RS 232, TTY, RS 422/485

S7-200 via ´modem Loadable driver (e.g. Mod-bus Master Broadcast)

Loadable driver (e.g. Mod-bus Master Broadcast)

S7-300 Loadable driver (e.g. Mod-bus Master Broadcast)

Loadable driver (e.g. Mod-bus Master Broadcast)

S7-400 Loadable driver (e.g. Mod-bus Master Broadcast)

Loadable driver (e.g. Mod-bus Master Broadcast)

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 75/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Overview of the properties of the serial protocols With the following overview you can evaluate the properties of the applica-ble protocols by means of chosen core properties.

Table 2-46

Modbus Protocol Criterion Master

Data range 1 – 255 bytes

Connected stations 1 – 1bidirectional

S7-200 No

S7-300 300 Bit/s – 76.8 kBit/s

S7-400 300 Bit/s – 76.8 kBit/s RS2

32

Bridgeable distance 15 m

S7-200 No

S7-300 300 Bit/s – 19.2 kBit/s

S7-400 300 Bit/s – 19.2 kBit/s

20m

A T

TY

Bridgeable distance 1000m

S7-200 No

S7-300 300 Bit/s – 76.8 kBit/s

S7-400 300 Bit/s – 76.8 kBit/s RS4

22 /

RS4

85

Bridgeable distance 1200 m

Data connection suitable for:

Small data amounts

Perf

or-

man

ce

Evaluation

Configuration effort High

Pogramming effort High

Connection of old systems ( S5 ) / third

party systems

Yes / Yes

Evaluation of the performance The evaluation of the performance statement of the above table is made on the basis of the experiences relating to these protocols.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 76/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.5 SIMATIC backplane bus

Introduction The following chapter shows successively all possible hardware constella-tions enabling a data transfer via the SIMATIC backplane bus.

Detailed bus description

You will find a detailed bus description of the bus system discussed here in the document “Selection criteria for networks and services”. http://support.automation.siemens.com/WW/view/en/21045102

Structure of the chapter The chapter SIMATIC backplane bus deals with the following hardware constellation:

Table 2-47

Constellation Description

Backplane connection Backplane bus communication between two sta-tions (CPUs)

Overview of the constellations Each constellation is described by means of the following 4 information units:

• Description of the connection case

• The matrix of the hardware constellations

• The core information of the available protocols

• An overview of the available sample applications for this constellation

Advantages of this consideration This consideration enables the purposive selection of the hardware constel-lation and out of this the selection of the applicable protocol. All possible hardware constellations within the SIMATIC S7 family will be viewed in each constellation. The following overview of protocols enables a direct selection by comparing the functionalities of the applicable protocols.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 77/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

2.5.1 Backplane connection

Connection case The task is to exchange data within a station equipped with several CPUs.

Hardware scheme This hardware constellation is made up as follows:

Figure 2-13 The station consists of two or several CPUs. All CPUs are physically con-nected with each other via the backplane bus. The data are exclusively transferred via the backplane bus.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 78/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Which protocols can I use with this constellation? The following table shows all applicable protocols for the respective hardware constellations. The following page provides further details of the protocols possible here.

Table 2-48

Station 1Station 2

S7-200 S7-300 S7-400 WinAC-Slot WinAC Basis/RTX (ab V 4.0)

S7-200 S7-300 S7-400 S7 basis communication

S7 communication global data

WinAC-Slot WinAC Basis/RTX (as of V 4.0)

= not applicable

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 79/185

Copyright © Siemens AG 2005 All rights reserved 20982954_SIMATIC_Comm_DOKU_v10_e

Overview of the properties of the possible backplane bus protocols With the following overview you can evaluate the properties of the applicable protocols by means of chosen core properties.

Table 2-49

S7 basic communication S7 communication ProtocolService

Criterion XPUT / XGET XSEND / XRECV BSEND / BRCV USEND / URCV PUT / GET

Global data

Data range 1 - 84 bytes 1 -76 bytes 1 – 32768 (S7-300) / 65535 (S7-400) bytes

1 – 165 bytes 1 – 165 bytes 1 - 22 bytes (S7-300) / 1 - 64 bytes (S7-400)

Consistency Only guaranteed when sending

Yes Throughout the whole length 8 bytes throughout the whole length

Yes

Acknowledgement mechanism

Operating system of the controller Level 7 implemented

Operating system of the controller Operating system of the controller

Connected stations 1 – 1 unidirectional 1 – 1 bidirectional

1 – 1 bidirectional 1 – 1 unidirectional 1-1 / 1-n bidirectional

Configuration type Non-configured connection Bilaterally configured Unilaterally config-ured

Bilaterally configured

Connection type Dyn. / stat connection Client / Server

Dyn. / stat connection Client / Client

Stat connection Client / Client

Stat. connection Client / Server

Stat connection Client / Client

Data connec-tion suitable

for:

Small data amounts Medium to large data amounts

Small data amounts Smallest data amounts

Perf

orm

ance

Evaluation In case of static connections

In case of dynamic connections

Configuration effort None Low Medium Pogramming effort Medium Medium Medium

Connection of old systems ( S5 ) / third party systems

No No No

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 80/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Evaluation of the performance of the used protocols The evaluation of the performance statement of the above table is partly made on the basis of the available measurements resulting from the com-munication examples in the Application Portal and partly on the basis of previous experiences when using protocols.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 81/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3 Protocol Description

The following chapter contains a collection of protocol descriptions of fre-quently used protocols supported by SIMATIC S7. The protocol descriptions on hand are divided into the following four groups:

Table 3-1

Group Group Name Description

1 Protocols within SIMATIC S7

Contains a description of the protocols based on SIMATIC S7.

2 Industrial Ethernet Introduces the standard Ethernet proto-cols supported by SIMATIC S7.

3 PROFIBUS Introduces the standard PROFIBUS protocols supported by SIMATIC S7.

4 Serial Protocols At last, all of the serial interface protocols supported by SIMATIC are described, except for the printer driver.

Each group consists of:

• A description of the bus system or the communication system, as well as

• a number of protocol descriptions which partly are further divided into operating descriptions.

Structure of the protocol descriptions If possible, each protocol description should contain the following sections:

• A protocol description with ○ the development history or a description of the origins of the protocol ○ the advantages and disadvantages of this protocol

• The services and properties of this protocol

• A rough overview of the necessary configuration steps

• Description of the user interface

• Statements on the performance of the protocol (is available)

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 82/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1 Protocols within SIMATIC S7

Introduction Within the framework of developing the automation system SIMATIC S7, communication capability of the system was as much an issue as develop-ment of new hardware components and a new programming software ap-proach. Concepts which were successfully used for S5 were considered as well as new approaches and communication principles necessary due to the modularity of the system. Some of these principles and services are also available to the SIMATIC S7 user. The following chapter discusses the resulting user interfaces.

Properties of the communication model within SIMATIC S7 In SIMATIC S7 the following protocols were developed with their services for transferring data within or between the controllers:

• Global data

• S7 basic communication

• S7 communication Due to the fact that these protocols are not hardware specific, they can also be used with different bus systems of the used CPUs. In order to provide an overview of the various communication paths of the protocols developed for SIMATIC S7 within and outside of SIMATIC S7, a brief overview of the protocols is given here with regards to the used media.

Table 3-2

Protocol Bus system

Global data S7 basic com-munication

S7 communica-tion

P-bus (I/O bus)

--- Yes ---

K-bus (Communication bus)

Yes Yes Yes

MPI-bus Yes Yes Yes

PROFIBUS --- Yes (DP) Yes

Industrial Ethernet --- --- Yes

Yes = available; --- = not available

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 83/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Where are the protocols processed ? An overview of the processing location for the protocol depending on the applicable system family is given for a better understanding of the function-ality.

Table 3-3

Protocol Family

Global data S7 basic communica-tion

S7 communication

S7-200 --- CPU (Server) CPU (Server) CP (Client / Server)

S7-300 CPU CPU CPU (Server) CP (Client / Server)

S7-400 CPU CPU CPU WinAC-Slot CPU CPU CPU

WinAC-Basis --- --- PC-CPU (Software) CP-CPU

It is apparent from this table that the communication load is mainly covered by the CPU. The communication processors are employed in the module families whose CPUs are not capable of taking over client functions for the respective protocols. Here, the communication processors are used as pro-tocol gateway.

Overview of the protocols The following chapter deals with the system protocols available within SIMATIC S7 for the data communication between logic controllers. The fol-lowing protocols are considered together with their services:

Table 3-4

Chapter Protocol

3.1.1 Global data 3.1.2 S7 basic communication (MPI, PB_DP) 3.1.3 S7 communication (IE, PB, MPI)

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 84/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.1 Global data

Basic characteristics Global data communication enables cyclic data exchange between CPUs via the MPI interface or the communication bus (C-bus) of S7-400 respec-tively. Data exchange occurs cyclic during updating the process image of the inputs and outputs. On top of cyclic transmission, the S7-400 also enables event controlled data transmission via default function blocks. This requires functions for the sending or receiving of data to be called within the application. The data to be transferred are statically defined within the program and can be transferred consistently to various global data groups, i.e. defined groups of stations exchanging global data. With max. 22 bytes (S7-300) and max. 54 bytes (S7-400) the amount of data to be transferred is rather low. The data itself can only be transferred to modules which were param-eterized in the same project and use either the same communication bus at the backplane bus (C-bus) or MPI-bus.

Services of the protocol The global data communication supports the following services:

• cyclic data transmission The cyclic data transmission includes all configured global data groups. Transmission occurs at the time of updating the process image.

• GD_SND, GD_RCV With the GD_SND and GD_RCV modules, the S7-400 can transfer global data packages using event controlled data-transmission. To do this, the modules require the number of the global data group as well as the global data package number.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 85/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Advantages and disadvantages of global data communication The following advantages and disadvantages arise from using this protocol:

Table 3-5

Advantages 1 Simple communication configuration 2 The transfer is consistent.

Disadvantages

1 Only applicable in homogenous SIMATIC S7 structures 2 Only static data transmission possible. 3 Only suitable for smallest data amounts (< 60 bytes) 4 Global data are unacknowledged data.

Advantages and disadvantages when using global data communication The following list contains the configuration steps necessary for global data communication.

Table 3-6

Configuration step Engineering-Tool What to do

1. Hardware configura-tion of the station

HW Config In the hardware configuration the modules of the individual stations are parameterized. The CPU modules are connected via networking the MPI interface by selecting the MPI buss, or via the backplane bus.

2. Open “Global Data Definition”

S7-Manager Open the Global data editor in the S7 manager by selecting the MPI-bus in the root of the project and selecting the “Define Global Data“ item via the context menu (right mouse-button).

3. Define Global Data Global data editor Enter the stations in the column head-ers. Within the table you can now de-fine the source and target sections of the individual stations. After the con-figuration has been completed, com-pile the data and load all stations with the new configuration.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 86/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

User interface of the S7-400 GD_SND / GD RCV The following section explains the SIMATIC function interface for event controlled data transmission of global data communication .

GD_SND

Figure 3-1

Table 3-7

Parameter Note

CIRCLE_ID Number of GD group to which the GD packet is to be sent.

BLOCK_ID Number of GD packet to be sent in the GD circle. RET_VAL Error information

GD_RCV

Figure 3-2

Table 3-8

Parameter Note

CIRCLE_ID Number of GD group from which the GD packet is to be received.

BLOCK_ID Number of GD packet to be received in the selected GD group.

RET_VAL Error information

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 87/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Note Detailed information of the parameters of the user interface and its usage is avail-able in the STEP 7 online help.

Scope of global data communication

Table 3-9

Characteristic Range of values

Data range per GD packet 1 – 22 bytes (S7-300) 1 - 64 bytes (S7-400)

Interface Cyclic data exchange at the time of process image update, or event controlled data transfer

via function block (only S7-400). Number of possible GD groups max. 4 to 16 depending on S7-300 CPU,

max. 16 to 32 depending on S7-400 CPU, Number of possible GD pack-ets

4 / 4 to 16 / 8 (sending / receiving) depending on S7-300 CPU

8 / 32 to 16 / 16 (sending / receiving) depending on S7-400 CPU

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 88/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.2 S7 basic communication (MPI, PB_DP)

Basic characteristics In the product life of the first S7-300 versions, the demand for an active communication option became apparent. This active communication option was created within the framework of the continued development of the S7-300 by introducing the S7 basic communication. The S7 basic communication refers to not configured data connections, which transfer data either via the MPI-bus or the PROFIBUS DP. The used connections are dynamic, i.e. they are generated by the application and can also be released again.

Services of the protocol The S7 basic communication has two groups of services, which are used depending on the respective bus system:

• I_PUT / I_GET This service enables reading and writing data of an I-Slave connected to the PROFIBUS DP.

• X_PUT / X_GET or X_SEND / X_RCV This service enables reading or writing data of another MPI or backplane bus station, as well as enabling a coordinated data transfer via the X_SEND / X_RCV functions.

Note Cancel functions are also provided for the connections used by both services, however, as these are not directly involved in the data transfer, they are not further discussed in this document. Further information on these functions are available in the “STEP 7 – System and standard functions for S7-300 and S7-400“ as well as the STEP 7 Online help.

Description of the services The services of the S7 basic communication are individually explained in the following chapters.

Table 3-10

Chapter Service

3.1.2.1 I functions 3.1.2.2 X-functions

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 89/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.2.1 I functions

Basic properties of the service The I-functions enable reading or writing data located on modules which are part of the own station or part of an intelligent distributed I/O sta-tion. The communication partner must be assigned to the station it is ad-dressed by. As this communication type is merely based on a client – server principle, no function call to the communication partner is necessary on the server side. The dynamic connection, set up at the first call of the communication block, can be closed after completing the data transfer, hence be discon-nected. If it is not closed, further communication calls can be processed quicker as no reconnection is necessary.

Note The I-Abort function is available for disconnecting connections used for I-functions. This function is described in the “STEP 7 - System and standard func-tions for S7-300 and S7-400“ manual.

Advantages and disadvantages of I-functions The following advantages and disadvantages arise from using these func-tions:

Table 3-11

Advantages 1 No communication configuration necessary. 2 Dynamic and variable data transfer possible. 3 Connection resources can be controlled by the application in the

logic controller. Disadvantages

1 Only applicable in homogenous SIMATIC S7 structures 2 The transfer is inconsistent. 3 Only suitable for small data amounts (< 100 bytes)

Configuration of I-functions The I-functions themselves need not be configured. The basis of these functions are the hardware addresses configured in the hardware configuration. These are necessary for each communication partner. For parameterizing the module, it is furthermore necessary to know whether the addressed module is a module with inputs or outputs.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 90/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Other details are not necessary.

The user interface The following section explains the function interfaces of the I-functions in SIMATIC S7.

I_PUT

Figure 3-3

Table 3-12

Parameter Note

REQ Job trigger for the PUT job CONT Parameter for determining whether the connection

should be maintained after completing the job, or whether it should be disconnected.

IOID Identifier of the address range of the partner module LADDR Logic address of the partner module in the address

section of the CPU. VAR_ADDR Reference to the target data area of the partner mod-

ule. SD Reference to the source data area of the local CPU

RET_VAL Error information if an error occurs in the course of the function.

BUSY Status information of the function being actively per-formed.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 91/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

I_GET

Figure 3-4

Table 3-13

Parameter Note

REQ Job trigger for the GET job CONT Parameter for determining whether the connection

should be maintained after completing the job or whether it should be disconnected.

IOID Identifier of the address range of the partner module LADDR Logic address of the partner module in the address

section of the CPU. VAR_ADDR Reference to the source data area in the partner mod-

ule. RET_VAL Error information if an error has occurred in the course

of the function. BUSY Status information of the function being actively per-

formed. RD Reference to the target data area in the local CPU

Note Detailed information on the parameters of the user interface and their usage is available in the STEP 7 online help or the “STEP 7 - System and standard func-tions for S7-300 and S7-400“ manual.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 92/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Scope of the I-functions

Table 3-14

Characteristic Range of values

Data area per job 1 - 84 bytes (I_PUT) / 1 - 94 bytes (I_GET) Interface Level 7 of the ISO/OSI-reference model Number of connection re-sources

0 - 12 connections depending on CPU and setting (S7-300)

16 -64 connections depending on CPU (not select-able) (S7-400)

Application examples For this protocol, a pre-coded example was created.

Table 3-15

Application title/ Entry-ID Description

Client / server communication with (I) Slaves via S7 basic communication (I_PUT/ I_GET) Entry-ID: 20987910

This Application is meant to help the user to simply, quickly and practically learn about the client/server specifics of the I_PUT/ I_GET S7 basic communica-tion service. It also shows the user how to deal with the configuration and user interfaces within SIMATIC.

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 93/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.2.2 X-functions

Basic properties of the service The X-functions enable reading or writing data located on modules which are located at the same communication or MPI bus. Furthermore, this service provides functions for a coordinated data exchange via send and receive blocks. The combination of

• Client-Server principle and

• Client-Client principle provides a large variety of application options. The X-functions, as well as the I-functions, are capable of managing con-nections dynamically. Connections established during the function call can be disconnected after the communication has been completed, or be main-tained. The next communication call can hence be processed more quickly, as a connection needs not be set up.

Note The X-Abort function is available for disconnecting connections used for X-functions. This function is described in the “STEP 7 - System and standard func-tions for S7-300 and S7-400“ manual.

Advantages and disadvantages of X-functions The following advantages and disadvantages arise from using these func-tions:

Table 3-16

Advantages 1 No communication configuration necessary. 2 Dynamic and variable data transfer possible 3 Connection resources can be controlled by the application. 4 Client–Server as well as Client–Client services are possible.

Disadvantages

1 Only applicable in homogenous SIMATIC S7 structures 2 Inconsistent transmission with X_PUT / X_GET functions. 3 Only suitable for small data amounts (< 100 bytes)

Configuration of X-functions The X-functions themselves need not be configured.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 94/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The basis of these functions are the MPI addresses configured in the hard-ware configuration. They are necessary for each communication partner. Other details are not necessary.

The user interface The user interfaces of the X-functions can be divided into 2 groups:

• Client-Server functions

• Client-Client functions The difference between both groups lies in the application of the function blocks at the connected stations. Client-Server functions exclusively supply modules which actively access other, connected stations. Client-Client functions are executed on both sides of the connection in or-der to provide a coordinated data exchange.

Client-Server function X-PUT

Figure 3-5

Table 3-17

Parameter Note

REQ Job trigger for the PUT job CONT Parameter for determining whether the connection

should be maintained after completing the job, or whether it should be disconnected.

DEST_ID The MPI address of the partner module configured in STEP 7.

VAR_ADDR Reference to the target data area in the partner mod-ule.

SD Reference to the source data area in the local CPU RET_VAL Error information if an error has occurred in the course

of the function. BUSY Status information of the function being actively per-

formed.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 95/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Client-Server function X-GET

Figure 3-6

Table 3-18

Parameter Note

REQ Job trigger for the GET job CONT Parameter for determining whether the connection

should be maintained after completing the job, or whether it should be disconnected.

DEST_ID The MPI address of the partner module configured in STEP 7.

VAR_ADDR Reference to the source data area in the partner mod-ule.

RET_VAL Error information if an error has occurred in the course of the function.

BUSY Status information of the function being actively per-formed.

RD Reference to the target data area in the local CPU

Client-Client function X-SEND

Figure 3-7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 96/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-19

Parameter Note

REQ Job trigger for the SEND job CONT Parameter for determining whether the connection

should be maintained after completing the job, or whether it should be disconnected.

DEST_ID The MPI address of the partner module configured in STEP 7.

REQ_ID Job identifier for identifying the data at the communica-tion partner

SD Reference to the source data area in the local CPU RET_VAL Error information if an error has occurred in the course

of the function. BUSY Status information of the function being actively per-

formed.

Client-Client function X-RCV

Figure 3-8

Table 3-20

Parameter Note

EN_DT The control parameter “enable data transfer“ enables controlling the data transfer.

RET_VAL Error information if an error has occurred in the course of the function.

REQ_ID Received job identifier for identifying the data at the sender

NDA Status parameter indicating the value “True” if new data has been received .

RD Reference to the target data area in the local CPU

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 97/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Special properties of the X_RCV block The X_RCV system function block enables buffering several received tele-grams. This enables selective processing of individual messages via the parameter EN_DT.

Note Further detailed information on the parameters of the user interface and its usage is available in the STEP 7 online help or the following manual: “STEP 7 - System and standard functions for S7-300 and S7-400“.

Quantity frameworks

Table 3-21

Characteristic Range of values

Data area per job 1 - 76 bytes Interface Level 7 of the ISO/OSI-reference model Number of connection re-sources

0 - 12 connections depending on CPU and set-ting (S7-300)

16 -64 connections depending on CPU (not selectable) (S7-400)

Application examples For this protocol, a pre-coded example was created.

Table 3-22

Application title/ Entry-ID Description

N to 1 Synchronization of Data in the MPI Network via S7 Basic Communication (X_SEND/ X_RCV) Entry-ID: 20989875

This Application describes synchronizing a system of four S7-300 stations. After a trigger pulse at a digital input three to four S7 stations send data to a fourth station via a dynamic connection, the defined master.

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 98/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.3 S7 communication (IE, PB, MPI)

Basic characteristics Within SIMATIC S7, the S7 protocol was designed as a standard protocol for communication. From a historical point of view, the S7-400 was planned as a single Client system for this communication. The continued development of the S7-300 family and the S7-200 family enabled providing these module families with Client functions for S7 communication. This was made possible with the application of communication processors. The huge advantage of this protocol is its independence from the hard-ware. This guarantees communication within SIMATIC S7 via one user in-terface, irrespective of which a communication bus system is being used. The configured communication relations are designed either unidirec-tional or bidirectional, so that:

• Client / Client relationships

• Client – Server relationships can be generated. The data to be transferred are application data, as the communication inter-face is located on level 7 of the ISO-OSI reference mode.

Services of the protocol Within the Client – Client relationship, the S7 communication is further di-vided into block oriented and uncoordinated send and receive functions:

• Client – Server relationships ○ PUT / GET – functions

• Client / Client relationships ○ USEND / URCV – functions ○ BSEND / BRCV – functions

These functions are further described in the following chapters:

Table 3-23

Chapter Service

3.1.3.1 PUT / GET 3.1.3.2 USEND / URCV 3.1.3.3 BSEND / BRCV

Configuration steps when using the protocol in SIMATIC S7 The following table contains the configuration steps necessary for configur-ing the S7 connection:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 99/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-24

Configuration step Engineering-Tool What to do

1. Hardware configura-tion of the station

HW Config The bus to be used as well as the module to be employed are selected in hardware configuration

2. Selecting the connec-tion partner

NetPro In the first step the modules, between which the connection is to be configured, are selected in NetPro

3. Configuring the con-nection

NetPro In the second step, the protocol is se-lected. It must be taken into account whether a Client-Client or a Client-Server relationship is to be established. If neces-sary, the connection must be defined as “unilateral“.

4. Programming LAD / FBD / STL editor The user data areas to be sent or re-ceived are transmitted via the user inter-face. This occurs irrespective of the used communication relationship and especially of the used service.

Note In-depth information and a detailed step-by-step description on configuring an S7 connection is available in chapter 6.3.1 ”Configuring an S7 connection“ of the fol-lowing documentation: “S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job References (R_IDs)”

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 100/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.3.1 PUT / GET

Basic characteristics The PUT / GET function blocks form the interface to the Client-Server functions of the S7 communication. They only need to be configured and applied on the client side. Programming of blocks on the server side is not necessary, as the functionality is based on operating system func-tions. Consistency of the data to be transferred can only be provided to a lim-ited extent, as, depending on the used operating system of the CPU, dif-ferent data amounts can be transmitted to the process. The amount of transferable data depends on the employed bus system:

Table 3-25

Bus system max. data length

MPI Approx. 165 bytes PROFIBUS Approx. 165 bytes

Industrial Ethernet Approx. 400 bytes

Advantages and disadvantages of PUT / GET functions The following advantages and disadvantages arise from using these func-tions:

Table 3-26

Advantages 1 The functions can be applied to different bus systems. 2 Dynamic and variable data transfer possible 3 The data are acknowledged by the operating system of the receiving

station. 4 The static connection must only be configured unilaterally.

Disadvantages

1 Only applicable in homogenous SIMATIC S7 structures 2 Inconsistent transfer possible. 3 Only suitable for small to medium data amounts (< 500 bytes), de-

pending on employed bus system 4 Extensive control procedures slow down the transmission rate.

The user interface The following section explains the SIMATIC S7 user interface for the PUT / GET function blocks.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 101/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

PUT function block

Figure 3-9

Table 3-27

Parameter Note

REQ Job trigger for the PUT job ID Connection ID according to the configuration in NetPro

DONE Status display for the successfully completed write job. ERROR Error information if an error occurs in the course of the

function. STATUS Status display for detailed information about the status

of a block or about an error. ADDR_i Area information on the data areas to be described in

the partner CPU. SD_i Area information on the source area within the local

CPU

GET function block

Figure 3-10

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 102/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-28

Parameter Note

REQ Job trigger for the GET job ID Connection ID according to the configuration in NetPro

NDR Status display for the successfully completed write read job.

ERROR Error information if an error occurs in the course of the function.

STATUS Status display for detailed information about the status of a block or about an error.

ADDR_i Area information on the data areas to be read in the partner CPU.

RD_i Area information on the target area within the local CPU

Note Further detailed information on the parameters of the user interface and its usage is available in the STEP 7 online help or the following manual: “STEP 7 - System and standard functions for S7-300 and S7-400“.

Quantity frameworks

Table 3-29

Characteristic Range of values

Data area per job 1 - 165 bytes (at MPI or PROFIBUS) 1 – 400 bytes (at Industrial Ethernet)

Interface Level 7 of the ISO/OSI-reference model Number of possible connection resources

2 (0) - 32 connections depending on CPU and setting (S7-300)

16 -64 connections depending on CPU (not selectable) (S7-400)

Application examples For this protocol, a pre-coded example was created.

Table 3-30

Application title/ Entry-ID Description

Client Server Communication between Wi-nAC Basis and S7-200 stations via S7 Com-munication (PUT/GET) Entry-ID: 20987586

This Application describes synchronizing substations by means of a server station. On request, the server station transmits up to 3 different data records to the substations.

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 103/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.3.2 USEND / URCV

Basic characteristics The USEND / URCV function blocks are the asynchronous interfaces of the Client-Server functions offered for the S7 communication. Program-ming of the function blocks as well as configuring the connection is necessary at both communication partners. Data consistency is guaranteed using function blocks for the transmis-sion. In contrast to the synchronous BSEND / BRCV interface, the USEND / URCV function blocks are acknowledged by the operating system. This enables data transmission independently from the partner. The applica-tion of the communication partner can hence always access the most cur-rent data. The amount of transferable data depends on the employed bus system:

Table 3-31

Bus system max. data length

MPI Approx. 165 bytes PROFIBUS Approx. 165 bytes

Industrial Ethernet Approx. 440 bytes

Advantages and disadvantages of USEND / URCV functions The following advantages and disadvantages arise from using these func-tions:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 104/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-32

Advantages 1 The functions can be applied to different bus systems. 2 Dynamic and variable data transfer possible 3 The data are acknowledged by the operating system of the receiving

station. 4 The transfer is consistent. 5 Uncoordinated data transfer, i.e. the communication partner needs

not acknowledge each date. Only the latest, current data is acknowl-edged hence used.

Disadvantages

1 Only applicable in homogenous SIMATIC S7 structures 2 The static connection must be configured bilaterally. 3 Only suitable for small to medium data amounts (< 500 bytes), de-

pending on employed bus system 4 Extensive control procedures slow down the transmission functions.

The user interface The following section explains the SIMATIC S7 user interface for the USEND / URCV function blocks.

USEND function block

Figure 3-11

Table 3-33

Parameter Note

REQ Job trigger for the USEND job ID Connection ID according to the configuration in NetPro

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

DONE Execution information for the successfully completed write send job.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 105/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Note

ERROR Error information if an error occurs in the course of the function.

STATUS Status display for detailed information about the status of a block or about an error.

SD_i Area information on the source area within the local CPU

URCV function block

Figure 3-12

Table 3-34

Parameter Note

EN_R Job trigger for the URCV job ID Connection ID according to the configuration in NetPro

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error information if an error has occurred in the course of the function.

STATUS Status display for detailed information about the status of a block or about an error.

RD_i Information on the target data areas within the local CPU

Note Further detailed information on the parameters of the user interface and its usage is available in the STEP 7 online help or the following manual: “STEP 7 - System and standard functions for S7-300 and S7-400“.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 106/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Quantity frameworks

Table 3-35

Characteristic Range of values

Data area per job 1 - 165 bytes (at MPI or PROFIBUS) 1 -440 bytes (at Industrial Ethernet)

Interface Level 7 of the ISO/OSI-reference model Number of possible connection resources

2 (0) - 32 connections depending on CPU and setting (S7-300)

16 -64 connections depending on CPU (not selectable) (S7-400)

Back to protocol overview within SIMATIC S7

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 107/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.1.3.3 BSEND / BRCV

Basic characteristics The BSEND / BRCV function blocks are the synchronous interface of the Client-Client functions offered for the S7 communication. The function blocks are necessary for both communication partners and must be ap-plied synchronously, i.e. be called cyclically in both user programs. Fur-thermore, configuring the connection at both communication partners is also necessary here. Data consistency is guaranteed using function blocks for the transmis-sion. In the case of the BSEND / BRCV function blocks, there is a direct hand-shake between the send and the receive block. This way, the sender re-ceives an acknowledgement for each transmitted message segment from the receive block. This enables transferring very large data amounts, up to 64 kBytes for S7-400, and 32 kBytes for S7-300. In the case of BSEND / BRCV, these data amounts can be transferred independent of the bus.

Advantages and disadvantages of BSEND / BRCV functions The following advantages and disadvantages arise from using these func-tions:

Table 3-36

Advantages 1 The functions can be applied to different bus systems. 2 Dynamic and variable data transfer possible 3 Each data segment is acknowledged by the received function block of

the receive station. 4 The transfer is consistent. 5 Data is transferred block oriented, i.e. the entire data is divided into

individual blocks and transmitted to the receive station in segments. 6 Large data amounts up to 64 kByte (S7-400) can be transmitted.

Disadvantages

1 Only applicable in homogenous SIMATIC S7 structures 2 The static connection must be configured bilaterally. 3 Extensive control procedures considerably slow down the transmis-

sion functions.

The user interface The following section explains the SIMATIC S7 user interface for the BSEND / BRCV function blocks.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 108/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

BSEND function block

Figure 3-13

Table 3-37

Parameter Note

EN_R Job trigger for the BSEND job R Input for actively resetting the function. ID Connection ID according to the configuration in NetPro

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error information if an error has occurred in the course of the function.

STATUS Status display for detailed information about the status of a block or about an error.

SD_1 Information on the send areas within the local CPU LEN Length of the data area to be sent

BRCV function block

Figure 3-14

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 109/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-38

Parameter Note

EN_R Job trigger for the BRCV job ID Connection ID according to the configuration in NetPro

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error information if an error has occurred in the course of the function.

STATUS Status display for detailed information about the status of a block or about an error.

RD_1 Information on the target data area within the local CPU

LEN Length of received data area

Basic performance data The following basic performance data for the BSEND / BRCV function blocks of the S7 communication were determined within the framework of the “S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job References (R_IDs)” application

Figure 3-15

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 110/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

It must be noted that in the application on hand, four different data packets were transferred via four different R_IDs between sender and receiver. The measuring range of the application is between 16 and 8092 bytes. The graph indicates the approximately linear course between the measured transmission time and the transferred data amount.

Quantity frameworks

Table 3-39

Characteristic Range of values

Data area per job 1 -32768 bytes (for S7-300) 1 -65536 bytes (for S7-400)

Interface Level 7 of the ISO/OSI-reference model Number of possible connection resources

2 (0) - 32 connections depending on CPU and setting (S7-300)

16 -64 connections depending on CPU (not selectable) (S7-400)

Application examples For this protocol, pre-coded examples were created.

Table 3-40

Application title/ Entry-ID Description

S7 Communication via Profibus CPs with BSEND / BRECEIVE and several Job Refer-ences (R_IDs) Entry-ID: 20987358

This application is an automatic test program to ex-change data between two stations on up to 4 R_Ids, respectively via an S7 connection, when operated under stress i.e. continuous data exchange between the stations. The application can hence recognize errors and react accordingly in a directed (default) manner.

Cross-subnet data record routing via gateway CPU using S7 communication (BSEND/BRECEIVE) Entry-ID: 20983154

This application illustrates an implementation of a functioning data record routing using a programmed application example . Via a gateway station, config-urable data are passed on from one station to a defined other station located in a different network.

Back to protocol overview within SIMATIC S7

3.2 Industrial Ethernet

Introduction An increasing demand for communication possibilities developed due to the increasing level of automation and systematization of production proc-esses. Aside from the field bus systems, this communication possibility was intended to enable the connection of individual manufacturing cells or to

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 111/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

other company divisions. The IEEE 802.3 Ethernet standard developed into the preferred bus system due to its wide use in office communication and WAN networking. For industrial use, however, it was required to improve the immunity and robustness of the individual components which lead to the Industrial Ethernet standard.

Bus system properties The physical configuration of Industrial Ethernet is defined on the basis of the IEEE 802.3 Ethernet standard. High-performance data transfer is pos-sible with transmission rates ranging from 10 MBit/sec. to the gigabit range. Within the framework of normalizing the Ethernet standard, the access to the jointly used bus was defined via the CSMA/CD procedure. In Industrial Ethernet, data can be transferred via triaxial, twisted pair, fiber optic cable or wireless LAN. Ethernet networks can be configured as

• linear bus,

• tree,

• star or

• ring topology; hybrid configurations are also possible. Aside from the physics, a protocol is also required for the data transfer.

Protocols of Industrial Ethernet Industrial Ethernet offers a large selection of possible protocols. The protocols supported in the SIMATIC world are displayed in the figure below:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 112/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Fig. 3-16 Above layer 2, the IP-stack and ISO-stack based protocols form large groups. For detailed information on the two stacks, please refer to the re-spective protocol descriptions. 2 layers can be located for the user.

• The level closest to the hardware is level 4 (Transport Layer). On this level, raw data are exchanged between stations via transport jobs.

• The level closest to the application is level 7 (Application Layer). On this level, application data or data structures are transferred to other applica-tions.

These differences also affect the user interfaces of the individual protocols.

Overview of the protocols The following chapter deals with the protocols available for Industrial Ethernet within SIMATIC for the data communication between controllers. The protocols listed in the table below are described:

Table 3-41

Chapter Protocol

3.2.1 ISO Transport protocol 3.2.2 TCP protocol 3.2.3 ISO on TCP protocol 3.2.4 UDP Protocol

Back to the bus-oriented selection aid of usable protocols

3.2.1 ISO Transport protocol

Basic properties Historically, the ISO Transport protocol, as level 4 interface of the ISO-OSI reference model, was the first Ethernet protocol in SIMATIC. The ISO Transport protocol is based on the ISO protocol defined in ISO 8073 TP0. The main advantage of this protocol is the message-oriented transfer of the data which facilitates processing within an automation system. Since the ISO Transport protocol lacks layer 3 implementation, network ad-dressing and thus routing are not possible. Due to the good determinability of the data transfer, the ISO Transport pro-tocol is – unlike TCP – also suitable for fault-tolerant systems. A connection of S5 systems is also possible with this protocol. However, the latest S7-300 modules no longer support this protocol.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 113/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Services of the protocol The ISO Transport protocol supports the following two services:

• Send / Receive Send / Receive is a service used to actively transfer data between two cli-ent stations. In this process, data are exchanged between the applications by means of send / receive function blocks between the stations.

• Fetch / Write (server) Fetch / Write is a service used to read out data from or write data into a server station. Access is performed via the operating system of the passive server station without further function calls in the server station.

Note In the SIMATIC S7 the Fetch / Write service is only implemented as server func-tionality. Therefore, the SIMATIC S7 cannot actively read or write data. Clients are capable of actively reading data from or writing data into the S7.

Advantages and disadvantages of the “ISO Transport protocol” The advantages and disadvantages of using this protocol are listed in the following table:

Table 3-42

Advantages 1 Quick communication protocol since it is very hardware-intimate. 2 Suitable for medium-sized to large data amounts ((<=8192 bytes). 3 The transfer is message-oriented. 4 Dynamic data lengths are possible.

Disadvantages

1 Mainly applicable in SIMATIC homogenous structures. 2 Increased programming effort required for data management due to

the SEND / RECEIVE programming interface.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for the ISO Transport protocol.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 114/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-43

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus to be used and the module used are selected in the hardware configuration.

2. Select connection partner

NetPro The first step in NetPro is to select the modules between which the connec-tion is configured.

3. Connection configu-ration

NetPro The second step is the selection of the protocol to be used. (See note)

4. User programming LADDER/FBD/Statement List Editor

The user data areas to be sent or received are transferred to the com-munication process via the user inter-face.

The SEND / RECEIVE user interface The following section explains the SIMATIC function interface for communi-cation via the ISO Transport protocol.

AG_SEND / AG_LSEND

Fig. 3-17

Table 3-44

Parameter Comment

ACT Job triggering for the SEND job. ID Connection ID according to the configuration in NetPro.

LADDR Hardware address of the module in the hardware configura-tion.

SEND Specification of the send area of the data area to be sent.

Note The configuration of ISO Transport connections is comparable to the configuration of ISO on TCP connections. Further information on the configuration of ISO on TCP connections is available in chapter 5.3 of the documentation: “Comparison of data transfer via one and via four parallel ISO-on-TCP connections on Industrial Ethernet”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 115/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Comment

LEN Specification of the length of the data area to be sent. DONE Execution display for the completed send job.

ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

AG_RECEIVE / AG_LRECEIVE

Fig. 3-18

Table 3-45

Parameter Comment

ID Connection ID according to the configuration in NetPro. LADDR Hardware address of the module in the hardware configura-

tion. RECV Specification of the area of the receive buffer. NDR Execution display for the completed reception of a com-

plete message. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block. LEN Length of the received data area.

Note For detailed information on the parameters of the user interface and their use please refer to the STEP 7 online help.

Quantity framework of the ISO Transport protocol

Table 3-46

Characteristic Range of values

Data area per job 1 – 8192 bytes Interface Level 4 of the ISO / OSI reference model Number of possible connec-tions

Up to 16 per S7-300 CP, up to 64 per S7-400 CP

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 116/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Back to the Industrial Ethernet protocol overview

3.2.2 TCP protocol

Basic properties TCP/IP (Transmission Control Protocol / Internet Protocol) developed in the 70s of the 20th century. The intention of the US Department of Defense, which ordered the protocol, was to increase the number of networks used militarily. Due to the commercial development of the Internet, TCP/IP has estab-lished itself as standard protocol – also on different bus systems. Due to the standardization of the protocol, implementing this protocol in automation technology suggested itself. Due to the fact that it is widely used in operating systems and due to its availability TCP/IP facilitates the connection of SIMATIC to PCs and mainframes.

Services of the protocol TCP supports the following services:

• Send / Receive Send / Receive is a service used to actively transfer data between two cli-ent stations. In this process, data are exchanged between the applications by means of send / receive function blocks between the stations.

• Fetch / Write (server) Fetch / Write is a service used to read out data from or write data into a server station. Access is performed via the operating system of the passive server station without further function calls in the server station.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 117/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Note In the SIMATIC S7 the Fetch / Write service is only implemented as server func-tionality. Therefore, the SIMATIC S7 cannot actively read or write data. Clients are capable of actively reading data from or writing data into the S7.

Advantages and disadvantages of TCP The advantages and disadvantages of using this protocol are listed in the following two tables:

Table 3-47

Advantages 1 Quick communication protocol since it is very hardware-intimate. 2 Suitable for medium-sized to large data amounts ((<=8192 bytes). 3 The protocol can be used very flexibly with third-party systems which

exclusively support TCP. 4 The protocol is routing-capable. 5 The protocol is acknowledged.

Disadvantages

1 Only static data lengths applicable. 2 Increased programming effort required for data management due to

the SEND / RECEIVE programming interface. 3 The data transfer is stream-oriented.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for TCP.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 118/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-48

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus to be used and the module used are selected in the hardware configuration.

2. Select connection partner

NetPro The first step in NetPro is to select the modules between which the connec-tion is configured.

3. Connection configu-ration

NetPro The second step is the selection of the protocol to be used. (See note)

4. User programming LADDER/FBD/Statement List Editor

The user data areas to be sent or received are transferred to the com-munication process via the user inter-face.

The SEND / RECEIVE user interface The following section explains the SIMATIC function interface for communi-cation via TCP.

AG_SEND / AG_LSEND

Fig. 3-19

Table 3-49

Parameter Comment

ACT Job triggering for the SEND job. ID Connection ID according to the configuration in NetPro.

LADDR Hardware address of the module in the hardware configura-tion.

SEND Specification of the send area of the data area to be sent. LEN Specification of the length of the data area to be sent.

Note The configuration of TCP connections is comparable to the configuration of ISO on TCP connections. Further information on the configuration of ISO on TCP connec-tions is available in chapter 5.3 of the documentation: “Comparison of data transfer via one and via four parallel ISO-on-TCP connections on Industrial Ethernet”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 119/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Comment

DONE Execution display for the completed send job. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

AG_RECEIVE / AG_LRECEIVE

Fig. 3-20

Table 3-50

Parameter Comment

ID Connection ID according to the configuration in NetPro. LADDR Hardware address of the module in the hardware configura-

tion. RECV Specification of the area of the receive buffer. NDR Execution display for the completed reception of a com-

plete message. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block. LEN Length of the received data area.

Note For detailed information on the parameters of the user interface and their use please refer to the STEP 7 online help.

Quantity framework of TCP

Table 3-51

Characteristic Range of values

Data area per job 1 – 8192 bytes Interface Level 4 of the ISO / OSI reference model Number of possible connec-tions

Up to 16 per S7-300 CP, up to 64 per S7-400 CP

Back to the Industrial Ethernet protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 120/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.2.3 ISO on TCP protocol

Basic properties The main advantage of the ISO Transport protocol is the message-oriented transfer of the data. The missing routing functionality, however, developed into an increasingly growing disadvantage due to advancing link-ing in network. As the routing-capable TCP/IP became more and more successful it was tried to combine the advantages of both protocols. In RFC 1006 (RFC = Request for Comments) “ISO on top of TCP”, also called “ISO on TCP”, the mapping of the ISO Transport properties to TCP/IP is established. ISO on TCP is also located on level 4 of the ISO-OSI reference model and defines port 102 as default port for the data transfer. This protocol can continuously be used in the current modules of the S7 and, using CP 1430 TCP, also in S5.

Services of the protocol ISO on TCP supports the following two services:

• Send / Receive Send / Receive is a service used to actively transfer data between two cli-ent stations. In this process, data are exchanged between the applications by means of send / receive function blocks between the stations.

• Fetch / Write (server) Fetch / Write is a service used to read out data from or write data into a server station. Access is performed via the operating system of the passive server station without further function calls in the server station.

Note In the SIMATIC S7 the Fetch / Write service is only implemented as server func-tionality. Therefore, the SIMATIC S7 cannot actively read or write data. Clients are capable of actively reading data from or writing data into the S7.

Advantages and disadvantages of “ISO on TCP” The advantages and disadvantages of using this protocol are listed in the following table:

Table 3-52

Advantages 1 Quick communication protocol since it is very hardware-intimate. 2 Suitable for medium-sized to large data amounts ((<=8192 bytes). 3 Routing-capable (i.e. can be used in WAN)

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 121/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

4 In contrast to TCP, the messages feature an end of data identification (i.e. they are message-oriented)

5 The protocol uses the acknowledged data transfer. 6 Dynamic data lengths are possible.

Disadvantages

1 Mainly applicable in SIMATIC homogenous structures. 2 Increased programming effort required for data management due to

the SEND / RECEIVE programming interface. 3 Separate configuration for routers required since the used port is

usually not enabled.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for ISO on TCP.

Table 3-53

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus to be used and the module used are selected in the hardware configuration.

2. Select connection partner

NetPro The first step in NetPro is to select the modules between which the connec-tion is configured.

3. Connection configu-ration

NetPro The second step is the selection of the protocol to be used. (See note)

4. User programming LADDER/FBD/Statement List Editor

The user data areas to be sent or received are transferred to the com-munication process via the user inter-face.

The SEND / RECEIVE user interface The following section explains the SIMATIC function interface for communi-cation via ISO on TCP.

Note For further information and a detailed step-by-step description of the configuration of ISO on TCP connections please refer to chapter 5.3 of the documentation: “Comparison of data transfer via one and via four parallel ISO-on-TCP connections on Industrial Ethernet”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 122/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

AG_SEND / AG_LSEND

Fig. 3-21

Table 3-54

Parameter Comment

ACT Job triggering for the SEND job. ID Connection ID according to the configuration in NetPro.

LADDR Hardware address of the module in the hardware configura-tion.

SEND Specification of the send area of the data area to be sent. LEN Specification of the length of the data area to be sent.

DONE Execution display for the completed send job. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

AG_RECEIVE / AG_LRECEIVE

Fig. 3-22

Table 3-55

Parameter Comment

ID Connection ID according to the configuration in NetPro. LADDR Hardware address of the module in the hardware configura-

tion. RECV Specification of the area of the receive buffer. NDR Execution display for the completed reception of a com-

plete message. ERROR Error display if an error occurs during the function.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 123/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Comment

STATUS Status display for detailed information on the status of the block.

LEN Length of the received data area.

Note For detailed information on the parameters of the user interface and their use please refer to the STEP 7 online help or the corresponding application example of this protocol.

Basic performance data/quantity frameworks The following basic performance data were determined for an ISO on TCP connection from the application: “Comparison of data transfer via one and via four parallel ISO-on-TCP connections on Industrial Ethernet”

Fig. 3-23: Message runtimes via the transfer spectrum As can be seen in the graph, the message runtime behavior of ISO on TCP is approximately linear. In this application, the transfer times of an identical data amount were compared via one or four connections.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 124/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Quantity frameworks

Table 3-56

Characteristic Range of values

Data area per job 1 – 8192 bytes Interface Level 4 of the ISO / OSI reference model Number of possible connec-tions

Up to 16 per S7-300 CP, up to 64 per S7-400 CP

Application examples For this protocol, pre-coded examples were created.

Table 3-57

Application title/ Entry-ID Description

Comparison of data transfer via one and via four parallel ISO-on-TCP connections on Industrial Ethernet Entry-ID: 20987359

This Application compares the sending of a variable data record via one or four Ethernet connections.

Back to the Industrial Ethernet protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 125/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.2.4 UDP Protocol

Basic properties Within the framework of the IP development, UDP (User Datagram Proto-col) was created along with TCP on the transport layer of IP. The intention of developing this protocol was to develop a datagram-capable protocol which can also be operated on routing-capable networks. The main advantage of a datagram-capable protocol is the fact that it is multicast- as well as broadcast-capable. The transfer of datagram mes-sages is connectionless, i.e. they are not acknowledged e.g. by the desti-nation station. For this reason the application has to perform the acknowl-edgement for the secure operation of the data transfer; however, this does not affect the advantages of UDP regarding speed, simplicity or flexibility.

Services of the protocol UDP supports the following service:

• Send / Receive Send / Receive is a service used to actively transfer data between two cli-ent stations. In this process, data are exchanged between the applications by means of send / receive function blocks between the stations.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 126/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Advantages and disadvantages of UDP The advantages and disadvantages of using this protocol are listed in the following:

Table 3-58

Advantages 1 Very quick communication protocol since it is very hardware-intimate. 2 Suitable for small to medium-sized data amounts ((<=2048 bytes). 3 The protocol can be used very flexibly and with third-party systems. 4 The protocol is routing-capable. 5 The protocol is multicast- / broadcast-capable.

Disadvantages

1 The protocol is unacknowledged, i.e. securing the communication requires a checking in the program.

2 Increased programming effort required for management of data and also connection partners due to the SEND / RECEIVE programming interface.

3 The data transfer is stream-oriented. 4 Broadcast functions can only be used in the direction of sending.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for UDP.

Table 3-59

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus to be used and the module used are selected in the hardware configuration.

2. Select connection partner

NetPro The first step in NetPro is to select the modules between which the connec-tion is configured.

3. Connection configu-ration

NetPro The second step is the selection of the protocol to be used. (See note)

4. User programming LADDER/FBD/Statement List Editor

The user data areas to be sent or received are transferred to the com-munication process via the user inter-face.

Note For further information and a detailed step-by-step description of the configuration of multicast or unspecified connections please refer to chapter 5.3 of the documen-tation: “Master-Slave Communication via Ethernet with UDP Using Multicast and Unspecified Connections”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 127/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The SEND / RECEIVE user interface The following section explains the SIMATIC function interface for communi-cation via UDP.

AG_SEND / AG_LSEND

Fig. 3-24

Table 3-60

Parameter Comment

ACT Job triggering for the SEND job. ID Connection ID according to the configuration in NetPro.

LADDR Hardware address of the module in the hardware configura-tion.

SEND Specification of the send area of the data area to be sent. LEN Specification of the length of the data area to be sent.

DONE Execution display for the completed send job. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

AG_RECEIVE / AG_LRECEIVE

Fig. 3-25

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 128/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-61

Parameter Comment

ID Connection ID according to the configuration in NetPro. LADDR Hardware address of the module in the hardware configura-

tion. RECV Specification of the area of the receive buffer. NDR Execution display for the completed reception of a com-

plete message. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block. LEN Length of the received data area.

Note For detailed information on the parameters of the user interface and their use please refer to the STEP 7 online help.

Basic performance data/quantity frameworks The following basic performance data were determined for a UDP connec-tion between 3 stations with the application “Master-Slave Communication via Ethernet with UDP Using Multicast and Unspecified Connections”.

Fig. 3-26

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 129/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The graphic above shows the time sequence of a data transfer from one sender to two receivers with acknowledgement by the user program. The linear sequence between user data length and message runtime is visible in the figure.

Quantity framework of UDP

Table 3-62

Characteristic Range of values

Data area per job 1 – 2048 bytes Interface Level 4 of the ISO / OSI reference model Number of possible connec-tions

Up to 16 per S7-300 CP, up to 64 per S7-400 CP

Application examples A pre-coded example was created for this protocol.

Table 3-63

Application title/ Entry-ID Description

Master-Slave Communication via Ethernet with UDP Using Multicast and Unspecified Connections Entry-ID: 20983558

This application shows a possibility of realizing an acknowledged data transfer to a number of bus sta-tions (stations) which is variable and dynamically changeable during runtime via Industrial Ethernet and UDP without having to modify the configuration / programming for each station. The master generates multicast messages; the reception of these mes-sages is acknowledged by the slaves by means of unspecified connections.

Back to the Industrial Ethernet protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 130/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3 PROFIBUS

Introduction Nowadays, it is impossible to imagine an automation system without field bus interface. Field bus has successfully established itself in industrial automation solutions. Several different bus systems are available, but PROFIBUS seems to become increasingly accepted in this field due to its openness and worldwide use.

Bus system properties PROFIBUS is based on the EN 50 170 standard (formerly known as DIN 19245). Physically, the bus is based on a bidirectional differential voltage system between two conductors which is also known as RS 485. The data transmission rates of PROFIBUS range from 9.6 kBit/sec. to 12 MBit/sec. The transmission technology is based on a token system. Via the token, the authorization for active sending is passed on to the respective station. The token system is the reason for the static configuration of the bus system which is described by a defined parameter record. In addition, the deterministics of the bus system can be preset via a predefined bus time; due to this, a fixed period of time for sending data is assigned to each station. In PROFIBUS the data are transferred via two-wire cables. Additionally, an optical variant using fiber optic or plastic optical fiber conductors has devel-oped for data transfer over large distances or through areas with EMC. Photoelectric barriers or infrared transfer options were developed for the transfer over small distances without direct electrical connection. PROFIBUS networks can have a:

• Linear bus or

• ring topology (only optical) Aside from the physical configuration of PROFIBUS, the protocols were also defined in its normalizing.

Protocols of PROFIBUS The protocols described in the original PROFIBUS standard (FDL and FMS) were supplemented by partly proprietarily developed protocols. These protocols are partly published and have influenced the normalizing. Yet, the basis of each protocol is the standard and thus the FDL protocol with its services.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 131/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Fig. 3-27 For the user the protocols are divided into 3 groups:

• The hardware-intimate FDL layer of level 2. The Data Link Layer serves as basis for all protocols.

• The Application Layer of level 7 via which application data or data struc-tures are transferred to other applications.

• And, as a special case, the DP protocol which is described in detail in the protocol description.

The differences between the levels and protocols also affect the user inter-faces.

Overview of the protocols The following chapter deals with the protocols available for PROFIBUS within SIMATIC S7 for the data communication between controllers. The following protocols are described:

Table 3-64

Chapter Protocol

3.3.1 FDL protocol 3.3.2 DP protocol 3.3.3 FMS protocol

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 132/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3.1 FDL protocol

Basic properties The FDL protocol is the basic protocol on which every other PROFIBUS protocol is based. It is located on level 2 of the ISO-OSI reference model. One important advantage of the protocol is its speed. The fact that it is hardware-intimate enables a correspondingly high message throughput. Another advantage of the protocol is its flexibility. Because of its 4 services (of which SIMATIC S7 offers 2 as interface) it covers a large range of trans-fer options. The SEND / RECEIVE interface is used as interface of the protocol. De-spite the fact that it is a level 4 interface, this is supported by the lack of level 3 and 4 in the PROFIBUS model. Third-party or S5 systems can be connected without difficulty with this pro-tocol, since the FDL protocol as basic protocol is supported by many PROFIBUS-capable modules.

Services of the protocol In its original form, the FDL protocol supports the following 5 services:

• SDA (Send Data with Acknowledge)

• SDN (Send Data with No Acknowledge)

• SRD (Send and Request Data with Acknowledge)

• CSRD (Cyclic Send and Request Data) Within SIMATIC, the two services listed below are actively supported:

Table 3-65

Chapter Service

3.3.1.1 SDA service (Send Data with Acknowledge) 3.3.1.2 SDN service (free layer 2 access) (Send Data with No Acknowledge)

They will be described in the following sub-chapters.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for FDL proto-col.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 133/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-66

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus to be used and the module used are selected in the hardware configuration.

2. Select connection partner

NetPro The first step in NetPro is to select the modules between which the connec-tion is configured.

3. Connection configu-ration

NetPro The second step is the selection of the protocol to be used. (See note)

4. User programming LADDER/FBD/Statement List Editor

The user data areas to be sent or received are transferred to the com-munication process via the user inter-face.

The SEND / RECEIVE user interface The following section explains the SIMATIC function interface for communi-cation via FDL protocol.

AG_SEND / AG_LSEND

Fig. 3-28

Table 3-67

Parameter Comment

ACT Job triggering for the SEND job. ID Connection ID according to the configuration in NetPro.

LADDR Hardware address of the module in the hardware configura-tion.

SEND Specification of the send area of the data area to be sent. LEN Specification of the length of the data area to be sent.

Note For further information and a detailed step-by-step description of the configuration of FDL connections please refer to chapter 6.3.2 of the documentation: “Data Ex-change with FDL (SDA) by the Use of AG_SEND / AG_RECV”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 134/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Comment

DONE Execution display for the completed send job. ERROR Error display if an error occurred during the function. STATUS Status display for detailed information on the status of the

block.

AG_RECEIVE / AG_LRECEIVE

Fig. 3-29

Table 3-68

Parameter Comment

ID Connection ID according to the configuration in NetPro. LADDR Hardware address of the module in the hardware configura-

tion. RECV Specification of the area of the receive buffer. NDR Execution display for the completed reception of a com-

plete message. ERROR Error display if an error occurred during the function. STATUS Status display for detailed information on the status of the

block. LEN Length output of the received data area.

Note For detailed information on the parameters of the user interface and their use please refer to the STEP 7 online help.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 135/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3.1.1 SDA service

Basic properties The SDA (Send Data with Acknowledge) service is an acknowledged data service. It enables a consistent data exchange of up to 240 bytes be-tween two active stations. Each data packet is followed by an acknowl-edgement of the receiving station. This ensures a successful and correct data transfer.

Advantages and disadvantages of the FDL protocol (SDA) The advantages and disadvantages of using this protocol are listed in the following:

Table 3-69

Advantages 1 Very quick communication protocol since it is very hardware-intimate. 2 The protocol can be used with third-party systems. 3 The data are transferred consistently. 4 The transfer is acknowledged.

Disadvantages

1 The service is only suitable for small data amounts (<= 240 bytes). 2 Increased programming effort required for management of data and

also connection partners due to the SEND / RECEIVE programming interface.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 136/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Basic performance data/quantity frameworks The following basic performance data were determined for an FDL SDA connection from the application “Data Exchange with FDL (SDA) by the Use of AG_SEND / AG_RECV”.

Fig. 3-30 The diagram above shows the transfer times for a data amount from 50 to 8092 bytes which was transferred in up to 37 partial data records. As can be seen in the diagram, there is a linear relation between data amount and transfer time.

Quantity framework of the FDL protocol (service SDA)

Table 3-70

Characteristic Range of values

Data area per job 1 – 240 bytes Interface Level 2 of the ISO / OSI reference model Number of possible connec-tions

Up to 16 per S7-300 CP, up to 64 per S7-400 CP

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 137/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application examples A pre-coded example was created for this protocol.

Table 3-71

Application title/ Entry-ID Description

Data Exchange with FDL (SDA) by the Use of AG_SEND / AG_RECV Entry-ID: 20987711

This application shows how a data transfer, which can transfer a user-defined data amount up to the maximum DB size, can be realized using the FDL protocol via PROFIBUS. The transfer is acknowl-edged on level 2 and in addition on level 7 which was realized in the application.

Back to the PROFIBUS protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 138/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3.1.2 SDN service (free layer 2 access)

Basic properties The SDN (Send Data with No Acknowledge) service is an unacknow-ledged bidirectional data service. It enables a consistent data exchange of up to 236 bytes between two are more stations. Using this service, e.g. the following connection types are possible:

• Unspecified connections, i.e. the communication partner is addressed in the user program. In addition, there is the option that user-defined com-munication partners can successively communicate with a station via one connection.

• Broadcast connections, i.e. simultaneous sending of messages to sev-eral receiving stations with only one job. Accordingly, broadcast mes-sages can be received on the same broadcast connection.

• Multicast connections, i.e. sending of a message to several receiving stations of a multicast circuit with one job. Accordingly, multicast mes-sages can also be received on the same multicast connection.

Note In SIMATIC it is only possible to configure one PROFIBUS broadcast connection. If a PROFIBUS broadcast connection has been configured, it is not possible to con-figure an additional PROFIBUS broadcast connection.

Characteristics during configuring the FDL-SDN service Aside from the configuration of the FDL connection, configuring a free layer 2 connection requires additional information. To provide this infor-mation, the “free Layer 2 access” entry in the properties of the FDL connec-tion has to be selected.

Note The configuration of the user data of the FDL-SDN service contains an additional header. For the structure of the header, please refer to the manual: “SIMATIC NET NCM S7 for PROFIBUS Volume 1 of 2”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 139/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Advantages and disadvantages of the FDL protocol (SDN) The advantages and disadvantages of using this protocol are listed in the following:

Table 3-72

Advantages 1 Very quick communication protocol since it is very hardware-intimate. 2 The protocol can be used flexibly also with third-party systems. 3 The data are transferred consistently. 4 Multicast as well as broadcast functions are possible.

Disadvantages

1 The service is only suitable for small data amounts (<= 236 bytes). 2 The transfer is unacknowledged. A user acknowledgement requires

an evaluation of the message in the program. 3 Increased programming effort required for management of data and

also connection partners due to the SEND / RECEIVE programming interface.

Quantity framework of the FDL protocol (service SDN)

Table 3-73

Characteristic Range of values

Data area per job 1 – 236 bytes Interface Level 2 of the ISO / OSI reference model Number of possible connec-tions

Up to 16 per S7-300 CP, up to 64 per S7-400 CP

Back to the PROFIBUS protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 140/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3.2 DP protocol

Basic properties On field level, protocols for PROFIBUS with a large number of services or extensive data editing are unsuitable since these factors would make it im-possible to reach the required bus cycle time and reaction time. The PROFIBUS DP (distributed I/O) protocol was developed to be able to cover the field level within the automation hierarchy. The basic feature of PROFIBUS-DP is the fact that the user data are displayed in the form of a cyclic data image. The object-oriented interfaces as used in the FMS or S7 protocol are completely bypassed. The principle of PROFIBUS-DP communication is a master-slave system. A master cyclically polls one or several slaves. Instead of the user interface, the user interface is located on level 7 (ISO-OSI reference model) of the DP protocol which, as standardized application along with DDLM (Direkt Data Link Mapper), is directly based on level 2 (ISO-OSI reference model), thus on FDL. The following two different types of DP masters exist:

• Master Class 1: This DP master cyclically controls the process.

• Master Class 2: This DP master is used for device parameterization and diagnostics.

Since there are no differences for all PROFIBUS protocols on level 2, all protocols can be operated in parallel in one PROFIBUS network.

Services of the protocol The DP protocol distinguishes different services which also result from the different master classes.

• Data services Data services are used to write or read data of the parameterized distrib-uted I/O. If a station is parameterized as slave, this also enables to make user data available to a master.

• Diagnostic services Depending on the parameterized job, diagnostic services enable diagnos-tics of a DP slave or a DP master.

• Control services The control service enables the sending of control jobs to a PROFIBUS-DP station in the following form:

○ Status changes ○ Read jobs for inputs / outputs of other stations ○ Sending of global control commands to the local master or other bus stations.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 141/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Advantages and disadvantages of the DP protocol The advantages and disadvantages of using this protocol are listed in the following:

Table 3-74

Advantages 1 Very quick communication protocol since it is very hardware-intimate. 2 The protocol can also be used with third-party systems. 3 The data transfer is acknowledged. 4 In case of minor or inconsistent data access, access is performed

without function call. Disadvantages

1 The service is only suitable for small data amounts (<= 244 bytes). 2 The protocol can only transfer static data amounts. 3 The effort required for configuring is considerable.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for DP proto-col.

Table 3-75

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus to be used and the module used are selected in the hardware configuration.

2. Hardware configura-tion of the slave

HW Config In the next step, the used slave mod-ules are selected and assigned to the bus.

3. Hardware configura-tion of the modules

HW Config Depending on the slave, also func-tional modules can be configured de-pending on the requirement in the system. It also has to be considered how the data are transferred to the master. Consistent data require func-tion calls in the program.

3. User programming LADDER/FBD/Statement List Editor

The data are polled by the master by direct I/O accesses or using the func-tion calls.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 142/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Note For a detailed step-by-step description of the configuration of a CPU or a CP DP master-slave system, please refer to chapter 5.3 of the documentation: “Direct Data Exchange between separate DP Systems via DP Communication”

The user interface The user interface of PROFIBUS DP can be divided into two groups in SIMATIC S7:

• S7-300 CP 342-5

• Internal DP interfaces (also CP 443-5 Extended or IM 467) Correspondingly, different user interfaces are available for both types which will be briefly explained in the following.

S7-300 CP 342-5 user interface DP_SEND / DP_RECV Depending on the operating mode of the PROFIBUS CP 342-5, the DP_SEND / DP_RECV functions have the following functions within the S7-300:

Table 3-76

Operating mode Block

DP master DP slave

DP_SEND The block transfers the data of a specified DP output area to the PROFIUB CP for output to the dis-tributed I/O.

The block transfers the input data of the DP slave to the PROFIBUS CP for transfer to the DP master.

DP_RECV The block transfers the process data of the distributed I/O as well as status information into a specified DP input area.

The block transfers the output data transmitted from the DP master into the DP data area specified on the block.

The two blocks are structured as follows:

DP_SEND

Fig. 3-31

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 143/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-77

Parameter Comment

CPLADDR Module start address of the CP in HW Config. SEND Indication of the DP data area to be transferred in the I/O,

bit memory address or data area. DONE Execution display for the completed send job.

ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

DP_RECV

Fig. 3-32

Table 3-78

Parameter Comment

CPLADDR Module start address of the CP in HW Config. RECV Indication of the DP receive data area in the I/O, bit mem-

ory address or data area. NDR Execution display for the completed reception of a data

area. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block. DPSTATUS Status display for detailed information on the status of the

bus system.

Note Detailed information on the parameters and the user interface and their use is available in the SIMATIC NET NCM S7 for PROFIBUS – Volume 1 manual or in the STEP7 online help.

The DPWR_DAT / DPRD_DAT user interface The DPWR_DAT / DPRD_DAT interface is suitable for all internal inter-faces of the SIMATIC S7 DP master. This includes all DP communications processors of the S7-400.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 144/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Note The DPWR_DAT / DPRD_DAT interface is only to be used if the size of the consis-tent data is 3 bytes or more than 4 bytes! For byte, word or double-word access, direct I/O access can be used. The task of the blocks is described in the table below:

Table 3-79

Block Task

DPWR_DAT With SFC 15 “DPWR_DAT” (write consistent data to a DP-norm-slave) you consistently transfer the data from a data source area to the addressed DP standard slave and into the process image.

DPRD_DAT With SFC 14 “DPRD_DAT” (read consistent data of a DP-norm slave) you consistently read out data of a DP standard slave or one of its modules.

The two blocks are structured as follows:

DPWR_DAT

Fig. 3-33

Table 3-80

Parameter Comment

LADDR This is the configured start address from the output area of the module which is to be written to.

RECORD This is the source area for the user data to be written. The length of the source area has to correspond to the config-ured data area of the respective module.

RET_VAL If an error occurs during processing the function, the return value contains an error code.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 145/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

DPRD_DAT

Fig. 3-34

Table 3-81

Parameter Comment

LADDR This is the configured start address from the input area of the module from which is to be read.

RET_VAL If an error occurs during processing the function, the return value contains an error code.

RECORD This is the destination area for the read user data. The length of the destination area has to correspond to the con-figured data area of the respective module.

Note Detailed information on the parameters of the user interfaces and their use in the different modes of the DP modules is available in the STEP7 online help or in the manuals: “STEP 7 – System and Standard Functions for S7-300 and S7-400” or ”SIMATIC NET NCM S7 for PROFIBUS Volume 1 of 2”

Basic performance data/quantity frameworks In the Applications portal an application dealing with DP communication be-tween internal DP interfaces and a CP 342-5 was created. In the scope of this application, a transfer time measurement serving as an example for the communication between internal and external interfaces was performed. The measurement was performed under the following boundary conditions:

Table 3-82

Condition Frame

Data amount 240 bytes, including 16 bytes acknowledge-ment

Baud rate 1.5 MBit/sec Bus profile DP

Master CPU 315 AG 10 Slave CPU 315 AG 10 with CP 342-5 DA 02

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 146/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The following results were measured:

Table 3-83

Condition Measured value Transfer time master -> slave (224 bytes user data) for 100 measurements Average duration 79 ms Maximum duration 438 ms Minimum duration 7 ms Transfer time slave -> master (224 bytes user data) for 100 measurements Average duration 33 ms Maximum duration 51 ms Minimum duration 19 ms The measurement of a transfer process lasts from the initiation of the data transfer in the sending station until the acknowledgement of the data by the receiving station. The short average time shows the high data throughput of the used protocol.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 147/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Application examples A pre-coded example was created for this protocol.

Table 3-84

Application title/ Entry-ID Description

Direct Data Exchange between separate DP Systems via DP Communication Entry-ID: 20987807

This application deals with a cost-effective transfer of data between two DP masters using a DP slave CP 342-5. A data acknowledgement which is evaluated using the application is additionally added to the DP protocol.

Back to the PROFIBUS protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 148/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.3.3 FMS protocol

Basic properties Along with the FDL protocol, an additional protocol – the FMS protocol – was specified in the original form of the PROFIBUS specification. Aside from the field devices, high-quality hierarchical systems were supposed to be considered via this protocol. To accomplish this, also a part of the MMS (Manufacturing Message Speci-fication) from the MAP communication model was complied with along with the field device connection. This overall model forms the Fieldbus Mes-sage Specification (FMS). Levels 3 to 6 don’t exist within PROFIBUS. Level 2 is the application layer, for the FMS protocol the Lower Layer Interface (LLI) was developed for level 7. In this LLI, functions of the levels which are not available such as connection buildup / cleardown and connection monitoring have been im-plemented for the FMS protocol. The FMS protocol is object-oriented. All transferred data are transferred in the form of multi-vendor, standardized communication objects. Each object is accessed via index or name.

Services of the protocol The FMS protocol can roughly be divided into two classes of services:

• Productive services and All services with which objects of an application process can be edited be-long to the group of the productive services.

• Management services. A number of functions relating to the management of the communications system belong to the group of the management services.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 149/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Advantages and disadvantages of the FMS protocol The advantages and disadvantages of using this protocol are listed in the following:

Table 3-85

Advantages 1 The protocol can be used flexibly with third-party systems. 2 The data transfer is acknowledged. 3 Access to individual variables or structure elements is possible. 4 Connections to slaves are possible as well as connections between

masters. Disadvantages

1 Due to its large overhead caused by management information, the protocol is very slow.

2 The configuration effort is considerable since all variables have to be defined symbolically and since it may be required to adapt the con-nection parameters.

Configuration steps when using the protocol in SIMATIC S7 The following list contains the configuration steps necessary for the FMS protocol.

Table 3-86

Configuration step Engineering tool What has to be done

1. Hardware configura-tion of the station

HW Config The bus and the module used are se-lected in the hardware configuration.

2. Creating the commu-nication objects used

E.g. DB Editor In the DB Editor, the data records to be transferred are programmed in the form of data blocks.

3. Specifying the com-munication objects using symbols

Symbol Editor In the Symbol Editor, the communica-tion objects are specified in the created data blocks. Either index or name ad-dressing can be selected.

4. Selecting connection partner

NetPro First, the modules between which the FMS connection is to be configured are selected.

5. Connection configura-tion

NetPro The connection FMS connection is selected and the connection parame-ters are adapted according to the FMS profile and the functionalities.

6. User programming LADDER/FBD/Statement List Editor

In the user program, the data areas to be transferred are stored in the data blocks for the function call with the names and indices.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 150/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Configuration step Engineering tool What has to be done

7. User programming LADDER/FBD/Statement List Editor

In the user program, the transfer func-tions are supplied with the prepared names or indices of the variables to be transferred as well as the correspond-ingly prepared destination data areas.

The READ, WRITE, REPORT user interface The following section explains the SIMATIC function interface for communi-cation via the FMS protocol.

The client service READ

Fig. 3-35

Table 3-87

Parameter Comment

REQ Job triggering for the READ job. ID Connection ID according to the configuration in NetPro. It

contains the communication reference and the K bus ID. VAR_1 Address of the storage location of the communication

variable designation. (See step 5 of the configuration steps)

RD_1 Address of the data area into which the communication variable is to be written.

NDR Execution display for the completed read job. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 151/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The client service WRITE

Fig. 3-36

Table 3-88

Parameter Comment

REQ Job triggering for the WRITE job. ID Connection ID according to the configuration in NetPro. It

contains the communication reference and the K bus ID. VAR_1 Address of the storage location of the communication

variable designation. (See step 5 of the configuration steps)

SD_1 Address of the data area in which the source data to be written are stored.

DONE Execution display for the completed write job. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of the

block.

The server service REPORT

Fig. 3-37

Table 3-89

Parameter Comment

REQ Job triggering for the REPORT job. ID Connection ID according to the configuration in NetPro. It

contains the communication reference and the K bus ID.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 152/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Comment

VAR_1 Address of the storage location of the communication variable designation. (See step 5 of the configuration steps)

SD_1 Address of the data area in which the source data to be reported are stored.

DONE Execution display for the completed report job. ERROR Error display if an error occurs during the function. STATUS Status display for detailed information on the status of

the block.

Note Detailed information on the parameters of the user interface and their use is avail-able in the STEP7 online help or in the manual “SIMATIC NET NCM S7 for PROFIBUS / FMS Manual Volume 2/2”.

Quantity framework of the FMS protocol

Table 3-90

Characteristic Range of values

S7-300 allow up to: - 256 server variables and - 256 variable descriptions loadable from the

partner. The variables can be freely distributed to all config-urable FMS connections.

Number of possible com-munication variables

S7-400 allow up to: - 512 server variables and - 2640 variable descriptions loadable from

the partner. The variables can be freely distributed to all config-urable FMS connections.

Interface Level 7 of the ISO-OSI reference model Number of possible connec-tions

Up to 16 connections per S7-300 CP, up to 48 connections per S7-400 CP

Back to the PROFIBUS protocol overview

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 153/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4 Serial Protocols

Introduction All protocols and bus systems discussed so far refer to serial protocols on the lowest levels, i.e. they are transferred individually, successively via a data line. The difference between these and the following protocols is that these protocols and architectures have been designed explicitly for multi-point operation. The following protocols have been exclusively designed for point-to-point operation, with the exception of the loadable protocol driver. Some interfaces have proven particularly suitable for the application of point-to-point connection in automation technology. These interfaces are available for SIMATIC S7 in the form of integrated interfaces or communi-cation processors These interfaces are:

• RS 232C (V.24)

• RS 422 / 485 (X.27)

• 20 mA (TTY)

Properties of the interfaces All three of the available interface systems have different physical and technological requirements:

Table 3-91

Characteristics RS 232 C (V.24) RS 422/485 (X.27) 20 mA (TTY)

Type of interface Voltage interface Current loop interface Differential voltage in-terface

Front connector 9 pole Sub-D 9 pole Sub-D 15 pole Sub-D Max. transmis-sion rate

up to 115.2 kBit/s up to 19.2 kBit/s up to 115.2 kBit/s

Max. line length

max. 15 m max. 1000 m (at 9.5 kBit/s)

max. 1,200 m (at 19.2 kBit/s)

Corresponds to the norm

DIN 66020, DIN 66259, EIA-RS 232C, CCITT V.24/V.28

DIN 66258 part 1 DIN 66259 part 1 and 3EIA-RS 422/485, CCITT V.11

Driver for bidirectional data traffic Three standard protocols are available for data transfer via point-to-point connection. These are:

Table 3-92

Chapter Protocol

3.4.1 Protocol RK512 3.4.2 Procedure 3964(R) 3.4.3 Free ASCII protocol

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 154/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Loadable protocol drivers Loadable protocol drivers are furthermore available for operation via multi-point networks. They process the respective protocols via their software in-terfaces. These protocol drivers are:

Table 3-93

Chapter Protocol

3.4.4 Modbus protocol 3.4.5 Data highway protocol

These 5 protocols are discussed in the following sections.

Back to the bus-oriented selection aid

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 155/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.1 Protocol RK512

Basic characteristics The computer interface RK 512 controls data transfer at bidirectional point-to-point connection between the local logic controller and a communica-tion partner. Hereby the RK 512 protocol uses transport layer, level 4, known from the ISO-OSI reference model. This provides a very high transmission security. The services used with the RK 512 are acknowledged.

Services of the protocol The protocol RK 512 has the following services, derived from the 3964R procedure:

Table 3-94

Service Description

PUT At a SEND / PUT message, the local station sends a command message with user data to the communication partner, which in return responds with a response mes-sage.

GET At a GET message, the local station sends a command message without user data, and the communication part-ner responds with a response message with user data.

Advantages and disadvantages of the RK 512 protocol The following advantages and disadvantages arise from using this protocol:

Table 3-95

Advantages 1 The protocol can be used well with third-party systems. 2 The data transfer is acknowledged. 3 Reading / writing of individual definable data areas is possible 4 Relative simple configuration and user program development 5 Data safety is very high due to Hamming distance 4. 6 Suitable only for average data amounts (<=1024 bytes).

Disadvantages

1 Due to the high protocol effort, e.g. using the 3964R (on which the RK 512 is based), the connection performance is not very high.

2 RS 485 cannot be used as bus medium.

Configuration steps when using the protocol in SIMATIC S7 The large variance of the usable modules and user interfaces does not al-low for a general statement on the configuration.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 156/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

For detailed information on the necessary configuration steps please use the documentation available for your module.

The user interface Due to the fact that all available communication processors and internal in-terfaces use different user interfaces, a detailed statement on usage func-tion blocks is not sensible. For detailed information on the available function blocks please use the documentation available for your module.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 157/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Quantity framework of the protocol RK 512

Table 3-96

Characteristic Range of values

Data area per job up to 1024 bytes per telegram (128 bytes per segment)

Interface Level 4 of the ISO / OSI reference model (connection works, but technically on level 7)

Number of possible connec-tions per CP

1 (point-to-point connection)

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 158/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.2 Procedure 3964(R)

Basic characteristics The procedure 3964 (R) controls data transfer at point-to-point connection between a local station and a communication partner. Procedure 3964(R) contains a bit transmission layer (level 1 of the ISO-OSI reference model) as well as the link layer control (level 2 of the ISO-OSI reference model). Layer 2, the link layer control, is available in the form of a control charac-ter. This control character controls the complete and error-free data trans-mission from the communication partner. When connecting via the 3964(R) procedure, both communication partners must be configured with different priorities.

Note The difference between the procedure 3964 and the procedure 3964R lies in the transmission of the block check character. At the 3964R procedure, the block check characters are transferred as well. Both types are discussed under the name 3964(R) below.

Services of the protocol The 3964(R) procedure supports the following services:

• SEND The SEND function available for the respective system transmits a data field from a data block. This data field is defined by data block number, start address and length of the data to be transferred.

• RECEIVE The RECEIVE function, available for the respective system, transfers re-ceived data fields from a data buffer into a target area. The target area within the local station is specified by means of a data block, the start ad-dress of the data. The length of the received data is given after successful completion of the function.

Advantages and disadvantages of the procedure 3964(R) The advantages and disadvantages of using this protocol are listed in the following:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 159/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-97

Advantages 1 The protocol can be used well with third-party systems. 2 The data transfer is acknowledged by the communication partner

(hardware). 3 Data safety is high due to Hamming distance 3. 4 Suitable for average data amounts (<=1024 bytes) 5 The performance of the procedure relative to the data safety is good.

Disadvantages

1 RS 485 cannot be used as bus medium. 2 Coordinated calls of send and receive functions on both sides are

necessary.

Configuration steps when using the protocol in SIMATIC S7 The large variance of the usable modules and user interfaces does not al-low for a general statement on the configuration. For detailed information on the necessary configuration steps please use the documentation available for your module.

The user interface Due to the fact that all available communication processors and internal in-terfaces use different user interfaces, a detailed statement on usage func-tion blocks is not sensible. For detailed information on the available function blocks please use the documentation available for your module.

Quantity framework for procedure 3964(R)

Table 3-98

Characteristic Range of values

Data area per job up to 1024 bytes per message Interface Level 2 of the ISO / OSI reference model Number of possible connec-tions per CP

1 (point-to-point connection)

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 160/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.3 Free ASCII protocol

Basic characteristics The ASCII protocol controls data transfer at point-to-point connection be-tween a local station and a communication partner on the lowest level. The ASCII protocol contains the bit transmission layer (level 1 of the ISO/OSI reference model). The structure of the messages is completely user specific, hence the development of some protocols based on the ASCII protocol is possible. Only one end-of-message character must be defined for the received messages. Using the ASCII protocol, data with any structure (all printable ASCII characters from the ASCII table, as far as possible within the parameterized character framework) can be sent and received.

Services of the protocol The free ASCII protocol supports the following two data services:

• SEND The SEND function available for the respective system transmits a data field from a data block. This data field is defined by data block number, start address and length of the data to be transferred.

• RECEIVE The RECEIVE function, available for the respective system, transfers re-ceived data fields from a data buffer into a target area. The target area within the local station is specified by means of a data block, the start ad-dress of the data. The length of the received data is given after successful completion of the function.

Advantages and disadvantages of the free ASCII protocol The advantages and disadvantages of using this protocol are listed below:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 161/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-99

Advantages 1 The protocol can be used well with third-party systems, as it

is entirely based on ASCII code. 2 Suitable for average data amounts (<=1024 bytes) 3 The performance of the procedure is very good, as there is no

header or procedure processing. 4 The entire ASCII character scope can be transferred as data.

Disadvantages

1 The data transfer is unacknowledged. 2 Data safety is very low due to Hamming distance 1, only the

parity bit is used. 3 Coordinated calls from send and receive functions necessary

on both sides.

Configuration steps when using the protocol in SIMATIC S7 The large variance of the usable modules and user interfaces does not al-low for a general statement on the configuration. For detailed information on the necessary configuration steps please use the documentation available for your module.

The user interface Due to the fact that all available communication processors and internal in-terfaces use different user interfaces, a detailed statement on usage func-tion blocks is not sensible. For detailed information on the available function blocks please use the documentation available for your module.

Quantity framework of the free ASCII protocol

Table 3-100

Characteristic Range of values

Data area per job up to 1024 bytes per message Interface Level 1 of the ISO / OSI reference model Number of possible connec-tions per CP

1 (point-to-point connection)

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 162/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.4 Modbus protocol

Basic characteristics Apart from the already introduced protocols, a number of other communica-tion protocols are also available in the field of automation technology. An option was created for some of these protocols to be also used within SIMATIC. There aren’t any own modules for processing this protocol stack, neither for the modbus protocol nor for other protocols. The option of connecting sys-tems which support only this protocol to SIMATIC S7 was nevertheless created. For this purpose some of the high-end communication processors for serial communication were provided with reloadable protocol drivers. Hereby, the stacks and protocol mechanisms necessary for communica-tion were realized in software form. The modbus itself is a master-slave system, similar to the already de-scribed PROFIBUS DP. With both available drivers, you are using the GOULD-MODBUS protocol in RTU format as master or as slave. This en-ables connection to Modicon or Honeywell logic controllers. As opposed to DP communication, the communication is hereby controlled with function codes. Furthermore, unlike known from DP, the I/O data are not accessed cyclically, but data of the logic controller are accessed directly, similar to S7-communication. The modbus provides a number of function codes, which by means of the communication processor are converted to SIMATIC S7 function calls. From a physics point of view, the interfaces can be operated on:

• RS 232 C,

• 20mA (TTY) as well as on

• RS 422 / 485 Multi-point connections on RS 422/485 are possible, up to 32 slaves can be connected to a master. In order to set up multi-point networks with other in-terfaces, further hardware is necessary.

Services of the protocol The available modbus protocol drivers support the following function codes:

Table 3-101

Functions codes

Slave Master Funktion according to MODBUS specification

General description

01 yes yes Read Output Status Reading individual bits 02 yes yes Read Input Status Reading individual bits 03 yes yes Read Output Registers Reading register (words) 04 yes yes Read Input Registers Reading register (words) 05 yes yes Force Single Coil Writing 1 bit

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 163/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Functions codes

Slave Master Funktion according to MODBUS specification

General description

06 yes yes Preset Single Register Writing 1 register (word) 07 no yes Read Exception Status Reading out the event bit 08 yes yes Loop Back Diagnostic Test Line check 11 no yes Fetch Communications Event

Counter Reading ”Status Word“ and ”Event Counter“ from the slave.

12 no yes Fetch Communications Event log

Reading ”Status Word“, ”Event Counter“, ”Message Counter“, and ”Event Bytes“ from the slave.

15 yes yes Force Multiple Coils Write several bits 16 yes yes Preset Multiple registers Writing several registers

Advantages and disadvantages of the Modbus protocol The advantages and disadvantages of using this protocol are listed in the below:

Table 3-102

Advantages 1 Easy connection to Modicon or Honeywell systems. 2 Suitable for small to average data amounts (<=255 bytes) 3 The data transfer is acknowledged.

Disadvantages

1 Considerable configuration and programming effort. 2 The protocol is not widely available within the SIAMTIC.

Configuration steps when using the protocol in SIMATIC S7 The following table contains the configuration steps necessary for the Mod-bus protocol.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 164/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-103

Configuration step S7-300 S7-400

1. Configuration of the partner station

Not necessary Partner station and used PTP network are added within the S7 project.

2. Hardware configura-tion of the station

The used modules are defined in the hardware configuration of the station.

3. Defining the basic parameters of the CP

The Modbus specific parameters are defined via the configuration wizard installed with the loadable driver.

4. Assigning interfaces Not necessary Assigning the communication interface of the communication processor

5. Properties of other station

Not necessary Defining the properties of the partner station, including assign-ing the used PtP network.

6. Loading the configu-ration data

Loading the configuration data into the used CPU and the CP.

7. User programming The transmission jobs are triggered and processed via the user inter-face of the respective services.

Note The functions available for master and slave interfaces are described in the re-spective, following interface descriptions.

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 165/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.4.1 Modbus-Master The following section gives a description of the user interfaces as well as the performance data of the Modbus-Master interface.

User interface S7-300 The following section explains the SIMATIC S7 user blocks for serial con-nection via CP 341 in detail.

The P_SND_RK block

Figure 3-38

Table 3-104

Parameter Note

SF Select send or receive data, here send data ’S’. REQ Trigger job with positive edge

R Cancel job with positive edge LADDR Base address of the communication processor config-

ured in STEP 7 DB_NO Data block number of the data source.

DBB_NO Data byte number of the start byte of the data source. LEN Length of the data message to be sent

R_TYP Address type of the partner CPU, must be ’X’ here.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 166/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Note

DONE Execution information for the successfully completed write send job.

ERROR Error display if an error occurred during the function. STATUS Status display for detailed information about the status

of a block or about an error.

Note: The further parameters of the block are not required and can remain empty.

The P_RCV_RK block

Figure 3-39

Table 3-105

Parameter Note

EN_R Receive permission for the P_RCV_RK block. R Cancel job with positive edge

LADDR Base address of the communication processor config-ured in STEP 7

DB_NO Data block number of the data source. DBB_NO Data byte number of the start byte of the data source.

NDR Execution information for the successfully completed write receive job.

ERROR Error display if an error occurred during the function. LEN Data length of the received data message

STATUS Status display for detailed information about the status of a block or about an error.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 167/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Note on the P_RCV_RK block The R_RCV_RK block is only necessary if data are expected from the Modbus slave. All further parameters of the block are not required and can remain empty.

User interface S7-400 The following section in detail explains the SIMATIC S7 user blocks for se-rial connection via CP 441-2 via the Modbus protocol, the BSEND / BRCV function blocks.

BSEND function block

Figure 3-40

Table 3-106

Parameter Note

EN_R Job trigger for the BSEND job R Input for actively resetting the function. ID Connection ID according to the configuration in NetPro.

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error display if an error occurred during the function. STATUS Status display for detailed information about the status

of a block or about an error. SD_1 Information on the send areas within the local CPU LEN Length of the data area to be sent

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 168/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

BRCV function block

Figure 3-41

Table 3-107

Parameter Note

EN_R Job trigger for the BRCV job ID Connection ID according to the configuration in NetPro.

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error display if an error occurred during the function. STATUS Status display for detailed information about the status

of a block or about an error. RD_1 Information on the target data area within the local

CPU LEN Length of received data area

Quantity framework of the Modbus master protocol

Table 3-108

Characteristic Range of values

Data range up to 255 bytes per job Interface Level 7 of the ISO / OSI reference model Number of possible connec-tions per CP

1 (point-to-point connection), up to 32 in multipoint systems

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 169/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.4.2 Modbus slave The following section gives a description of the user interfaces and the per-formance data of the Modbus-Slave interface.

User interface S7-300 The following section explains the SIMATIC S7 user block for using the Modbus-Slave functionality via the CP 341 in detail.

Figure 3-42

Table 3-109

Parameter Note

LADDR Base address of the CP START_TIMER Timer for monitoring time start START_TIME Time value of monitoring time start

OB_MASK Mask I/O access error and delay alarms. CPSTART Start FB initialization

CP_START_FM Initialization becomes active with rising edge of CP_START.

CP_START_NDR Info: Write request from CP CP_START_OK Startup terminated without error

CP_START_ERROR Startup terminated with error ERROR_NR Error number

ERROR_INFO Additional error information

User interface S7-400 The following section explains the SIMATIC S7 user block for using the Modbus-Slave functionality via the CP 441-2 in detail.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 170/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Figure 3-43

Table 3-110

Parameter Note

ID Connection ID from NetPro START_TIMER Timer for monitoring time start START_TIME Time value of monitoring time start

STATUS_TIMER Read timer for SYSTAT STATUS_TIME Read time interval for SYSTAT

OB_MASK Mask I/O access error and delay alarms. CP_START Start FB initialization

CP_START_FM Initialization becomes active with rising edge of CP_START.

CS_START_NDR Info: Write request from CP CP_START_OK Startup terminated without error

CP_START_ERROR Startup terminated with error ERROR_NR Error number

ERROR_INFO Additional error information

Note Further detailed information on the functions to be used are available in the follow-ing manual: “Loadable driver for point-to-point CPs MODBUS protocol RTU-format S7 is Slave”

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 171/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Quantity framework of the Modbus slave protocol

Table 3-111

Characteristic Range of values

Data range Up to 255 bytes Interface Level 7 of the ISO / OSI reference model Number of possible connec-tions per CP

1 connection

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 172/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

3.4.5 Data highway protocol

Basic characteristics Apart from the already introduced protocols, a number of other communica-tion protocols are also available in the field of automation technology. An option was created for some of these protocols to be also used within SIMATIC. There aren’t any own modules for processing this protocol stack neither for the data highway protocol nor for other protocols. The option of connecting systems which support only this protocol to SIMATIC S7 was nevertheless created. For this purpose some of the high-end communication processors for serial communication were provided with reloadable protocol drivers. Hereby, the stacks and protocol mechanisms necessary for communica-tion were described in software form. The Asynchrone Link Full-Duplex (DF1) protocol is used here for trans-ferring data. Communication partners can be all modules for which the DF1 protocol can be parameterized on the “Asynchrone Link” interface. On a physical layer, the data highway protocol can be used on:

• RS 232,

• 20mA (TTY) or

• RS 422

Services of the protocol The data highway protocol exclusively supports the Send / Receive ser-vice. This enables active data transmission between two client stations. In this process, data are exchanged between the applications by means of send / receive function blocks on both sides.

Advantages and disadvantages of the data highway (DF1) protocol The advantages and disadvantages of using this protocol are listed in the below:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 173/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 3-112

Advantages 1 Easy connection to Allen Bradley systems. 2 Suitable for average to large data amounts (<=1204 / 4096 bytes) 3 The data transfer is acknowledged.

Disadvantages

1 Considerable configuration and programming effort. 2 The protocol is not widely available within the SIAMTIC.

Configuration steps when using the protocol in SIMATIC S7 The following table contains the configuration steps necessary for the data highway (DF1) protocol.

Table 3-113

Configuration step S7-300

1. Hardware configura-tion of the station

The used modules are defined in the hardware con-figuration of the station.

2. Defining the basic parameters of the CP

The data highway specific parameters are defined via the configuration wizard installed with the loadable driver.

3. Loading the configura-tion data

Loading the configuration data into the used CPU and the CP.

4. User programming The data are transmitted coordinated to the partner station via the user interface of the respective mod-ules.

User interface S7-300 The following section explains the SIMATIC S7 user blocks for serial con-nection via CP 341 in detail.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 174/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The P_SND_RK block

Figure 3-44

Table 3-114

Parameter Note

SF Select send or receive data, here send data ’S’. REQ Trigger job with positive edge

R Cancel job with positive edge LADDR Base address of the communication processor config-

ured in STEP 7 DB_NO Data block number of the data source.

DBB_NO Data byte number of the start byte of the data source. LEN Length of the data message to be sent

R_TYP Address type of the partner CPU, must be ’X’ here. DONE Execution information for the successfully completed

write send job. ERROR Error display if an error occurred during the function. STATUS Status display for detailed information about the status

of a block or about an error.

Note: The further parameters of the block are not required and can remain empty.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 175/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

The P_RCV_RK block

Figure 3-45

Table 3-115

Parameter Note

EN_R Receive permission for the P_RCV_RK block. R Cancel job with positive edge

LADDR Base address of the communication processor config-ured in STEP 7

DB_NO Data block number of the data source. DBB_NO Data byte number of the start byte of the data source.

NDR Execution information for the successfully completed write receive job.

ERROR Error display if an error occurred during the function. LEN Data length of the received data message

STATUS Status display for detailed information about the status of a block or about an error.

Note: All further parameters of the block are not required and can remain empty.

User interface S7-400 The following section in detail explains the SIMATIC S7 user blocks for se-rial connection via CP 441-2 via the data highway (DF1) protocol, the BSEND / BRCV function blocks.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 176/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

BSEND function block

Figure 3-46

Table 3-116

Parameter Note

EN_R Job trigger for the BSEND job R Input for actively resetting the function. ID Connection ID according to the configuration in NetPro.

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error display if an error occurred during the function. STATUS Status display for detailed information about the status

of a block or about an error. SD_1 Information on the send areas within the local CPU LEN Length of the data area to be sent

BRCV function block

Figure 3-47

Table 3-117

Parameter Note

EN_R Job trigger for the BRCV job ID Connection ID according to the configuration in NetPro.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 177/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Parameter Note

R_ID Parameter for sub-addressing within a connection. Both partner function blocks must use the same value.

NDR Execution information for the successfully completed write receive job.

ERROR Error display if an error occurred during the function. STATUS Status display for detailed information about the status

of a block or about an error. RD_1 Information on the target data area within the local

CPU LEN Length of received data area

Quantity framework of the data highway protocol

Table 3-118

Characteristic Range of values

Data range up to 1024 / 4096 bytes per job (S7-300 / S7-400)

Interface Level 7 of the ISO / OSI reference model Number of possible connec-tions per CP

1 (point-to-point connection), up to 32 in multipoint systems

Back to protocol overview Serial Protocols

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 178/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

4 Compendium / Glossary

ISO-OSI reference model Communication being used for data exchange requires the previous agreement in which way it should take place. The consideration of different communications has shown that the operation schemes are often similar. The increasing significance of the communication in the world economy caused the ISO (International Standards Organization), an institution of the UNO, to form a work group dealing with the standardization of the computer communication in the seventies of the 20th century. In 1983 the ISO-Norm 7498 (later also taken up into the Norm CCITT X.200), a reference model for computer communication with the title “Basic Reference Model for Open Systems Interconnection (OSI Reference Model)“ was drawn up due to the committee’s work. This describes the communication of open systems, i.e. of systems open for this kind of com-munication. This cannot be equated with “open communication”. The ISO-OSI reference model divides the communication abstractly in seven levels (layers) with defined functionality, the reason why the model is often referred to as OSI Layer Model. Each layer has the task to take over a specific, clearly defined group of subtasks within the communication. Each of the communication partners involved includes all seven layers. The layers communicate with each other via clearly defined interfaces facilitat-ing the exchange of individual layers without intervening the functionality of the system as a whole. At these interfaces, each layer provides services which can be used by the neighboring layer. The following layers can be seen within the layer system.

Table 4-1

Layer Description Explanation

7 Application Layer Here the network-based services are available for the user’s application.

6 Presentation Layer The structures of the user data are converted here before being transferred into the application layer.

5 Session Layer The defined interface for establishing and remov-ing sessions.

4 Transport Layer Error-free and logical channels for transferring data are made available here.

3 Network Layer This layer transports data from their source to their destination and possibly defines the route of the data.

2 Data Link Layer The data formats for the data transfer are deter-mined here. In addition, the access type to the network is defined here. This is divided in MAC (Medium Access Control Layer) and LLC (Logical Link Control).

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 179/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Layer Description Explanation

1 Physical Layer This layer defines the electrical and mechanical properties of the transmission medium.

TCP/IP The ARPANET, forefather of the TCP/IP protocol, was first deployed in 1969, long before the Ethernet idea was born. The development of the modern TCP began in 1976 until it assumed its present character with the assignment of the RFC 793 in 1981. The TCP/IP protocol family on Ethernet can be structurally described as fol-lows:

Figure 4-1: Structure of the TCP/IP Although not related to the ISO-OSI reference model, the structure of TCP/IP is very similar to it. The ISO-OSI reference model was “completed” in 1983 and the TCP/IP model in 1981. Nevertheless, there is an obvious similarity between the TCP/IP and ISO-OSI reference model.

Layer model of the TCP/IP protocol The following overview describes the functionality of individual layers within the TCP/IP protocol:

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 180/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Table 4-2

Layer Description

Application Layer The top layer of the TCP/IP layer model is called application layer. This layer offers a number of application protocols which many applications are based on. These application protocols are based either on UDP or TCP and some even on both of them. One of these supplements to the TCP protocol is RFC 1006 “ISO Transport Services on top of the TCP“.

Transport Layer The transport layer is based on the internet layer. It forms the actual data interface for applications or protocols which are based on TCP/IP. This layer is mainly divided into two large, equal blocks: • The UDP (User Datagram Protocol) which functions as a datagram

interface and transmits encapsulated data via a not acknowledged, connectionless network service.

• The (Transmission Control Protocol), an acknowledged, connection-oriented protocol transmits data in a byte flow.

Internet Layer The internet layer is based on the physical layer and can be compared with the network layer of the ISO-OSI layer model. The function of IP (Internet Protocol) is to transfer data safely from one network to an-other until the destination is reached. This transmission is independent of the selected path and of the used network. Besides the Internet Pro-tocol, an ARP (Address Resolution Protocol) is also located at the Internet layer. The IP has an unacknowledged functionality, so the securing of data transmission must be ensured at one of the higher layers.

Physical Layer The basis of the layer model is a network layer (physical layer). Ac-cording to the TCP/IP philosophy, this layer is kept as flexible as pos-sible which enables a quick connection to new networks or networks of different types so that the TCP/IP protocol is as portable as possible.

Acknowledgement mechanism An acknowledgement mechanism is an implemented or systematic func-tionality acknowledging received data flows or messages with a short in-formation, e.g. in terms of completeness, to the sender.

Baud rate The baud rate refers to the speed of data exchange between different sta-tions. This transmission speed is measured in bits/s or bauds.

Bus profile The bus profile is a series of parameters which are used to define specific system properties. For example, the reaction times of the addressed part-ners, the number of repetitions for messages and the like are specified

Client A client is a device or a general object using the service of another station, often of a server.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 181/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Connection types • Static connections Static connections are connections configured within STEP 7 and actively connected without program calls, by means of the communication modules.

• Dynamic connections Dynamic connections are connections which are exclusively connected and possibly disconnected by program calls .

CP The Communication Processor is a module dealing exclusively with com-munication tasks and connecting a station to a communication system.

CSMA The term CSMA (Carrier Sense Multiple Access) is referred to an acciden-tal access procedure to a mutual bus line. When a station wants to send, the bus line is to be checked as to whether it is blocked by another station. If the line is free, the station will start to send, otherwise the line bid will be deferred for a certain time and the station starts a new attempt later on. (Multiple Access).

Datagram A datagram is a completed data package for the transmission via an IP network. A data package mostly consists of a header and the data of the above transport layer of the ISO reference model in the user data area.

Data consistency The size of a data area which cannot simultaneously be changed by com-peting processes is referred to as a "consistent data area". Hence, a data area larger than the consistent data area could be falsified as a whole.

Deterministics The term deterministics describes the degree of freedom within a closed system. With regard to PROFIBUS it defines the ability to predict when a specific station will regain the right to send, thus being ready for data transmission.

Communication method • Client/Client communication A Client/Client communication is an active communication of two active sta-tions with each other. In this connection, both stations are able to send and to receive data.

• Client/Server communication

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 182/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

A Client/Server communication is a unilateral communication connection between two stations. Here, the client is the only active part of the commu-nication. It can access to data and functions of the server (service provider)

MAP MAP (Manufacturing Automation Protocol) is a network protocol which is used for the automation and production systems in the automotive industry (GM, Opel).

Master As an active station in a network, the master is able to send data without being externally triggered by other stations of the network or to poll cycli-cally data from other stations, usually slaves.

Master-Slave systems: In a Master-Slave system, one or several masters are cyclically connected to the slaves allocated to them. In case of Master-Slave systems with dif-ferent priority classes, the master of lower priority can access the slaves of masters with a higher priority. However, the master cannot own his slave as long as the master with the higher priority is still active.

MPI bus The MPI bus is a subtype of the widely used PROFIBUS. Both share physi-cally the same medium (RS 485). With respect to protocols both systems, MPI and PROFIBUS, are closely related to each other. Both systems can also be operated on one bus. However, within the MPI protocol some modi-fications have been carried out to keep the bus as simple as possible for its actual function as programming bus. Contrary to the PROFIBUS, the MPI bus is dependent on the potential, thus considerably limiting its spatial ex-tension.

Multicast / Broadcast Multicast / broadcast are services sending data on an unacknowledged ba-sis to several or all listening stations. Both services differ by:

Table 4-3

ServiceCriterion

Multicast Broadcast

Receiver A group of stations defined in a multicast group

All stations at the bus

Performance of the SIMATIC

Can be used either sending or receiving

Only sending

PDU PDU = Protocol Data Unit (OSI). The data package which is transferred via a network.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 183/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Performance Performance is a standard for the performance of a completed system or a data transfer.

PPI bus Like the MPI bus, the PPI bus (Peer to Peer Interface) is designed as a programming bus. But unlike the MPI bus, the PPI bus is not designed for lateral communication of data, among other things, this is caused by the partially interrupted transfer of the individual messages.

Processing systems / Function calls • Synchronous A synchronous function call is only completed when the called function has completely been processed. A program with a synchronous function call remains at this program point until the called function has been completed.

• Asynchronous An asynchronous function call is processed parallel to the actual program calling up this function. The called function has not to be terminated and the calling program does not remain at this program point. To be able to moni-tor the successful conclusion of an asynchronous function, the status vari-ables of the called function are to be usually read several times, e.g. in a program part which is often passed.

Protocol A protocol is a precise down-to-the-bit agreement between communication partners required to perform a specific communication service. The protocol defines the content structure of the data traffic on the physical line and de-fines, for example, the operating mode, connection setup procedure, data security or the transfer speed.

Procedure A procedure is generally a process. It is often based on a specified protocol and uses coordinately some of the services specified therewith to facilitate the communication flow.

RFC (RFC 1006) The documentation of the RFC (Request for Comments) defines the func-tions, functionalities and the properties of the TCP/IP protocol. They are available for everyone in the Internet. The RFC 1006 specifies the so-called “ISO on top of TCP protocol“ which is represents an illustration of the ISO transport protocol to the TCP protocol.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 184/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Routing The term "routing" usually refers to the establishment of a communication path from A to B. In the context of automation and IT engineering, the term "routing" implies the provision of a communication path for any type of data packages to be transmitted (routed) from station A to station B across the boundaries of different networks. However, this does not ensure that the “shortest” path will always be selected, for the data, but, as far as possible, the fastest path.

Secured data transfer The data transfer is secured if the sending of data has the following proper-ties:

• If the data are transmitted, the sender will be informed.

• It is actually not possible to duplicate the data by different paths (i.e. a message sent time-delayed via different paths cannot be received twice).

• The data are consistent.

• The data sequence is known.

Server A server is a device or generally an object offering its services to other de-vices or objects for utilization.

Services Options for data exchange (services) offered by a communication protocol. Services are used as an interface for the used layer of the ISO reference model.

Slave Slaves are passive stations which are configured and polled by an active station, a master. Slaves can be either “stupid” or “intelligent“ modules.

Station A station is a bus station identified at the appropriate bus by a physical ad-dress.

Token bus system Network access procedures for allocating buses for several active stations (used with the PROFIBUS). The right to send (Token) is passed on by an active station to another active station. For each active station applies: Be-tween Token sending and Token receiving is a Token cycle.

Communication with Automation Systems

Rev. A - Endgültig 12.04.2004 185/185

Cop

yrig

ht ©

Sie

men

s AG

200

5 A

ll rig

hts

rese

rved

20

9829

54_S

IMAT

IC_C

omm

_DO

KU_v

10_e

Unidirectional or bidirectional communication Unidirectional or bidirectional communication describes the active route of the communication.

• Unidirectional communication is only actively pronounced in one direction, even if acknowledgments and answers can also be transported into the opposite direction.

Bidirectional communication is actively pronounced in both directions. I.e. both communication partners are actively involved in the data transfer.

WAN WAN = Wide Area Network. These are large-surface data networks ex-ceeding an individual, closely limited place.