Teaser_r3.png

IO-Link - ctrlX CORE with S20 IO-Link Master

EngJay
Established Member


Introduction

This article shows how to setup the communication configuration between the EtherCAT master of the ctrlX CORE and an S20 EtherCAT bus coupler with S20-IOL-8 IO-Link Master using the EtherCAT App and the PLC App with S20 configuration libraries so you can read IO-Link sensors on the Data Layer.

Prerequisites
Video Demonstration

 

EtherCAT Master IO Configuration

In ctrlX IO Engineering, scan for devices and apply them to the IO project. Then under the S20 EtherCAT bus coupler, manually add the S20-IOL-8 module. Make sure all devices on the EtherCAT bus coupler are in the correct order.

Add_S20-IOL-8_to_Topology.png

Then download the configuration to the ctrlX CORE. If the 'D' status indicator LED on the S20-IOL-8 module is not active at this point, cycle the EtherCAT master.

PLC Configuration

In the PLC engineering software, add the EtherCAT master info to the Data Layer.

Add_EtherCAT_Master_to_DataLayer.png

Enable the S20-IOL-8 in the Data Layer.

Enable_S20-IOL-8.png

Add the CXA_S20 library, then add the example code for IH_S20IOL8SetPortConfig and IH_S20IOL8GetLivePortList, in the IOL8 folder, to a POU in your program.  You only need one instance of IH_S20ComConfiguration.

S20-IOL-8_Configuration_Code.png

Remember to add the configuration POU to the Main_task.

Add_Config_POU_to_MainTask.png

After building the code, Login to the ctrlX CORE and download the code.  Execute IH_S20IOL8SetPortConfig to activate the IO Ports on the S20-IOL-8 IO-Link Master. Then execute IH_S20IOL8GetLivePortList.  The array assigned to IH_S20IOL8GetLivePortList will now contain the configuration data for all IO-Link sensors connected to the S20-IOL-8 IO-Link Master. 

GetLivePortList_Actual_Configuration.png

Use the data acquired from the array tied to IH_S20IOL8GetLivePortList to populate the array tied to IH_S20IOL8SetPortConfig. Then execute IH_S20IOL8SetPortConfig again to load the correct port configuration data. In the array tied to IH_S20IOL8SetPortConfig, any unused ports should be disabled to avoid an error signal on the S20-IOL-8 module. 

Download Program
1 Comment
Must Read
Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist