Third Party Libraries

C/C++ code existing in Kernel mode cannot be linked with or execute libraries from third parties that were developed for execution in User mode. There is therefore no possibility to use any DLL directly in TwinCAT C++ modules.

The connection of the TwinCAT 3 real-time environment can be realized via ADS communication instead. You can implement a User-mode application that makes use of the third-party library that provides TwinCAT functions via ADS.

Third Party Libraries 1:

This action of an ADS component in User mode can take place both as a client (i.e. the DLL transmits data to the TwinCAT real-time if necessary) and as a server (i.e. the TwinCAT real-time fetches data from the User mode if necessary).

Such an ADS component in User mode can also be used in the same way from the PLC. In addition, ADS can communicate beyond device limits.

The following samples illustrate the use of ADS in C++ modules:

Sample03: C++ as ADS server

Sample07: Receiving ADS Notifications

Sample08: provision of ADS-RPC