Request/problem:
OPC UA Companion Specifications allow users to include defined information models to build their application over them. PLCopen companion specification was developed jointly by PLCopen and OPC Foundation with the aim to map IEC61131-3 into OPC UA Namespace. This allows the PLC manufacturers to utilize a common standard information model to represent various elements of their PLCs. The OPC UA SDKs available in the market generally do not provide the support for such companion specs out-of-the box. The client approached us to prepare extensions for the Matrikon Flex OPC UA SDK to support the PLCopen information model for his PLCs.
Solution:
The Matrikon Flex OPC UA SDK uses a set of helper C++ classes to support different types of objects which are generally derived using the Base OPC UA object classes.
To extend the support for PLCopen, a set of helper classes was developed for the new objects, types and variables which is introduced by the PLCopen companion specification along with the DI Specification which is used as the base for many of the objects in PLCopen. Also, additional helper classes to support creating structures and enums types were implemented. To simplify the use of arrays, an additional helper routine was created to encapsulate the initialization and configuration necessary.
A detailed example which shows how to instantiate new PLCopen resources and objects such as device resource, program, functional blocks etc was implemented as part of the sample application.
Architecture:
Results:
The helper classes and a demonstration application were shared to the customer which was used to integrate the classes as part of the PLC address space preparation application.