39040038 Datasync Doku v21 En

download 39040038 Datasync Doku v21 En

of 44

Transcript of 39040038 Datasync Doku v21 En

  • 8/18/2019 39040038 Datasync Doku v21 En

    1/44

     

     Applications & Tools Answers for industry.

    Cover

    Communication: Performant Data SynchronizationBetween Several Field and One Head

    PLC 

    S7-1200 Set 17

    Application Description June 2013

  • 8/18/2019 39040038 Datasync Doku v21 En

    2/44

    Table of Contents

    2Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Warranty and Liability 

    Note The Application Examples are not binding and do not claim to be completeregarding the circuits shown, equipping and any eventuality. The ApplicationExamples do not represent customer-specific solutions. They are only intendedto provide support for typical applications. You are responsible for ensuring thatthe described products are used correctly. These Application Examples do notrelieve you of the responsibility to use safe practices in application, installation,operation and maintenance. When using these Application Examples, yourecognize that we cannot be made liable for any damage/claims beyond theliability clause described. We reserve the right to make changes to these Application Examples at any time without prior notice. If there are any deviationsbetween the recommendations provided in these application examples and otherSiemens publications – e.g. Catalogs – the contents of the other documentshave priority.

    We do not accept any liability for the information contained in this document.

     Any claims against us – based on whatever legal reason – resulting from the use ofthe examples, information, programs, engineering and performance data etc.,described in this Application Example shall be excluded. Such an exclusion shallnot 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 of a product, fraudulent concealment of adeficiency or breach of a condition which goes to the root of the contract(“wesentliche Vertragspflichten”). The damages for a breach of a substantialcontractual obligation are, however, limited to the foreseeable damage, typical forthe type of contract, except in the event of intent or gross negligence or injury tolife, body or health. The above provisions do not imply a change of the burden of

    proof to your detriment.

     Any form of duplication or distribution of these Application Examples or excerptshereof is prohibited without the expressed consent of Siemens Industry Sector.

    Caution: The functions and solutions described in this article confine themselves to therealization of the automation task predominantly. Please take into accountfurthermore that corresponding protective measures have to be taken up in thecontext of Industrial Security when connecting your equipment to other parts of theplant, the enterprise network or the Internet. Further information can be foundunder the Entry ID 50203404.

    http://support.automation.siemens.com/WW/view/en/50203404  

    http://support.automation.siemens.com/WW/view/en/50203404http://support.automation.siemens.com/WW/view/en/50203404

  • 8/18/2019 39040038 Datasync Doku v21 En

    3/44

    Table of Contents

    DatasyncV21, Entry ID: 39040038 3

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Table of ContentsWarranty and Liability .............................................................................................. 2 

    1  Task................................................................................................................. 4 

    2  Solution overview ........................................................................................... 5 

    2.1  Description of the core functionality.................................................... 7 2.1.1  Overview and description of the user interface ................................... 7 2.1.2  Synchronization of the data................................................................ 9 2.1.3  Simulation of the data in the field PLCs ............................................ 11 2.1.4  Time synchronization ....................................................................... 12 2.2  Hardware and software components used ....................................... 12 

    3  The blocks of the data synchronization ...................................................... 14 

    3.1  Complete overview of the program blocks........................................ 14 3.1.1  Program overview of the head PLC.................................................. 14 3.1.2  Program sequence in the field PLC .................................................. 15 

    3.2  Data blocks ..................................................................................... 16 3.2.1  The data block of the head PLC ....................................................... 16 3.2.2  The data block of the field PLC ........................................................ 20 3.3  The data block “DATASYNC_X” ...................................................... 22 

    4  Mechanisms of data synchronization .......................................................... 25 

    4.1  Control process in the overview ....................................................... 25 4.2  Functioning of the function block DATASYNC_X .............................. 26 4.3  Behavior in the event of a power failure ........................................... 27 

    5  Performance Measurement .......................................................................... 28 

    5.1  Conception of the measurement ...................................................... 28 5.2  Values of the performance measurement ......................................... 30 

    5.3  Result .............................................................................................. 31 6  Installation .................................................................................................... 32 

    6.1  Hardware installation ....................................................................... 32 6.2  Software installation......................................................................... 33 

    7  Starting up the Application .......................................................................... 34 

    7.1   Assigning the IP addresses.............................................................. 34 7.2  Download the PLCs and the panels ................................................. 37 

    8  Operating the Application ............................................................................ 40 

    9  Related literature .......................................................................................... 42 

    10  History .......................................................................................................... 42 

    11  Appendix A: Measured Data ........................................................................ 43 

    11.1  Head: S7-1200; 6 ms program load ................................................. 43 11.2  Head: S7-1200; 50 ms program load ............................................... 43 11.3  Head: WinAC; 6 ms program load .................................................... 44 11.4  Head: WinAC; 50 ms program load .................................................. 44 

  • 8/18/2019 39040038 Datasync Doku v21 En

    4/44

    1 Task

    4Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    1 Task

    Introduction

    For synchronization tasks and for the exchange of control and status informationamong a head PLC and field PLCs, e.g. for solar trackers in solar parks, aperformant cyclic communication system is needed.

    For reducing the data transfer, e.g. to an HMI or when a remote supervision isused, the data are to be exchanged in bundles by means of a data concentrator(here: head PLC).

    The figure below provides an overview of the automation task.

    Figure 1-1

    Field PLC 1 Field PLC 2 Field PLC n

    Head PLC HMI

     

    Description of the automation problem A module for the data synchronization and the exchange of control and statusinformation among the head PLC and several field PLCs is to be developed. It is toassume the following task independently:

      Supply of all the field PLCs with the same or different sets of data from thehead PLC (down sync).

      Updating the sets of data from all the field PLCs in the head PLC (up sync).

    Requirements of the automation task

    The following requirements are posed to the block:

      Optimal and performant utilization of the available connection resources of the

    head and field PLC.  Simple adaptation to variable quantities (data volume sent and received).

      To be used with S7-1200 and S7-300/400/IPC with Win AC.

      The programming is to be done mainly with SCL.

  • 8/18/2019 39040038 Datasync Doku v21 En

    5/44

    2 Solution overview

    DatasyncV21, Entry ID: 39040038 5

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    2 Solution overview

    Display

    The following figure gives a schematic overview of the most important componentsof the solution:

    Figure 2-1

    HMI Panel S7-1200 IPC + WinAC

    Field PLCs S7-1200 (e.g. in solar trackers) with

    function block DATASYNC_SUB

    DATASYNC_

    HEAD

    Possible Head PLCs with function block

    DATASYNC_HEAD

    DATASYNC_

    SUB

    DATASYNC_

    HEAD

    DATASYNC_

    SUB

    DATASYNC_

    SUB

    DATASYNC_

    SUB

     

    Setup

    The application example is demonstrated in a concrete example - controlling solartrackers.

    The expression solar tracker means solar energy systems which can be trackedaccording to the position of the sun to ensure the best possible energy yields.

    For the field PLC, a CPU S7-1200 is used in this example. For the sake of a betterclarity, the number has been reduced to four.

    For the head PLC, this solution uses two types of devices:

      An S7-1200 controller

      An S7-300/400 / IPC with WinAC

  • 8/18/2019 39040038 Datasync Doku v21 En

    6/44

    2 Solution overview

    6Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Description

    With the function block “DATASYNC_X” (X:= HEAD or SUB), a block has beendeveloped that assumes the control of the data synchronization automatically.

    The head PLC sequentially establishes an ISO-on-TCP communication connectionwith each field PLC and terminates it again. Data is sent to the field PLCs and datais received from them. After all field PLCs have been operated, the process isrepeated.The following figure summarizes the data exchanged between head PLC and fieldPLCs.

    Figure 2-2

    Field PLC1..4

      Head PLC

    Data structure of the Head-PLC:

    • Geographic position (longitude / latitude)

    • Requirement time synchronization

    • Current time

    Data structure of the Field PLCs:

    • Zenith / azimuth angle

    • Current weather data (temperature / wind)

    • Production data

    It is always the head PLC which takes the initiative.

    Since the field PLCs are only passive and wait for the request from the head PLC,there is a separate “DATASYNC_SUB” block for the field PLC. Its task is thesupply and disposal of the send and receive data.

    The data communication among the PLCs is displayed in images by the HMI panel.

    For displaying and updating the images, the panel uses the send and receive dataof the head PLC.

    Delimitation

    This application does not include any

      information concerning the programming language SCL.

      basic information on industrial Ethernet.

      information on astronomic algorithm or solar tracking.

    Basic knowledge of these topics is assumed.

  • 8/18/2019 39040038 Datasync Doku v21 En

    7/44

    2 Solution overview

    DatasyncV21, Entry ID: 39040038 7

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    2.1 Description of the core functionality

    2.1.1 Overview and description of the user interface

    For commissioning, operation and monitoring there is

      an overview for operating and configuring the solar trackers.

      an information surface for every field PLC.

    The user interface has been realized in a comfort panel TP700.

    For updating the images with the current data, an HMI connection between thepanel and the head PLC has been configured.

    Overview head PLC

    In this overview screen, all the field PLCs can be configured when their geographicposition is entered and the time synchronization can be triggered.

    The longitude and the latitude are to be entered in decimal degrees.

    Figure 2-3

  • 8/18/2019 39040038 Datasync Doku v21 En

    8/44

    2 Solution overview

    8Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Information screen

    There is a separate information screen for every field PLC. The calculated zenithand azimuth angles and simulated weather information and production data are

    displayed here.Figure 2-4

  • 8/18/2019 39040038 Datasync Doku v21 En

    9/44

    2 Solution overview

    DatasyncV21, Entry ID: 39040038 9

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    2.1.2 Synchronization of the data

    Schematic layout

    The data synchronization between the head PLC and the field PLCs is donecomfortably with the function block “DATASYNC_X”.

    This block implements the cyclic and performant data exchange between the headPLC and the field PLCs.

    The defined data structure is sent from the head PLC to the field PLC when theconnection has been built up on both sides. The field PLC waits for reception andthen sends its own data structure to the head PLC(see Figure 2-2).

     As soon as the head PLC has received the data sent from the field PLC, the dataexchange is completed. The connection is disconnected.

    The exchanged data structures and the IP addresses of the field PLCs are stored

    in different global data blocks.

    Increasing the performance by parallel connections

    There is the possibility of operating several field PLCs in parallel (multiplexing). Thefunction block “DATASYNC_HEAD” can be called with a different instance datablock in the OB1 of the head PLC for every available connection. The maximumnumber of calls is limited by the available connection resources of the head PLC.

    In the present Application Example, these parallel connections are being used.

    Note The maximum admissible number of parallel connections varies depending in thehead PLC.

      S7-1200 supports no more than eight connections.

      S7-300/400 / IPC with WinAC supports up to 32 connections.

  • 8/18/2019 39040038 Datasync Doku v21 En

    10/44

    2 Solution overview

    10Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    The following graphic shows the possibility of increasing the performance bymultiplexing.

    Figure 2-5

    DATASYNC_

    HEAD

    DATASYNC_

    HEAD

    DATASYNC_

    HEADHEAD PLC

    DATASYNC_

    FIELD

    DATASYNC_

    FIELD

    DATASYNC_

    FIELDFIELD PLCs

      DATASYNC_

    FIELD…

    1   2 3   z

    1

    3

    2   …

    z

    Multiplex z field PLCs

    via several channels

    n available

    connection

    resources

    DATASYNC_

    HEAD…

     

    Example:

     An S7-1200 CPU is used as the head PLC, and there are 12 field PLCs. Thismakes possible the following combinations:

      Number of available connection resources: n = 8

      Number of field PLCs: z = 12

    Therefore, the “DATASYNC_HEAD” block can be called in eight instances. Thereare eight communication channels for the 12 field PLCs.In the dynamic multiplex mode, the 12 field PLCs are synchronized through the

    eight channels.

  • 8/18/2019 39040038 Datasync Doku v21 En

    11/44

    2 Solution overview

    DatasyncV21, Entry ID: 39040038 11

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Communication blocks

    The communication between the head PLC and the field PLCs is done by an ISO-on-TOP connection.

    The connecting and disconnecting process and the sending and receiving of thedata is internally carried out in the “DATASYNC_X” block by means of the followingstandard communication blocks:

    Table 2-1

    Block Description

    TCON The TCON command establishes the communicationconnection.

    TDISCON TDISCON establishes the connection to the partner station.

    TSEND TSEND sends data through an existing communicationconnection.

    TRCV The counterpart to TSEND is TRCV. With this command, data

    can be received through an existing communicationconnection.

    2.1.3 Simulation of the data in the field PLCs

    Determining the position of the sun, using an astronomical algorithm

    Depending on the position of the earth, the position of the sun can be calculatedwith the aid of an astronomical algorithm, using details on longitude and latitude.This position of the sun is described with the azimuth angle for the horizontalalignment and zenith for the vertical alignment. To calculate the position of the sun,the algorithm needs the Universal Time Coordinated (UTC) to take the earth’s

    changing orbital period around its own axis into account.

    Table 2-2

    Parameters Unit Description

    Longitude [°] Longitude from 0° (North) to 360 °

    Latitude [°] Latitude from -90° (South pole) to +90° on the Northpole

    In this Application Example, the astronomic algorithm is calculated with the functionblock SimpleAstroAlgorithm in the cyclic program of the field PLCs.

    Simulation of the weather and production data in the field PLCs

    The simulation of data that are sent from the field PLCs to the head PLC is done bytime-controlled OBs and a mathematical calculation.

  • 8/18/2019 39040038 Datasync Doku v21 En

    12/44

    2 Solution overview

    12Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    2.1.4 Time synchronization

    For the visualization screen the time synchronization of all the CPUs can be

    synchronized with the current UTC time in the head PLC. The synchronizationtakes place in two steps:

    1. With a trigger command, the head PLC reads out the current time and datehead PLC with the button Activate Timesync by means of the function blockRD_SYS_T. This information is stored in the sending reports of the field PLCsand the time synchronization bit there is set.

    2. The field PLCs receive the information with the next data synchronization andrecognize the requirement to carry out a time synchronization. Then they adapttheir real time clocks to the times they received.

    2.2 Hardware and software components used

    The application was set up with the following components:

    Hardware components

    Table 2-3

    Component No. Order number Note

    CPU 1215C AC/DC/Rly 1 6ES7 215-1BG31-0XB0 Head PLC

    IPC 277D PN/IEBundle with WinAC RTX (F)

    1 6ES7 647-8A… Head PLC

    CPU 1214C DC/DC/DC 1 6ES7 214-1AE30-0XB0 Field PLCField PLC1

    CPU 1212C DC/DC/DC 3 6ES7 212-1AE31-0XB0 Field PLCs

    Field PLC2 - 4HMI panel TP700 Comfort 1 6AV2124-0GC01-0AX0

    SCALANCE X208 1 6GK5208-0BA10-2AA3

    PG / PC 1 For loading the headand field PLCs

    Standard software components

    Table 2-4

    Component No. Order number Note

    STEP 7 Professional V12 1 6ES7822-0A…

    WinCC Professional 1 6AV210…

  • 8/18/2019 39040038 Datasync Doku v21 En

    13/44

    2 Solution overview

    DatasyncV21, Entry ID: 39040038 13

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Example files and projects

    The following list includes all files and projects used in this example.

    Table 2-5Component Note

    39040038_DATASYNC_CODE_v20.zip This zip file contains two STEP 7 V12projects.

      DATASYNC_1200 for the S7-1200CPU as the head PLC.

      DATASYNC_IPC for the IPC withWinAC as the head PLC

    39040038_DATASYNC_DOKU_v20_d.pdf This document.

  • 8/18/2019 39040038 Datasync Doku v21 En

    14/44

    3 The blocks of the data synchronization

    14Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    3 The blocks of the data synchronization

    3.1 Complete overview of the program blocks

    3.1.1 Program overview of the head PLC

    Program structure

    The following graphic shows the complete user program of the head PLC.

    Figure 3-1

    DATASYNC_HE

     AD

    iDB

    OB 1

    DATASYNC_HE

     AD

    RD_SYS_T

    DB_IPADDRESS DB_MANAGE

    DB_RCV_ 

    DATA

    DB_SND_ 

    DATA

    DB_STATE

    iDB

    DATASYNC_HE AD

    iDB

    DATASYNC_ 

    HEAD

    iDB

    TCON

    TRCV

    TSEND

    TDISCON

     

    Description

    Table 3-1

    Block Note

    DATASYNC_HEAD Function block for data synchronization; to enable a paralleldata synchronization with all the other field PLCs (solar tracker),the block is called several times - each time with a differentinstance data block - cyclically in the application program.

    Per field PLC, there is one call of the FB in the OB1 in this Application Example (4 field PLCs 4 calls).

    TCON, TRCV, TSENDand TDISCON

    Function blocks for the communication (see also chapter 2.1.2);the enable the data communication.

    DB_IPADDRESS Data block; contains the IP addresses of all the field PLCs.

    DB_STATE Data block; contains status information of every field PLC.

  • 8/18/2019 39040038 Datasync Doku v21 En

    15/44

    3 The blocks of the data synchronization

    DatasyncV21, Entry ID: 39040038 15

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Block Note

    DB_MANAGE Data block; contains information setting up the communicationchannels.

    DB_RCV_DATA Data block; contains the receive data of the field PLC inseparate structures.

    DB_SND_DATA Data block; contains the receive data of the field PLC inseparate structures.

    RD_SYS_T Function block; responsible for reading out the current and localtime for the time synchronization.

    3.1.2 Program sequence in the field PLC

    Program structure

    The following graphic shows the complete user program of the field PLCs.

    Figure 3-2

    DATASYNC_ 

    SUB

    iDB

    OB 1

    SimpleAstro

     Algorithm

    DB_SND_RCV

     _DATA

    TCON

    TRCV

    TSEND

    WR_SYS_T

    OB 30

    OB 31

     

  • 8/18/2019 39040038 Datasync Doku v21 En

    16/44

    3 The blocks of the data synchronization

    16Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Description

    Table 3-2

    Block Note

    DATASYNC_SUB Function block for data synchronization

    TCON, TRCV, TSEND Function blocks for the communication (see also chapter 2.1.2);the enable the data communication.

    DB_SND_RCV_DATA Data block; contains sending data for and receiving data fromthe head PLC.

    SimpleAstroAlgorithm Function block; calculates the position of the sun on the basis ofthe position data (longitude and latitude) sent.

    WR_SYS_T Function block; responsible for reading out the current and localtime for the time synchronization.

    OB 30, OB 31 Time-controlled organization block for the simulation of theweather and production data

    3.2 Data blocks

    3.2.1 The data block of the head PLC

    Overview

    For establishing a communication connection, the data block “DATASYNC_HEAD”needs more information

      about the field PLC

    –  IP addresses

    –  number of project engineers

    –  feedback concerning the status of the connection

      the maximum number of possible parallel connections

    –  with an S7-1200 as head PLC: eight connections

    –  with an S7-300/400 / WinAC as head PLC: 32 connections

      about the sending and receive structure

    –  size of each structure

    –  storage location

     All these pieces of information are stored in different global data blocks:

    Table 3-3

    Data block Responsible for...

    DB_IPADDRESS IP addresses of the field PLCs used

    DB_MANAGE Number of field PLCs, length of the structures, global trigger forstarting the data synchronization

    DB_RCV_DATA Storage location for the received data of every field PLCs

    DB_SND_DATA Storage for the data to be sent

    DB_STATE Communication status of every field PLC

    These data blocks are described in the following:

  • 8/18/2019 39040038 Datasync Doku v21 En

    17/44

    3 The blocks of the data synchronization

    DatasyncV21, Entry ID: 39040038 17

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    DB_IPADDRESS

    In the global data block “DB_IPADDRESS”, the IP addresses for every field PLCare stored. Every IP address is defined as the data type “Struct”, and divided into

    the segments “REM_1”, “REM_2”, “REM_3” and “REM_4” with the data type“USInt” (S7-1200) or “byte” (WinAC).

    Figure 3-3

    DB_MANAGE

    The global data block “DB_MANAGE” serves for the communication of theconnections.

    Figure 3-4

    In the parameter “Act_SubStation”, the “DATASYNC_HEAD” blocks store thenumber of the last field PLC they called, or read the number of the next free fieldPLC.

    The parameter “Nr_of_Substations” contains the number of field PLCs.

    “REQ_x” are Bool variables for using (REY_x “True”) or the release (REQ_x

    “False”) of a “DATASYNC_HEAD” block and therefore with a connection resource.For every “DATASYNC_HEAD” one bit is provided.

    The parameters “LEN_SNDData” and “LEN_RCVData” each contain the length ofthe send and receive structure in number of bytes.

  • 8/18/2019 39040038 Datasync Doku v21 En

    18/44

    3 The blocks of the data synchronization

    18Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    DB_STATE

    In this data block, the communication status of each field PLC is listed and updatedand observed while “DATASYNC_HEAD” is running. For every station, one byte is

    provided.Figure 3-5

    The value of the status byte is to be interpreted as follows:

    Table 3-4

    Value Meaning

    1 A connection between the head and the field PLCs is being established.

    2 The connection between the head and the field PLC was successfullyestablished.

    3 The data exchange between the head and the field PLC is completed and thecommunication connection is disconnected.

    4 The first attempt to establish a connection between the head and the field PLCfailed.

    5 From the second attempt onwards (the status was “4” before), the system tries toestablish a connection for a certain period of time.

    0 Field PLC available for access.

    DB_SND_DATA and DB_RCV_DATAThe two data blocks contain the data to be synchronized.

    The following rule is applied:

      The structure of the send data of the head PLC must be identical with thereceive structure of the field PLC.

      The structure of the receive data of the head PLC must be identical with thesend structure of the field PLC.

      The send and receive structure is the same for every field PLC.

    For every field PLC one structure is stored in the data block.

    Since the send and receive structure must be identical for all field PLCs, werecommend the use of templates (PLC data types).

    PLC data types are defined data structures which can be opened several times inthe program. The structure of a PLC data type is composed of several componentswhich can have different data types. There are the following possibilities of usingPLC data types:

      PLC data types can be used as data types for variables in a variabledeclaration of code blocks or in data blocks

      PLC data types can be used as templates for creating global data blocks withthe same data structure.

  • 8/18/2019 39040038 Datasync Doku v21 En

    19/44

    3 The blocks of the data synchronization

    DatasyncV21, Entry ID: 39040038 19

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    UDT_HEAD_RCV_STRUCT

     As the data type of the receive data, the template “UDT_HEAD_RCV_-STRUCT” isused:

    Figure 3-6

    With this template, one sector is defined for every field PLC in the receive datablock “DB_RCV_DATA” of the head PLC.

    Figure 3-7

    UDT_HEAD_SND_STRUCT

     As the data type of the receive data, the template “UDT_HEAD_RCV_-STRUCT” isused:

    Figure 3-8

    With this template, one sector is defined for every field PLC in the send data block“DB_SND_DATA” of the head PLC.

    Figure 3-9

  • 8/18/2019 39040038 Datasync Doku v21 En

    20/44

    3 The blocks of the data synchronization

    20Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    3.2.2 The data block of the field PLC

    DB_SND_RCV_DATA

    Since this communication connection is always initiated by the head PLC, it issufficient to integrate only one data block into the user program of the field PLC.

    The global data block “DB_SND_RCV_DATA” contains the send and receivestructure for the data exchange.

    The rules for the send and receive structure are also applied here:

      The structure of the send data of the field PLC must be identical with thereceive structure of the head PLC.

      The structure of the receive data of the field PLC must be identical with thesend structure of the head PLC.

    Here, the data block template is also created by a template.

    UDT_SUB_SND_STRUCT

     As the data type of the receive data, the template “UDT_SUB_SND_-STRUCT” isused:

    Figure 3-10

    UDT_SUB_RCV_STRUCT

     As the data type of the receive data, the template “UDT_HEAD_RCV_-STRUCT” isused:

    Figure 3-11

  • 8/18/2019 39040038 Datasync Doku v21 En

    21/44

    3 The blocks of the data synchronization

    DatasyncV21, Entry ID: 39040038 21

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    With these templates, the data block of the field PLC is defined.

    Figure 3-12

    Note Since the send and receive structures must be identical for all field PLCs, thesetemplates can be reused for the other field PLCs.

  • 8/18/2019 39040038 Datasync Doku v21 En

    22/44

    3 The blocks of the data synchronization

    22Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    3.3 The data block “DATASYNC_X”

    Description

    The function block “DATASYNC_X” controls the data synchronization between thehead and the field PLC.

    For the head and the field PLC, there are different “DATASYNC_X” blocks whichdiffer as far as their functionalities scope and therefore their interface configurationare concerned.

    Interfaces for the head PLC

    Calling the block has been described as follows:

    Figure 3-13

  • 8/18/2019 39040038 Datasync Doku v21 En

    23/44

    3 The blocks of the data synchronization

    DatasyncV21, Entry ID: 39040038 23

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Parameters

    The parameters have the following meaning:

    Table 3-5

    Parameters Type Datatype

    Meaning

    ID

    INPUT

    WORD A unique number for the communication connection. Ifthe “DATASYNC_HEAD” is called several times, adifferent number must be selected.

    REQ BOOL With “True” the data synchronization is triggered and asupply resource is assigned.

    With “False”" the synchronization process is stopped andthe approval of the communication is initiated

    NR_SUBSTATIONS INT Number of project field PLCs

    DB_NR_IPADDRESS Number of the data block“DB_IPADDRESS”.

    DB_NR_STATE Number of the data block“DB_STATE”.

    DB_NR_SND_DATA Number of the data block“DB_SND_DATA”.

    LEN_SND_DATA Length of the send structure

    DB_NR_RCV_DATA Number of the data block“DB_RCV_DATA”.

    LEN_RCV_DATA Length of the receive structure

    IDB_NR_LOC Number of the instance block of this“DATASYNC_HEAD” block

     ACT_SUBNET_NUM

    BER

    IN/

    OUT

    INT Variable for interim storage of the field PLC used last.

    RSC_FREE OUT BOOL With “True”, the connection resource is released, as soonas REQ has been set to “False”.

  • 8/18/2019 39040038 Datasync Doku v21 En

    24/44

    3 The blocks of the data synchronization

    24Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Interfaces for the field PLC

    Calling the block has been described as follows:

    Figure 3-14

    Parameters

    The parameters have the following meaning:

    Table 3-6

    Parameters Type Data type Meaning

    ID

    INPUT

    WORD A unique number for the communication connection.

    REM_IP1

    USINT

    First part of the IP address of the head PLC

    REM_IP2 Second part of the IP address of the head PLC

    REM_IP3 Third part of the IP address of the head PLC

    REM_IP4 Fourth part of the IP address of the head PLC

    SND_DATAIN/ OUT VARIANT

    Pointer to the send section

    RCV_DATA Pointer to the receive section

  • 8/18/2019 39040038 Datasync Doku v21 En

    25/44

    4 Mechanisms of data synchronization

    DatasyncV21, Entry ID: 39040038 25

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    4 Mechanisms of data synchronization

    4.1 Control process in the overview

    With the block “DTASYNC_X” a possibility of replacing control and statusinformation between the head PLC and the field PLCs (solar trackers in solarparks) automatically and effectively and of synchronizing the time has beenrealized.

    The following diagram shows the process in the head and in a field PLCs:

    Figure 4-1

    Initiation of the data

    synchronization

    Find next free field PLC

    Copy IP address of the field

    PLC from the global DB into

    the instance DB

    Disconnect the connection

    Establish connection

    Copy send structure from the

    global DB to the instance DB

    Send data to the free field PLC

    Receive data from the field PLC

    Copy receive structure from

    the instance DB

    to the global DB

    Establish connection

    Copy send structures from theglobal DB to the instance DB

    Receive data from the

    head PLC

    Send data to the central PLC

    Copy receive structure from

    the instance DB

    into the global DB

    Head PLC with

    DATASYNC_HEAD

    Field PLC z with

    DATASYNC_SUB

     

  • 8/18/2019 39040038 Datasync Doku v21 En

    26/44

    4 Mechanisms of data synchronization

    26Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    4.2 Functioning of the function block DATASYNC_X

    In this chapter, the functioning of the “DATASYNC_X” block is briefly explained.

    For more details, please refer to the program code which has good comments.

    Establish communication connection

    The command “TCON” establishes and builds up the communication connection. As soon as the connection is working, it is automatically maintained and monitoredby the CPU. “TCON” is carried out in several cycles.

    The block receives the required information such as

      the IP address of the connection partner

      the number of the connection

    through the input parameters in the “DATASYNC_X” block.

    Send data

    The command “TSEND” sends data through an existing communicationconnection. “TSEND” is carried out in several cycles.

    The block receives the required information through the input parameters in the“DATASYNC_X” block.

    Receive data

    The command “TRCV” sends data through an existing communication connection.“TRCV” is carried out in several cycles.

    The received data are buffered in a receive area, and then they are transmitted tothe receive area.

    The receive area is defined by the following two dimensions:

      pointer at the beginning of the area

      length of the area in number of bytes.

    This information is transmitted by the parameters at the “DATASYNC_X” block.

    Establish a communication connection (head PLCs only)

    The instruction “TDISCON” disconnects the communication connection of the CPUto the communication partner. “TDISCON” is a command working over severalcycles.When the connection has been disconnected successfully, the ID entered in the FB“TCON” is no longer valid and can therefore be neither used for sending nor for

    receiving.

  • 8/18/2019 39040038 Datasync Doku v21 En

    27/44

    4 Mechanisms of data synchronization

    DatasyncV21, Entry ID: 39040038 27

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Copy data

    The transmission of the data (IP address, send and receive structure) between aglobal data block and an instance data block is done by MOVE commands.

    The storage address where the information of the current field PLC is located, isdetermined by an Offset calculation.

    The following graphic shows the principle with the example of an IP address.The global data block “DB_IPADDRESS” contains the IP address for all the fieldPLCs. The block “DATASYNC-HEAD” calculates the Offset for the storage area ofthe IP address of the field PLC to be edited on the basis of the IN/OUT variables“ACT_SUBNET_Number”.

    Figure 4-2

    IP address

    Field PLC 1

    IP addresse

    Field PLC 2

    IP address

    Field PLC 3

    IP address

    Field PLC z

    4- Bytes

    Global DB

    DB_IPADDRESS

    IP address

    Field PLC 3

    Instance DB

    DATASYNC-HEAD

    Offset: 2 * 4-Bytes

    ACT_SUBNET_NUMBER:=3

     

    4.3 Behavior in the event of a power failure

    If more than one field PLCs are involved in the data synchronization, it must bemade sure that the synchronization mechanism to the intact field PLCs is notblocked in the event if one or more field PLCs break down (e.g. because theconnection cable is pulled out).

    To solve this problem, the status of the communication connection of each fieldPLCs is documented in the data block “DB_STATE” (see chapter 3.2.1). Thesestatus values are compiled by means of the status parameters “TCON_Busy” or

    “TRCV_Error” of the communication blocks (TCON, TSEND, TRCV, TDISCON).

    If an interruption of the communication to a field PLC is detected (status value: 4),the block “DATASYNC_HEAD” tries to reestablish the connection for a definedperiod of time (status value: 5). If it does not succeed, this will be acknowledgedwith an error message.

     As soon as a connection has been reestablished, the error message is deleted.

  • 8/18/2019 39040038 Datasync Doku v21 En

    28/44

    5 Performance Measurement

    28Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    5 Performance Measurement

    Objective

    In order to be able to describe the performance of the program, a performancemeasurement is carried out.

    The following chapter describes:

      the concept of the performance measurement.

      the measurement results.

      an analysis of the values.

    5.1 Conception of the measurement

    Structure

    The following hardware constellation was used for the measurement:  Constellation 1:

    –  Head PLC S7-1200-CPU

    –  Field PLCs: up to 32 S7-1200-CPUs

      Constellation 2:

    –  Head PLC IPC

    –  Field PLCs: up to 32 S7-1200-CPUs

    These components were interconnected in accordance with the instructions inchapter 6.

    Figure 5-1

    S7-1200 IPC + WinAC

    1, 4, 8, 16, 32 Field-PLCs S7-1200 with function

    block DATASYNC_SUB

    Head PLCs with up to eight function blocks“DATASYNC_HEAD”

    DATASYNC_

    SUB

    DATASYNC_

    HEAD

    DATASYNC_

    SUB

    DATASYNC_

    HEADDATASYNC_

    HEADDATASYNC_

    HEAD

    DATASYNC_

    SUB

    DATASYNC_

    HEADDATASYNC_

    HEADDATASYNC_

    HEADDATASYNC_

    HEAD

    . . .

     

    In the user program of the head PLC, up to eight function blocks

    DATASYNCH_HEAD are called in the OB1 (see also chapter 2.1.2).

  • 8/18/2019 39040038 Datasync Doku v21 En

    29/44

    5 Performance Measurement

    DatasyncV21, Entry ID: 39040038 29

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    Measuring scenarios

    For the performance measurement, several variants were measured that differ inthe following aspects:

      type of head PLC  number of substations

      data load

      program load.

    The following table shows the values:

    Table 5-1

    Parameters Settings

    Type of head PLC S7-1200 (CPU 1215), WinAC (IPC 227D)

    Number of substations 1, 4, 8, 16, 32

    Size of the area to be synchronized (in

    bytes)

    10, 100, 200, 1000

    Program load (in ms) 6, 50

    Measure cycle

    The measuring clock is started before the connection to the first substation is builtup. The end of a measure cycle is the point in time when all the substations havebeen synchronized once.

  • 8/18/2019 39040038 Datasync Doku v21 En

    30/44

    5 Performance Measurement

    30Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    5.2 Values of the performance measurement

    Data conditioning

    To avoid systematic errors, the measuring parameters are determined by repeatedmeasurement.

    100 subsequent measurements are determined and processed as representativemeasuring data. All the values and the maximum and the minimum synchronizationtime of a measure of a series of measurements are listed in the Annex (seechapter 11).

    Diagrams

    The following diagrams show the time for a synchronization cycle the S7-1200(gray line) needs as compared to the WinAC (blue line) for two measuringscenarios.

    Figure 5-2

    Figure 5-3

    Detailed values

    The detailed values of the performance measurement are listed in chapter 11 

    “ Appendix A: Measured Data”.

    Number of substations

    200 b te, 6 ms ro ram load

       T   i  m  e   i  n  m  s

    Number of substations

    1000 b te, 50 ms ro ram load

       T

       i  m  e   i  n  m  s

  • 8/18/2019 39040038 Datasync Doku v21 En

    31/44

    5 Performance Measurement

    DatasyncV21, Entry ID: 39040038 31

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    5.3 Result

    Overview

    These are the results of the individual measurements:  The WinAC always synchronizes the data fields quicker than the S7-1200.

      The higher the number of substations, the higher is the time differencebetween the synchronization for the S7-1200 and the Win AC.

      The synchronization time increases clearly when more than 8 substations arebeing used.

      The synchronization time increases with the number of substations and thevolume of the data to be synchronized.

    Analysis

    The measured values allow the following conclusions:

      The first two observations can be attributed to the increased performance ofthe current Intel atomic chip of the IPC as compared to the processor of theS7-1200 CPU.

      Up to a number of 8 substations there is a call of the FB “DATASYNC_HEAD”per substation in the OB1. Accordingly, the computing time increases, but thesynchronization time does not increase proportionally to the number ofsubstations, since the connection resources can be used in parallel.

    From a number of 8 substations or more, the maximum number of connectionresources of the two head PLC is used up, so that the parallel processing iscompleted by a serial processing. For more details about the behavior of the

    program, please refer to Figure 2-5.

  • 8/18/2019 39040038 Datasync Doku v21 En

    32/44

    6 Installation

    32Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    6 Installation

    6.1 Hardware installation

    The figure below shows the hardware setup of the application.

    Figure 6-1

    TP700 CPU 1215C IPC 277D

    192.168.0.45

    Possible Head PLCs

    192.168.0.55192.168.0.50

    192.168.0.1 192.168.0.2 192.168.0.3 192.168.0.4

    CPU 1214C CPU 1212C CPU 1212CCPU 1212C

    X208

    24V 24V24V

    24V24V24V24V

    24V

    PG

     

    Connect one head PLC (a CPU 1215C or an IPC277D), the field PLCs, theSCALANCE X208 and the panel to one 24V power supply each. Connect all thedevices with a SCALANCE X208 by means of a standard Ethernet cable.

    Note The installation guidelines for these components must always be observed.

  • 8/18/2019 39040038 Datasync Doku v21 En

    33/44

    6 Installation

    DatasyncV21, Entry ID: 39040038 33

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    6.2 Software installation

    Development software

    Install the TIA V12 on your configuration computer.

    Follow the instructions of the installation program.

    Application software

    For each head PLC, a sample program is available.

    Unpack the zipped code folder 39040038_DATASYNC_CODE_v20.zip  from thedownload area into a folder you chose.In this folder, there are the STEP 7 V12 project folders:

      DATASYNC_1200 for the S7-1200 CPU as the head PLC.

      DATASYNC_IPC for the IPC with WinAC as the head PLC

    Navigate to the project folder you need and open the TIA project Datasync.ap12 with a double click.

    Figure 6-2

  • 8/18/2019 39040038 Datasync Doku v21 En

    34/44

    7 Starting up the Application

    34Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    7 Starting up the Application

    7.1 Assigning the IP addresses

    The following IP addresses are used in this application:

    Table 7-1

    IP address Component

    192.168.0.45 Head PLC S7-1200

    192.168.0.55 Head PLC IPC

    192.168.0.50 HMI panel

    192.168.0.100 PG / PC

    192.168.0.1 Field PLC 1

    192.168.0.2 Field PLC 2

    192.168.0.3 Field PLC 3

    192.168.0.4 Field PLC 4

    The subnet mask is 255.255.255.0.

    PG / PC

    Change the IP addresses of the PG / PC as follows:

    Table 7-2

    No. Action Note

    1. For changing the networkaddress, open the Internet log(TCP/IP) settings with “Start >Control Panel > Network andInternet > Network Connections”

    Enter the IP address accordingto the figure.

    Then close all dialogs with OK.

  • 8/18/2019 39040038 Datasync Doku v21 En

    35/44

    7 Starting up the Application

    DatasyncV21, Entry ID: 39040038 35

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    SIMATIC components

    The SIMATIC components are addressed in the TIA portal by means of the onlinefunction “Assign IP address”.

    Table 7-3

    No. Action Note

    1. Open the portal view of the TIAportal project.

    2. First open the tree for the HEADPLC and then double-click onthe function Online &diagnostic. 

    Note:

    If you use the IPC as the headPLC, you use the functionOnline & diagnostic in thesection of the WinAC.

    3. In Functions, select Assign IP address.

    Click on the button Accessibledevices.

  • 8/18/2019 39040038 Datasync Doku v21 En

    36/44

    7 Starting up the Application

    36Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    No. Action Note

    4. If necessary, select the PG / PCinterface. The search foraccessible devices is carried out

    automatically.The result is shown in a list.

    Identify the PLC you use asHEAD via the MAC address andclick on Apply.

    5. Assign the IP address stored inthe project with the commandAssign IP address.

    The HEAD PLC now owns the IPaddress stored in the project.

    6. Change the IP addresses of thefield PLCs and of the panel in

    the same way.

  • 8/18/2019 39040038 Datasync Doku v21 En

    37/44

    7 Starting up the Application

    DatasyncV21, Entry ID: 39040038 37

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    7.2 Download the PLCs and the panels

    In the following, the SIMATIC components with the hardware configuration and the

    user program are downloaded.

    Note Please find a detailed instruction in the FAQ “How is a project downloaded in theCPU in STEP 7 (TIA portal) V11?” in the Entry ID: 59728694.

    Table 7-4

    No. Action Note

    1. At first, select the first field PLC.

    Then download the deviceconfiguration and the program tothe field PLC with the respectivesymbol in Online > Download toDevice.

    2. The project is compiled.

    Click the “Load” button.

    http://support.automation.siemens.com/WW/view/en/59728694http://support.automation.siemens.com/WW/view/en/59728694http://support.automation.siemens.com/WW/view/en/59728694http://support.automation.siemens.com/WW/view/en/59728694http://support.automation.siemens.com/WW/view/en/59728694

  • 8/18/2019 39040038 Datasync Doku v21 En

    38/44

    7 Starting up the Application

    38Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    No. Action Note

    3. Activate “Start all” to start theblock.Exit the download with “Finish”.

    4. Proceed in the same way for the3 other remaining field PLCs.

    Select the stations PLC_2 to

    PLC_4 and download therespective field PLC.

    5. Select the head PLC.

    Note:

    When you use the IPC as thehead PLC, select the WinAC.

    Then download the deviceconfiguration and the program tothe head PLC with the respectivesymbol in Online > Download toDevice.

    The next download procedure is

    carried out according to steps 2and 3.

  • 8/18/2019 39040038 Datasync Doku v21 En

    39/44

    7 Starting up the Application

    DatasyncV21, Entry ID: 39040038 39

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    No. Action Note

    6. For transferring the HMI project,select the HMI station in the TIAproject and download it to the

    panel with the respective symbolor Online > Download to Device.

    The next download procedure iscarried out according to step 2.

    Note:

     Any warning messagesconcerning the name of theobjects in the visualizationimages can be ignored.

  • 8/18/2019 39040038 Datasync Doku v21 En

    40/44

    8 Operating the Application

    40Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    8 Operating the ApplicationTo describe the principle of data synchronization clearly, several visualizationimages were created for the panel.

      HEAD PLC: This overview serves for entering the positions of the field PLCsand for activating the time synchronization.

      Field PLC 1…4: These images display the information transmitted by the fieldPLCs:

    –  weather data

    –  production data

    –  calculated position of the sun

    Note The data synchronization is started automatically.

    Table 8-1

    No. Action Note

    1. In the HMI screen HEAD PLC,enter the coordinates of everyfield PLC. With these data, thefield PLCs calculate the currentposition of the sun.

    2. With the button ActivateTimeSync, you initiate the timesynchronization with all the fieldPLCs.

  • 8/18/2019 39040038 Datasync Doku v21 En

    41/44

    8 Operating the Application

    DatasyncV21, Entry ID: 39040038 41

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    No. Action Note

    3. Change to the visualization ofthe field PLCs with thenavigation.

    Here, the information isdisplayed which the field PLCstransmit to the head PLC.

    4. With the HOME button youchange back to the HEAD PLCoverview screen at any time.

    5. With the switch-off symbol, youexit the runtime.

  • 8/18/2019 39040038 Datasync Doku v21 En

    42/44

    9 Related literature

    42Datasync

    V21, Entry ID: 39040038

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    9 Related literatureThis list is not complete and only represents a selection of relevant literature.

    BibliographyTable 9-1

    Subject Title

    /1/ STEP7

    SIMATIC S7-300/400

     Automating with STEP7 in STL and SCL

     Author: Hans Berger

    Publicis MCD Verlag

    ISBN: 978-3-89578-397-5

    /2/ STEP7

    SIMATIC S7-1200

     Automating with SIMATIC S7-1200

     Author: Hans Berger

    Publicis MCD Verlag

    ISBN: 978-3-89578-355-5

    Internet link specifications

    This list is not complete and only represents a selection of relevant information

    Table 9-2

    Subject Title

    /1/ Reference to thedocument

    http://support.automation.siemens.com/WW/view/en/39040038 

    /2/ Siemens IndustryOnline Support

    http://support.automation.siemens.com 

    /3/

    10 HistoryTable 10-1

    Version Date Modifications

    V1.0 10/2009 First version

    V2.0 05/2013 Complete review of code and document.

    http://support.automation.siemens.com/WW/view/en/39040038http://support.automation.siemens.com/WW/view/en/39040038http://support.automation.siemens.com/http://support.automation.siemens.com/http://support.automation.siemens.com/http://support.automation.siemens.com/WW/view/en/39040038

  • 8/18/2019 39040038 Datasync Doku v21 En

    43/44

    11 Appendix A: Measured Data

    DatasyncV21, Entry ID: 39040038 43

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    11 Appendix A: Measured Data

    11.1 Head: S7-1200; 6 ms program load

    11.2 Head: S7-1200; 50 ms program load

    Number of 

      substations

     Number of bytes 1 in ms  4 in ms  8 in ms 16 in ms  32 in ms 10 min 1637min 1486min 1739min 3313min 6944

    max 1834max 4710max 6899max 8053max 12347 average 1740 average 2781 average 3775 average 5131average 8490

    100 min 1867min 1740min 1724min 3494min 7202

    max 2009max 4793max 6601max 6799max 12598 average 1975average 2805average 3230 average 4977average 8854

    200 min 1657min 1611min 1661min 3417min 7157

    max 1857max 4757max 5743max 7205max 12065 average 1721 average 2777average 3158 average 4726average 9226

    1000 min 1672min 1484min 1558min 3468min 7000

    max 1952max 4645max 5010max 8668max 12709 average 1853 average 2698average 3149 average 5168average 8830

      Number of 

      substations

     Number of bytes 1 in ms  4 in ms  8 in ms 16 in ms  32 in ms 10 min 234min 443min 500min 987min 1912

    max 323max 3522max 3539max 3009max 5155

    average 280 average 741 average 1752 average 2047average 2334

    100 min 357min 376min 507min 1111min 1923

    max 459max 2673max 3570max 4002max 4413

    average 399 average 725 average 982 average 2100average 2417

    200 min 342min 411min 449min 956min 2134

    max 430max 3467max 3446max 4052max 6077

    average 392 average 823 average 939 average 1356average 3526

    1000 min 300min 387min 470min 1116min 2860

    max 393max 3484max 3066max 4004max 7819

    average 351 average 772 average 924 average 2115average 3395

  • 8/18/2019 39040038 Datasync Doku v21 En

    44/44

    11 Appendix A: Measured Data

       C  o  p  y  r   i  g   h   t         S

       i  e

      m  e  n  s   A   G

       2   0   1   3   A   l   l  r   i  g   h   t  s  r  e  s  e  r  v  e   d

    11.3 Head: WinAC; 6 ms program load

    11.4 Head: WinAC; 50 ms program load

    Number of 

      substations

     Number of bytes 1 in ms  4 in ms 8 in ms 16 in ms 32 in ms10 min 1694min 1550min 1538min 3124min 6223

    max 1750max 3260max 2982max 4377max 10534

    average 1704average 1812 average 1972 average 3353 average 7537

    100 min 1681min 1543min 1749min 3130min 6154

    max 1741max 2344max 2649max 4321max 10668average 1704average 2070 average 2286 average 3355 average 7416

    200 min 1681min 1532min 1538min 3128min 6256

    max 1740max 3077max 3082max 7341max 11114

    average 1703 average 2178 average 2428 average 4182 average 7502

    1000 min 1678min 1533min 1541min 3134min 6010

    max 1790max 3659max 4126max 6807max 10124

    average 1707average 2172 average 2566 average 4065 average 7700

      Number of 

      substations

     Number of bytes 1 in ms 4 in ms 8 in ms 16 in ms 32 in ms

    10 min 198 min 187 min 192 min 385 min 3108

    max 219 max 362 max 536 max 643 max 803

    average 209  average 257 average 304 average 479 average 1187

    100 min 203 min 187 min 192 min 457 min 785

    max 221 max 590 max 402 max 576 max 2617

    average 215 average 277 average 280 average 523 average 1189

    200 min 204 min 186 min 200 min 378 min 4441

    max 222 max 792 max 2188 max 1144 max 789

    average 213 average 287 average 463 average 667 average 1850

    1000 min 202 min 193 min 202 min 178 min 799

    max 221 max 795 max 1833 max 987 max 3062

    average 211 average 444 average 475 average 785 average 1834