Skip to main content

Overview

The CODESYS Control Extension Package provides many different options and interfaces to connect your own programs to the Linux runtime system and the IEC application.

This allows you, for example, to control the PLC, respond to events from the PLC, or add your own functionality to the PLC or IEC application.

See below for an overview of the most important interfaces and functionalities. Note: "From outside the PLC" still means that you are on the Linux system. The interfaces are available on the Linux system only and not on another device, but still outside of the runtime process.

  • External Event Task: You can control the execution time for an IEC task yourself (from outside of the PLC).

  • Event Mechanism: You can react outside of the PLC to events of the IEC application (example: Start/Stop/Exception).

  • Access to the PLC Shell: You can access the PLC shell outside of the PLC.

  • START/STOP Switch: You can connect your own start/stop switch (outside of the PLC) with very easy ways.

  • Calling an External Function: You can very easily call your own functionality which is implemented outside of the PLC.

  • Linking Your Own I/Os: You can easily connect your own I/Os (example: local) outside of the PLC.

  • Extension SDK: You can very easily implement your own functions in C code, which can then be used from the IEC application.

  • Retain Data in Shared Memory: You can connect retain data from the application via SHM in the controller.

For an overview of the security measures taken, as well as security-relevant notices, see: Security Mechanisms.

These new mechanisms and interfaces are largely based on process separation which are based on Linux standard resources (files, sockets, or similar).

Among other things, "unix domain sockets" are used, and therefore a "remote terminal" can be implemented independent of technology (Python, C, an so on).

Connecting your own C code (Extension SDK) is an exception because C code compiled here in the form of a dynamic runtime system component (shared object) is directly added to the CODESYS runtime system and executed. For more information, see: Extension SDK.

The examples are located in the installation directory of the CODESYS Control Extension Package. By default, this is: C:\Program Files\CODESYS <version>\CODESYS\CODESYS Control SL Extension Package\<version>\Examples.