background image

Your Global Automation Partner

Getting Started

PROFINET  

Controller/Device

Commissioning in 

CODESYS 3

Summary of Contents for CODESYS 3

Page 1: ...Your Global Automation Partner Getting Started PROFINET Controller Device Commissioning in CODESYS 3...

Page 2: ......

Page 3: ...g PROFINET Devices Manually 17 3 3 4 Configuring the BL20 station 19 3 3 5 Configuring the TBEN S2 4IOL IO Link Master 20 Configuring the Empty Slots 2 5 IO Link Ports 21 Configuring the Empty Slots 6...

Page 4: ...Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 2...

Page 5: ...fies steps that the user has to perform RESULTS OF ACTION This symbol identifies relevant results of steps Compact controller TBEN L PLC HMI PLC TX500 series Programmable gateways BL20 PG EN V3 BL67 P...

Page 6: ...About these instructions Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 4...

Page 7: ...YS packages and device description files 2 1 Installing a CODESYS package If another CODESYS version is used first of all the package for the used Turck device has to be installed Download the CODESYS...

Page 8: ...9 208 4952 0 F 49 208 4952 264 more turck com www turck com 6 2 2 Create CODESYS Standard Project with TBEN L PLC Create a new standard project with TBEN L PLC as CODESYS device The CODESYS project is...

Page 9: ...n of the device s local I Os and the VAUX diagnostics Diagnostics of the local I Os and module status 2 serial interfaces COM0 and COM1 Connection of RS232 and RS485 devices 1 CAN interface CANbus Use...

Page 10: ...9 208 4952 264 more turck com www turck com 8 2 3 1 Configuring the Ethernet Interface Right clicking the entry Device TBEN Lx PLC 1x opens context menu Add the Ethernet interface via the Add device f...

Page 11: ...ing the Ethernet interface in the project tree The IP address of the network interface corresponds to the IP address of the TBEN L PLC Select eth0 under network interface The IP address is set automat...

Page 12: ...Creating a CODESYS Project and Configuring the Network Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 10...

Page 13: ...ck ultrasonic sensor RU40U M18E LiU2PN8X2T H1151 IO Link V1 1 IO Link port 4 generic port configuration used as digital input BL20 E GW EN with I O module 1 BL20 E 2CNT 2PWM I O module 2 BL20 2DO 24VD...

Page 14: ...ces with much more process data 50 400 byte as for example IO Link RFID or serial COM interfaces the cycle time has to be increased to 2 4 or 8 ms 3 2 1 Adding the PROFINET Controller to the Project T...

Page 15: ...vices are not time critical due to very weak real time requirements Therefore the task is low priority default priority 30 interval 10 ms In applica tions with a large amount of slaves it can be neces...

Page 16: ...m 14 3 3 Configuring PROFINET Devices In this example the following Turck multiprotocol devices are used as PROFINET devices TBEN S1 8DXP TBEN S2 4IOL BL20 E GW EN 3 3 1 Installing the GSDML files Dow...

Page 17: ...Start the device search via the Scan for devices function at the PROFINET controller The found devices can either be selected separately or all found devices can be added to the project via the Copy A...

Page 18: ...16 The devices are added to the project tree Modular Turck devices as the BL20 station in the example are added with all connected I O modules The configuration of the IO Link ports of the TBEN S2 4IO...

Page 19: ...FINET Devices Manually As an alternative for the scanning of the network PROFINET devices can also be add manually to PROFINET Add external PROFINET devices using the Add device function Fig 12 Adding...

Page 20: ...INET Controller Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 18 Select the PROFINET devices from the device catalog and add them to the project Fig 13 Adding ex...

Page 21: ...ar PROFINET devices first of all select the gateway in this example the BL20 E GW EN Right click the gateway and use the Add device function to add the I O modules in the order in which they follow th...

Page 22: ...DXP channels of the device DXP 2 4 6 and 8 2 5 IO Link ports For the configuration of the four IO Link ports Specific or generic configuration of the IO Link ports see Configuring the Empty Slots 2 5...

Page 23: ...put Use the Plug device function to select an IO Link device for the respective empty slot The configuration is either done via SIDI Simple IO Link Device Integration or as generic configu ration In t...

Page 24: ...9 208 4952 0 F 49 208 4952 264 more turck com www turck com 22 Select the entry of the temperature sensor TS 530 LI2UPN8X family under Port configuration generic and plug the device Select TS 530 LI2U...

Page 25: ...port 2 generically and select the entry IN 1 BYTE OUT 1 BYTE Select the entry of the ultrasonic sensor RU40U M18E LiU2PN8X2T H1151 under Port config uration specific and plug the device Fig 18 Generi...

Page 26: ...he Device as PROFINET Controller Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 24 Configure port 4 generically and select the entry DI Fig 19 IO Link Port Config...

Page 27: ...empty slots 6 to 8 allow the mapping of channel diagnostics IO Link Events and the modules status to the process image of the IO Link master Select the entry for the respective empty slot using the Pl...

Page 28: ...Using the Device as PROFINET Controller Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 26 Diagnostics Fig 21 TBEN S2 4IOL Diagnostics in the process image...

Page 29: ...27 2017 06 IO Link Events Fig 22 TBEN S2 4IOL IO Link Events in the process image...

Page 30: ...Using the Device as PROFINET Controller Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 28 Module status Fig 23 TBEN S2 4IOL Module status in the process image...

Page 31: ...d an IP address and if necessary adapt the parameters Send Clock Reduction Ratio2 and Phase to the application NOTE Assigning an IP address or a station name to the devices is not necessary if the dev...

Page 32: ...nsmission can be determined for the purpose of load distribution With the settings Send Clock 1 ms and Reduction Ratio 4 the PROFINET Cycle Time or Update Time is divided into four phases of 1 ms each...

Page 33: ...e device status can be requested in the program by entering the PROFINET device instance and the requested function Instance Status Example Request if the device is in cyclic data exchange tben_s2_4IO...

Page 34: ...the following function blocks IOL_CALL in accordance with IO Link specification single acyclic accesses IOL_WriteParamterList sending a parameter list for e g initial parameterization of IO Link devi...

Page 35: ...33 2017 06 Fig 29 Function block IOL_WriteParameterList...

Page 36: ...Using the Device as PROFINET Controller Hans Turck GmbH Co KG T 49 208 4952 0 F 49 208 4952 264 more turck com www turck com 34...

Page 37: ...TBEN L PLC 1 _V1 0 3 0 package TIA Portal V13 GSDML V2 3 TURCK CDS3_PN_Device 20151208 010322 xml 4 1 Creating a CODESYS Project and Configuring the Network Create CODESYS project and configure the ne...

Page 38: ...4952 0 F 49 208 4952 264 more turck com www turck com 36 4 2 Configuring the PROFINET Device 4 2 1 Adding the PROFINET Device to the Project The Turck PROFINET Device is used Add the Profinet_Device t...

Page 39: ...Device NOTE Please observe the following for the configuration of the I O data The CODESYS input data have to be have to be configured as output data in the PROFINET Controller configuration the CODE...

Page 40: ...ww turck com 38 Which data will be mapped into the configured input and output data depends on assignments in the PLC program or in the I O mapping of the TBEN L PLC Fig 32 PROFINET Device data mappin...

Page 41: ...The PROFINET CODESYS device is configured as standard PROFINET Device in TIA Portal Installing the GSDML file Install the device s GSDML file GSDML V2 3 TURCK CDS3_PN_Device xml in TIA Portal It can b...

Page 42: ...uring the PROFINET parameters Like for all other PROFINET Device the PROFINET interface has to be configured for the CDS3 PN Device in the project Set all necessary IP settings and assign a PROFINET D...

Page 43: ...e CODESYS device NOTE The configuration of the data in TIA Portal has to be done in reverse order compared to the configuration in CODESYS Input data in TIA Portal are output data in CODESYS and vice...

Page 44: ...208 4952 0 F 49 208 4952 264 more turck com www turck com 42 After configuring the PROFINET Device in TIA Portal and starting the PN controller the CODESYS application with the PROFINET Device is runn...

Page 45: ...100000538 2017 06 100000538 28 subsidiaries and over 60 representations worldwide www turck com...

Reviews: