11/07/2024

PROFINET - Connect ctrlX CORE X3 with IndraDrive

Overview

In this tutorial, it will be shown how to connect an IndraDrive Cs device to a ctrlX CORE X3. The ctrlX CORE X3 will be the Profinet controller (PN-Controller), and the IndraDrive will be the Profinet device. The IndraDrive device will be connected to the Ethernet port (XF51) of the ctrlX CORE, and the CoDSys fieldbus library will be used to configure the connection.

Prerequisites

Configuration

Note: Before starting with the configuration it is required to install the CoDeSys Fieldbus libraries. Please follow the steps shown here: Manual - CODESYS Fieldbus communication packages for ctrlX CORE. In the case the user has access to the collaboration room, download the packages from this link.

1. From the ctrlX CORE side it first requires to configure the Network configuration in the “Settings” side:

  1. Go to “Settings” 
  2. "Connectivity"
  3. Select the "eth1" connection 
  4. Go to the "IPv4" menu
  5. Choose an IP address (It is recommended to choose a different one to eth0) Something of the type 192.168.0.X 
  6. Save configuration

2. IndraDrive configuration file import

NOTE: It is required to have the .xml file of the IndraDrive device.

  • Open the PLC program. In the Menu, select “Tools” -> "Device Repository" -> "Install" -> Select the .xml file with the PN-Device information.

  • Once successfully imported, the imported device should be visible:

3. Add ethernet device:

  1. Right click over "Device" -> Select “Add device” 
  2. Select “Ethernet”
  3. Press “Add Device”

4. Add PN-Controller device. As in this case, the ctrlX CORE will be the PN-Controller, it is required to select this type of device in the configuration.

  1. Right click over "Ethernet" -> "Add device"
  2. Select "PN-Controller over Profinet IO Master" 
  3. Press "Add device"

5. Once the PN-Controller is imported, in the Device tree, new trees with the task’s priorities will be added

  • Now it is required to change the priorities:

Double click over "Profinet_communicationTask" -> Include a priority of 37 as a recommendation

For the Profinet_IOTask the same steps are followed:

Double click over "Profinet_IOTask" -> Write a priority of 30 as a recommendation

6. Scan the IndraDrive device:

  1. Right click over "PN_Controller" -> Select "Scan for devices"
  2. Check the found devices
  3. Copy All devices to project -> Close the window

Troubleshooting: If error messages appear during scanning, it is recommended to add the device manually:

  1. Instead of clicking over "Scan for devices", click over "PN_Controller" -> "Add device"
  2. Look for the previously added "IndraDrive" description and add it to the project tree by pressing "Add device"
  3. Perform step 10 of this tutorial and log out again
  4. Scan again with right click over "PN_Controller" -> "Scan for devices" and copy the device to the project
  5. The manually added device can be deleted and you can keep the new one
  6. Continue with the Tutorial

7. Configure ethernet IP Address:

  1. Right click over "Ethernet"
  2. "Browse"
  3. Select eth1 connection as it was the one previously configured in the ctrlX CORE web interface
  4. Press “Ok”

8. Configure PN-Controller:

  1. Double click over "PN_Controller"
  2. Give a station name
  3. Configure the PN-Device IP Address. The IP Address is required to be 192.168.0.X as this was the defined type of network

9. Configure the input or output to be able to read the values:

  1. Double click over the input we want to read
  2. Select the "PNIO Module I/O Mapping" tab
  3. Expand the variable
  4. Select "Enabled 2"

10. Test the configuration: "Generate code" or press "F11" -> Login in the ctrlX CORE to transfer the PLC program -> Run the program

  • Read the received values

NOTE: If the symbols are orange, it means that it does not have license.



Related Links

1

Latest published/updated articles

Types
How-to
Categories
Drives