ie_sr_s7_s5_iso

Upload: luisht79

Post on 06-Apr-2018

216 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/2/2019 ie_sr_s7_s5_iso

    1/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    1

    $ERXWWKLV'RFXPHQW

    This document contains information on the samples for Industrial Ethernetcommunication between an S7 and an SIMATIC S5 station using theLSEND/LRECEIVE service on the basis of the ISO protocol.

    )RUDEULHIRYHUYLHZRIWKLVVDPSOHUHIHUWR&KDSWHU

    )RUGHWDLOHGLQIRUPDWLRQUHIHUWR&KDSWHUDQGWKHFKDSWHUV

    IROORZLQJ

    The document covers the following topics:

    System structure

    Introduction to the required blocks and their communication structure

    Program structures and extracts of code

    Operator control and monitoring

    Troubleshooting

  • 8/2/2019 ie_sr_s7_s5_iso

    2/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    2

    2YHUYLHZRIWKH6DPSOH

    6FKHPDWLFRIWKH6\VWHP

    &KHFNLQJWKH)XQFWLRQDOLW\RIWKH6DPSOH

    The variable table of the active S7 station allows you to determine if the sample isfunctioning correctly. The variable table is contained in the Blocks folder of theSTEP 7 project.Data being sent and received has continuously changing values (see also"Operator Control and Monitoring").

    PG/PC with STEP 7 and STEP 5

    as

    MPI portPG interface on

    CPU and CP

    Active PartnerS7-400 Station

    Passive PartnerS5 Station

    Local Ethernet with

    hub, e.g., ELM

  • 8/2/2019 ie_sr_s7_s5_iso

    3/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    3

    )XQFWLRQ'LDJUDP

    The following diagram illustrates how the sample works:

    'DWD([FKDQJH

    400 bytes of data are exchanged cyclically by the stations involved in communication.

    $FWLYH3DVVLYH3DUWQHU

    The active partner initiates connection establishment and the sending of new data. Thepassive partner returns the received data to the active partner. Return means thatreceived data is sent back after it has been completely received.

    &RQQHFWLRQ7\SH

    The ISO protocol is used in this sample. This means that a connection of the type "ISOconnection" must be configured.

    3UHSDUHGDWD

    IRUVHQGLQJ

    6DYHUHFHLYHG

    GDWD

    Receive data and copy

    it to the send buffer

    Send data (400 bytes)

    Send data (400 bytes)

    Active SIMATIC S7-400 Station Passive SIMATIC S5 Station

  • 8/2/2019 ie_sr_s7_s5_iso

    4/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    4

    3URJUDP2YHUYLHZ

    'HVFULSWLRQRIWKHDFWLYHHQG

    An "AG_LSEND" FC is called every cycle tosend 400 bytes of data.

    Parallel to the send job an "AG_LRECV" FCis called to fetch data from the CP.The data is saved once it has beencompletely received.

    Once the RECEIVE job has been processedwithout error, the first word in the send dataarea is incremented by 1 and the receivecycle begins again.

    'HVFULSWLRQRIWKHSDVVLYHHQG A "RECEIVE" FB is triggered in every cycle.

    When the "RECEIVE" FB signals newlyreceived data, "SEND" FB is triggered withthe newly received data to send thereceived data back.

    The RECEIVE ALL and SEND functions runin the background to receive and return thedata.

    AG_LRECV

    AG_LSEND

    MY_RECEIVE_CALL

    MY_SEND_CALL

    FC40

    FC41

    FC50

    FC60

    Passive End (S5)Active End (S7)

    SEND

    FB40

    FB-RECEIVE

    FB121

    FB-SEND

    FB120

    FB41

    RECEIVE

    OB1OB1

    SEND/RECEIVE-ALL

  • 8/2/2019 ie_sr_s7_s5_iso

    5/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    5

    2SHUDWRU&RQWURODQG0RQLWRULQJ

    An operator control and monitoring function is available using the supplied variabletable.The following conditions must be met to allow you to use the "Monitoring and

    Modifying Variables" program:

    There must be an online connection to the CPU.

    "Monitor variables" must be activated.

    The values to be modified must be marked as valid.

    If the conditions listed above are met, you can determine whether the VDPSOHLVIXQFWLRQLQJFRUUHFWO\ by observing that the data sent and received from the activestation is FKDQJLQJFRQWLQXRXVO\.

  • 8/2/2019 ie_sr_s7_s5_iso

    6/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    6

    6\VWHP6WUXFWXUH

    This chapter lists the hardware and software required to run the sample.

    1RWH

    6FRSHRI$SSOLFDWLRQRIWKLV'RFXPHQWThe content of this document assumes a specific configuration (CP 443-1 at theactive end, CP 1430 TCP at the passive end).This documentation can, however, be used for all SEND/RECEIVE samples ofcommunication between a SIMATIC S7 and a SIMATIC S5 station.

    *HQHUDO6WUXFWXUH

    Bus system Industrial Ethernet

    Communications protocol ISO

    Active End SIMATIC S7

    Passive end SIMATIC S5

    Communications processors CP 443-1, CP 1430

    Services SEND / RECEIVE with long data

    The sample uses the ISO protocol. Using this protocol and the SEND / RECEIVEservices for long data there is data exchange between SIMATIC S7 and SIMATICS5 stations. A CP 443-1 for the ISO protocol is used as the communicationprocessor in the active SIMATIC S7-400. A CP 1430 is used at the passiveSIMATIC S5 end.

  • 8/2/2019 ie_sr_s7_s5_iso

    7/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    7

    +DUGZDUH5HTXLUHGIRUWKH$FWLYH(QG

    6ORW 0RGXOH1 PS407 10A

    3 CPU 414-1

    4 CP 443-1

    1RWH

    The CPs should be version 3.0 or later.

    You can check the version of the CP using NCM S7 INDUSTRIAL ETHERNETDiagnostics (6WDUW!6LPDWLF!1&06,QGXVWULDO(WKHUQHW!,QGXVWULDO(WKHUQHW'LDJQRVWLFV).If your CPs are earlier than version 3.0 it is possible to update their software(download a new version from Internet/Intranet and load it into the CP with theNCM S7 Industrial Ethernet firmware loader).

    1RWH

    8VLQJDGLIIHUHQW&38If you want to use a different CPU for the sample, please read the document

    "Change_CPU".

    1RWH

    8VLQJDGLIIHUHQW&3If you want to use a different CP for the sample, please read the document"Change_CP".

  • 8/2/2019 ie_sr_s7_s5_iso

    8/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    8

    +DUGZDUH5HTXLUHGIRUWKH3DVVLYH(QG

    6ORW 0RGXOH1 CPU 135 U

    2 CP 1430 TF

    ! &DXWLRQThe samples relate to specific hardware configurations. These must exist toensure problem-free operation.If you want to use a different configuration, you must make modifications (refer tothe notes below).

    &DEOHVDQG2WKHU+DUGZDUH5HTXLUHG

    MPI cable

    Ethernet cable: Type depending on the medium used, for example, AUI or ITP

    Hub or fan-out unit, for example, ELM, SSV 104

    PG or PC with MPI port

    5HTXLUHG6RIWZDUH

    You require the following software to run the sample:

    Microsoft Windows 95 or Windows NT 4.0 as the operating system

    STEP 7 V4.021 or later (See also "1RWH")

    NCM S7 INDUSTRIAL ETHERNET for STEP 7 V4.021

    STEP 5 V6.65 or later

    SINEC NCM COM for CP 1430, Version V5.01 or later

  • 8/2/2019 ie_sr_s7_s5_iso

    9/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    9

    ,QWURGXFWLRQWRWKH5HTXLUHG%ORFNVDQGWKHLU&RPPXQLFDWLRQ6WUXFWXUH

    This chapter covers the following topics:

    How the sample works

    Blocks required for communication and their communication structure

  • 8/2/2019 ie_sr_s7_s5_iso

    10/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    10

    +RZWKH6DPSOH:RUNV

    'DWD([FKDQJH2 bytes of data are exchanged cyclically by the stations involved in communication.

    $FWLYH3DVVLYH(QG

    The active SIMATIC S7 end initiates the SEND / RECEIVE function. The passiveSIMATIC S5 end receives the data and sends it back to the active end.Industrial Ethernet with the ISO protocol is used as the network medium.

    6WHSE\6WHS([HFXWLRQRIWKH8VHU3URJUDPDWWKH$FWLYH(QG

    SEND:A data block of 2 bytes is sent to the passive partner in every cycle.

    RECEIVE:A receive job is triggered in every cycle and, depending on the return value, thereceived data is written to the receive buffer.

    Incrementing data:The value of the data to be sent is incremented by 1 and the send/receive cyclestarts again.

    6WHSE\6WHS([HFXWLRQRIWKH8VHU3URJUDPDWWKH3DVVLYH(QG6,0$7,&6

    SEND:A send job is triggered when new data is received.

    RECEIVE:A receive job is triggered at the passive end every cycle. When new data isreceived, it is entered in the common receive/send buffer.

  • 8/2/2019 ie_sr_s7_s5_iso

    11/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    11

    %ORFNV5HTXLUHGIRU&RPPXQLFDWLRQDQGWKHLU&RPPXQLFDWLRQ6WUXFWXUH

    This chapter provides a detailed description of the AG_LSEND and AG_LRECVblocks required for SEND / RECEIVE communication.

  • 8/2/2019 ie_sr_s7_s5_iso

    12/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    12

    6)XQFWLRQ$*B/6(1')&

    3XUSRVHRIWKH%ORFN

    The AG_LSEND function (FC) transfers data from the specified send buffer of the PLCto the configured partner station. The send buffer pointer can point to a process imagearea, a bit memory area, or a data block area. The length of the data field to be sentmust not exceed a maximum of 8 Kbytes.

    The addresses and TSAPs of the partners are specified during configuration and areassigned a connection ID with which the AG_LSEND function sends the data.

    7KHEORFNSDUDPHWHUVDUHGHVFULEHGLQGHWDLOLQ&KDSWHU

    6)XQFWLRQ6(1')%

    3XUSRVHRIWKH%ORFN

    The function block sends the PLC data from the specified send buffer to the specifiedaddress area of the CP.The addresses and TSAPs of the partners are set in the CP configuration.

    7KHEORFNSDUDPHWHUVDUHGHVFULEHGLQGHWDLOLQ&KDSWHU

  • 8/2/2019 ie_sr_s7_s5_iso

    13/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    13

    6)XQFWLRQ$*B/5(&9)&

    3XUSRVHRIWKH%ORFN

    The AG_LRECV function (FC) transfers data received from the partner station in thespecified receive buffer of the PLC. The receive buffer can reference a process imagearea, a bit memory area, or data block area. The receive buffer must be at least aslong as the longest data field that can be expected.

    The addresses and TSAPs of the partners are specified during configuration and areassigned a connection ID with which the AG_LRECV function receives the data.

    7KHEORFNSDUDPHWHUVDUHGHVFULEHGLQGHWDLOLQ&KDSWHU

    6)XQFWLRQ5(&(,9()%

    3XUSRVHRIWKH%ORFN

    The function block transfers the CP data from the specified address area to thespecified send buffer of the PLC. The receive buffer can reference a process image

    area, a bit memory area, or data block area. The receive buffer must be at least aslong as the longest data field that can be expected.

    The addresses and TSAPs of the partners are set in the CP configuration.

    7KHEORFNSDUDPHWHUVDUHGHVFULEHGLQGHWDLOLQ&KDSWHU

  • 8/2/2019 ie_sr_s7_s5_iso

    14/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    14

    3URJUDP6WUXFWXUHVDQG([WUDFWVRI&RGH

    This chapter introduces you to the structure of the program for both the active andpassive ends and important sections of code are shown and explained.

  • 8/2/2019 ie_sr_s7_s5_iso

    15/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    15

    3URJUDP6WUXFWXUHRIWKH$FWLYH3DUWQHU

    No

    Program/cycle start

    CallAG_LSEND

    Error occurredwith

    AG_LSEND?

    Save errornumber

    Yes

    Yes

    No

    CallAG_LRECV

    Error occurredwith

    AG_LRECV?

    AG_LRECV jobcomplete?

    Save errornumber

    Increment senddata

    Yes

    No

  • 8/2/2019 ie_sr_s7_s5_iso

    16/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    16

    ([WUDFWVRI&RGHIRUWKH$FWLYH3DUWQHU

    $FWLYH(QG6\PEROV

    6\PERO7DEOH8VHGIRUWKH6HQG5HFHLYH6DPSOHV

    8VHV

    The use of symbols makes the code easier to read. The symbolic name thenappears in the program instead of the address.

    Example: Instead of "MW50" you see "RECEIVE_DATA" in the code.

  • 8/2/2019 ie_sr_s7_s5_iso

    17/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    17

    $FWLYH(QG2%

    3XUSRVH

    OB1 is responsible for cyclic execution of the user program.In this sample program, the blocks that implement the send / receive functionality(AG_LSEND and AG_LRECV) are called.

    &DOO

    OB1 is called in every CPU cycle.

    1DPH

    OB1

    &RGH

    'HVFULSWLRQ

    OB1 calls the blocks named "MY_SEND_CALL" (call FC AG_LSEND) andMY_RECEIVE_CALL" (call AG_LRECV) in every cycle.

  • 8/2/2019 ie_sr_s7_s5_iso

    18/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    18

    $FWLYH(QG$*B/6(1'-RE

    3XUSRVH

    400 bytes of data are sent to the configured partner using the Send / Receiveservice $*B/6(1'.

    &DOO

    Called within OB1.

    1DPH

    MY_SEND_CALL (FC40)

    &RGH

  • 8/2/2019 ie_sr_s7_s5_iso

    19/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    19

    0HDQLQJRIWKH3DUDPHWHUVIRUWKH65VHUYLFH$*B/6(1'

    ACT:Edge signal for executing the block.

    ID:This identifier identifies the S/R connection (obtained with "CPU -> Connections").

    LADDR:This parameter provides the address of the local CP (assigned in "HW Config" and canalso be read out using "Netpro")

    SEND:Address of a local data area from which the values are transferred.

    LEN:Length of the data area to be sent.

    DONE:Indicates error-free execution of the job.

    ERROR:Indicates whether or not an error has occurred.

    STATUS:Provides detailed information about states or errors during execution of the job.

    'HVFULSWLRQ

    &$//$*B/6(1'

    The S/R service "send data" is called. Depending on the "SEND_ERROR" bit, thestatus word is saved or the function is exited using a conditional block end (BEC).

    6XPPDU\

    The send block is triggered in every cycle to send data from the send buffer(DB40). When an error occurs during sending, the returned status value is saved ina data block (DB43).

  • 8/2/2019 ie_sr_s7_s5_iso

    20/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    20

    $FWLYH(QG$*B/5(&9-RE

    3XUSRVH

    400 bytes of data are sent by the configured partner using the Send / Receiveservice $*B/5(&9.

    &DOO

    Called within OB1.

    1DPH

    MY_RECEIVE_CALL (FC41)

    &RGH

  • 8/2/2019 ie_sr_s7_s5_iso

    21/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    21

    0HDQLQJRIWKH3DUDPHWHUVIRUWKH656HUYLFH$*B/5(&9

    ID:This identifier identifies the S/R connection (obtained with "CPU -> Connections").

    LADDR:This parameter provides the address of the local CP (assigned in "HW Config" and canalso be read out using "Netpro")

    RECV:Address of a local data area from which the values are transferred.

    NDR:Indicates error-free execution of the job.

    ERROR:Indicates whether or not an error has occurred.

    STATUS:Provides detailed information about states or errors during execution of the job.

    LEN:Length of the data area to be sent.

    'HVFULSWLRQ

    &$//$*B/5(&9

    The S/R service "receive data" is called. Depending on the "RECV_ERROR" bit,the status value is saved. Otherwise the received data length is accepted and ifreceived correctly the data word is incremented.

    6XPPDU\

    The receive block is triggered in every cycle to receive data and write it to thereceive buffer (DB41). If an error occurs during sending, the returned status valueis saved to a data block (DB43). If no error occurs in reception the data isincremented.

  • 8/2/2019 ie_sr_s7_s5_iso

    22/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    22

    3URJUDP6WUXFWXUHIRUWKH3DVVLYH3DUWQHU

    Yes

    Yes

    No

    Program/cycle start

    Call RECEIVE

    Error occurred

    with RECEIVE?

    Save errornumber

    Call SENDwith send bit

    Receivecomplete

    Save errornumber

    Reset send bit

    No

    Yes

    No

    Error occurredwith SEND?

    Call SEND/RECEIVE-ALL

  • 8/2/2019 ie_sr_s7_s5_iso

    23/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    23

    ([WUDFWVRI&RGHIRUWKH6,0$7,&63DVVLYH3DUWQHU

    3DVVLYH(QG2%

    3XUSRVH

    OB1 is responsible for cyclic execution of the user program.The following sample program calls the blocks (SEND/RECEIVE) for executing thesend / receive functions.

    &DOO

    OB1 is called in every CPU cycle.

    1DPH

    OB1

    &RGH

    OB1

    Segment 1

    : example for send/receive with

    : data length 400 byte (ISO)

    :

    :

    :JU FB 231 all functions for cp 1430

    Name :ALL-SS 0

    :

    :JU FB 41 call receive function

    Name :RECISO

    :

    :BE

  • 8/2/2019 ie_sr_s7_s5_iso

    24/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    24

    3DVVLYH(QG6(1'-RE

    3XUSRVH

    400 bytes of data are sent to the configured partner using the 6(1' FB (and

    SEND-ALL) .

    &DOO

    Called within OB1.

    &RGH

    FB 40

    Segment 1Name :SEND>ISO send to remote station (200 words)

    ::A F 45.7 "call-send-bit":JC FB 120

    Name :SENDSSNR : KY 0,0A-NR : KY 0,2 order number (ncm1430)ANZW : FW 56QTYP : KS DB send buffer type is dbDBNR : KY 0,40 send buffer is db40QANF : KF +1 send buffer offset is dw1QLAE : KF +200 send length (200 word/400 byte)PAFE : FY 54

    :

    :A F 57.5 anzw "data transfer completed":AN F 55.0:= F 55.1 edge flag "data transfer: completed":A F 57.5:= F 55.0::A F 55.1 edge flag "data transfer: completed":AN F 54.0 no pafe by send:R F 45.7 reset "call-send-bit"::BE

  • 8/2/2019 ie_sr_s7_s5_iso

    25/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    25

    0HDQLQJRIWKH3DUDPHWHUVIRUWKH6(1')%)%

    SSNR:Interface number of CP 1430.

    A-NR:The job number identifies the S/R connection of the CP 1430.

    ANZW:Conditional code word (status) of the job.

    QTYP:Type of buffer area.

    DBNR:The DB number for data blocks.

    QANF:Offset within the buffer area.

    QLAE:Length of the area to be sent.

    PAFE:Error display of the block.

  • 8/2/2019 ie_sr_s7_s5_iso

    26/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    26

    3DVVLYH(QG5(&(,9(-RE

    3XUSRVH

    400 bytes of data received from the specified partner are sent to the CPU using the5(&(,9( FB (and RECEIVE-ALL).

    &DOO

    Called within OB1.

    &RGH

    FB 41

    Segment 1Name :REC

  • 8/2/2019 ie_sr_s7_s5_iso

    27/37

  • 8/2/2019 ie_sr_s7_s5_iso

    28/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    28

    2SHUDWRU&RQWURODQG0RQLWRULQJ

    This chapter covers the following topics: Operator control and monitoring

  • 8/2/2019 ie_sr_s7_s5_iso

    29/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    29

    2SHUDWRU&RQWURODQG0RQLWRULQJ

    1RWHIf problems occur during operator control and monitoring, please read Chapter 7Troubleshooting, Variable Table.

    0RQLWRULQJ

    You can monitor the functions using the variable table provided with the sample.The following table explains how to use the table.

    6WHS 'HVFULSWLRQ

    1 Insert this end of the MPI cable in the MPI port of the S7 CPU in the activestation

    2 Select "Blocks" in the project window of the SIMATIC Manager under the activestation.

    3 Double-click "VAT1".

    4 In the program "Monitoring and Modifying Variables", select 3/&!&RQQHFW7R!&RQILJXUHG&38

    5 To monitor the specified variable, select "9DULDEOH!0RQLWRU

    1RWHThe monitor function is active when "Online" is displayed in the status bar in the"Monitoring and Modifying Variables" program and you can see a continuouslychanging progress bar.

  • 8/2/2019 ie_sr_s7_s5_iso

    30/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    30

    After you have completed the steps above, you will see the following variable table(the values may be different!):

    6(1'3DUDPHWHU

    In the upper part, "SEND", you can see the parameters of the AG_SEND

    Send/Receive service.,IWKHVDPSOHLVZRUNLQJFRUUHFWO\

    $PRQJVWRWKHUWKLQJVWKHSDUDPHWHU6(1'B'21($*B/6(1'MRE

    FRPSOHWHVKRXOGVKRZDFRQWLQXRXVO\FKDQJLQJVWDWXVRI!

    5(&(,9(3DUDPHWHU

    In the lower part, "RECEIVE", you should observe the same for the Send/Receiveservice, AG_LRECV.,IWKHVDPSOHLVZRUNLQJFRUUHFWO\

    $PRQJVWRWKHUWKLQJVWKHSDUDPHWHU5(&9B1'5UHFHLYHGDWDVKRXOG

    VKRZDFRQWLQXRXVO\FKDQJLQJVWDWXVRI!

    If the error output is set, you will see the status messages of the blocks in "last errorin program".

    ,IWKHVDPSOHLVZRUNLQJFRUUHFWO\

    'XHWRWKHXSGDWHF\FOHRIWKHYDULDEOHWDEOHWKHZULWWHQDQGUHDGGDWDVKRXOG

    EHGLIIHUHQW

    ,IWKHVDPSOHLVIXQFWLRQLQJFRUUHFWO\WKHGDWDVKRXOGEHFRQWLQXRXVO\

    FKDQJLQJ

  • 8/2/2019 ie_sr_s7_s5_iso

    31/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    31

    1RWHThe meaning of the values of the parameters for AG_LSEND and AG_LRECV isexplained in detail in the relevant documentation and in the NCM online help (forexample, 6WDUW!6LPDWLF!1&06,1'8675,$/(7+(51(7!+HOS

    )XQFWLRQV)&!(QJOLVK.

    1RWHThe sample is functioning correctly when the value of the data read and writtenchanges continuously.

    ! Dont forget!The variable table must be online and monitoring must be active before the valueswill be updated.

    2SHUDWRU&RQWURO

    You can call the functions using the variable table provided with the sample. How tostart and activate it was described above.

    1RWHTo call up the functions, the variable table must be "Online" and "Monitor" must be

    active so that the values can be updated (see above).

    The following table shows you how to change the value of the data sent to (andthen read by) the passive end.

    6WHS 'HVFULSWLRQ

    1 Enter a value between 0 and 32767 in the last column ("Modify Value") of theline "MW 52" "SEND_DATA" in the variable table.

    2 Select "Variable" -> "Activate Modify Value"

    &RUUHFWIXQFWLRQ

    If the value has been successfully modified, then value read should also return anew value.

  • 8/2/2019 ie_sr_s7_s5_iso

    32/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    32

    ([LWLQJ2SHUDWRU&RQWURODQG0RQLWRULQJ

    6WHS 'HVFULSWLRQ

    1 Select 7DEOH!([LW in the "Monitoring and Modifying Variables" program.

    2 Click the "No" button in the subsequent dialog.

  • 8/2/2019 ie_sr_s7_s5_iso

    33/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    33

    7URXEOHVKRRWLQJ

    This chapter is intended to help you if you encounter problems installing andstarting up the sample.

    3UREOHPV'RZQORDGLQJWKH+DUGZDUH&RQILJXUDWLRQWKH&RQQHFWLRQRUWKH

    %ORFNV

    Run the following checks.If your answer is "NO" to a question, go straight to the corresponding steps in"Remedies".

    6WHS 'HVFULSWLRQ

    1 Is the MPI cable connected to both the PG/PC and the S7 CPU?

    2 In the "Setting the PG/PC Interface" program is the correct interface parameterset assigned to the "Access point of application" "S7ONLINE (STEP 7)"? Forexample, "MPI-ISA on board (MPI)" if you are using the PG-MPI port?

    3 Is the hardware configuration in the project (offline configuration) identical inevery way with the actual configuration (online configuration)?

    4 Has the CPU been reset?

    5HPHGLHV

    Correct the problem by working through the steps below if your answer was no toone of the questions above.

    $QVZHUWR6WHSZDV12

    No connection can be established to the S7 CPU, it is not possible to download tothe CPU.

    6WHS 'HVFULSWLRQ

    1 Insert one end of the MPI cable in the MPI port on your PG or PC.

    2 Insert the other end of the MPI cable in the MPI port of your S7 CPU.

  • 8/2/2019 ie_sr_s7_s5_iso

    34/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    34

    $QVZHUWR6WHSZDV12

    No connection can be established to the S7 CPU, it is not possible to download tothe CPU.

    6WHS 'HVFULSWLRQ

    1 Start the "Setting the PG/PC Interface" program: "Start" -> "Simatic" -> "STEP7" -> "Setting the PG/PC Interface".

    2 Set the module you want to use as the MPI port in "Interface parameterassignment used".For example, "MPI-ISA on board (MPI)" if you are using the PG-MPI port.

    3 Click the "OK" button.

  • 8/2/2019 ie_sr_s7_s5_iso

    35/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with S5 CP 1430 SEND/RECEIVE

    35

    9DULDEOH7DEOH:ULWWHQDQGUHDGGDWDGRQRWFKDQJH

    Run the following checks.If your answer is "NO" to a question, go straight to the corresponding steps in"Remedies".

    6WHS 'HVFULSWLRQ

    1 Is the Ethernet cable connected to both the active and passive stations?

    2 When using Industrial Twisted Pair:Is a plug-in transceiver connected to the CP 1413 station?

    3 Can you see "Online" in the status bar of the variable table?

    4 Can you see a continuously changing progress bar in the status bar?

    5HPHGLHV

    Correct the problem by working through the steps below if your answer was no toone of the questions above.

    7KHDQVZHUWRVWHSZDV12

    No connection can be established between the stations and data exchange is notpossible.

    6WHS 'HVFULSWLRQ

    1 Connect one end of the Ethernet cable to the Ethernet port of the CP in theactive station.

    2 Connect the other end to your hub or fan-out unit (SSV).

    3 Repeat steps 1 and 2 for the passive station.

  • 8/2/2019 ie_sr_s7_s5_iso

    36/37

    6,0$7,&1(74XLFN6WDUW

    Industrial Ethernet Communication: S7 CP 443-1 ISO with CP 1430 SEND/RECEIVE

    36

    7KHDQVZHUWRVWHSZDV12

    No connection can be established between the two stations; without a plug-intransceiver it is not possible to establish a connection using Industrial Twisted Pair.

    6WHS 'HVFULSWLRQ

    1 Install a plug-in transceiver between the twisted pair cable and the AUI port ofthe S5 CP 143.

  • 8/2/2019 ie_sr_s7_s5_iso

    37/37

    6,0$7,&1(74XLFN6WDUW

    9DULDEOH7DEOH2SHUDWRUFRQWUROLVQRWZRUNLQJ

    Run the following checks.If your answer is "NO" to a question, go straight to the corresponding steps in"Remedies".

    6WHS 'HVFULSWLRQ

    1 Have you activated 9DULDEOH!0RGLI\9DOXH9DOLG in the "Monitoring andModifying Variables" program?

    2 Is the value you entered for memory word 52 (MW52) between 0 and 32767?

    5HPHGLHVCorrect the problem by working through the steps below if your answer was no toone of the questions above.