OPC UA Server Interface Plugin

The OPC UA Server Interface Plugin allows you to connect to Codabix via the standardized OPC UA interface.
The interface allows to you to create OPC UA Servers using the opc.tcp protocol and expose Codabix Nodes to OPC UA Clients.
  • Browse CoDaBix® Nodes
  • (Synchronously) read and write values to Nodes
  • Create subscriptions to Nodes
  • Access historic values of CoDaBix® Nodes using HDA (Historical Data Access)
  • Remotely access files on the CoDaBix® host machine with the OPC UA filetype
  • Supports the SignAndEncrypt policy for encrypted transport
  • opc.tcp (binary message encoding)
  • http (binary and XML message encoding - in a future version)
  • Connect S7 Variables or other Nodes using OPC UA

This plugin is part of the CoDaBix® Setup. Please consult CoDaBix® Setup and First Start for more information on how to install and uninstall this plugin.

This plugin is part of the CoDaBix® Setup. Please consult CoDaBix® Setup and First Start for more information on how to install and uninstall this plugin.

The OPC UA Server Interface Plugin can be configured only in the Interface Node in CoDaBix® (/System/Interfaces/OPC UA Server Interface/Channels/Default Channel/Settings):

Configuration

Nodes:

Name Type Purpose
Application
ApplicationCertificate Blob Contains the application instance certificate of the OPC UA Server in PKCS12 (.pfx) format.
Port Int32 Specifies the TCP Port for the opc.tcp protocol.
Security
AutoAcceptUntrustedCertificates Boolean Specifies if the OPC UA Server should automatically accept unknown Client application certificates when using the Sign or SignAndEncrypt mode.
PolicyAlgorithm String Valid values:
0: None (default)
1: Basic128Rsa15
PolicyLevel Int32
PolicyMode String Valid values:
0: None (default)
1: Sign
2: SignAndEncrypt

To change the settings, you can write a new Node value in the CoDaBix® Web Configuration by using the “Write a new value” button (Write a New Value Button).

To connect to the OPC UA Server, use the following URL (replace <Hostanme> with your machine's hostname or IP Address (or “localhost” if connecting from the same machine), and replace <Port> with your port number):

opc.tcp://<Hostname>:<Port>/

User Configuration

The OPC UA Server Interface Plugin requires that OPC UA Clients use the username authentication, which means you need to specify a username and password. The OPC UA Server uses the users configured in CoDaBix® (see CoDaBix® Web Configuration). Each user which is configured in CoDaBix® can connect to the OPC UA Server using the corresponsing username and password.

The OPC UA Server Interface Plugin requires that OPC UA Clients use the username authentication, which means you need to specify a username and password. The OPC UA Server uses the users configured in CoDaBix® (see CoDaBix® Web Configuration). Each user which is configured in CoDaBix® can connect to the OPC UA Server using the corresponsing username and password.

By default, CoDaBix® comes with a demo user (username “demo@user.org”, password “demo”) which is added to the “Demo Group” usergroup.

By default, a user cannot access any CoDaBix® Node. To change this, you need to add the user to a UserGroup, then allow access from this UserGroup to a Node. For further information, see CoDaBix® Web Configuration.

By default, a user cannot access any CoDaBix® Node. To change this, you need to add the user to a UserGroup, then allow access from this UserGroup to a Node. For further information, see CoDaBix® Web Configuration.

For example, to allow the demo user (demo@user.org) to access the “System” Node:

  1. Open the CoDaBix® Web Configuration
  2. Go to Nodes
  3. Select the “System” Node
  4. Click the “UserGroups” icon (UserGroups Icon)
  5. Select the “Demo Group” in the “Edit UserGroups” dialog

Select Demo Group

Accessing the OPC UA Server

After configuring the users, you can then access the OPA UA Server using the following configuration:

After configuring the users, you can then access the OPA UA Server e.g. with our tool OPC Watch using the following configuration:

  • ServerAddress: opc.tcp://localhost:4840/
  • UserIdentity / Username: demo@user.org
  • UserIdentity / Password: demo

OPC Watch

OPC Namespace: The CoDaBix® Nodes use the OPC UA Namespace URI "codabix://opc.server/". By default, this namespace will have the namespace index “2”.

The OPC UA Server Interface Plugin provides diagnostics information in the Status Node of the channel.

Diagnostics Information in the "Status" Node

Node Description
Code Defines the numeric expression / identifier of the status. A negative value means that the Server could not be started, whereas 0 or a positive value indicates that the Server started successfully.
Category Classifies the status into Information, Warning and Error and therefore indicates the general type of status information.
Severity Rates the status information into Low, Moderate, High and Critical and therefore indicates the urgency of an intervention.
Text Describes the status information identified by the Code property.

As an interface plugin, the OPC UA Server Interface Plugin extends the basic CoDaBix® Interface Model.

As an interface plugin, the OPC UA Server Interface Plugin extends the basic CoDaBix® Interface Model.

Interface

The plugin's interface type OpcServerInterface also defines the OpcServerInterfaceChannel and therefore extends the basic CodabixInterface and CodabixInterfaceChannel entities. While the OpcServerInterface just represents a concretization of the CodabixInterface, the OpcServerInterfaceChannel extends the CodabixInterfaceChannel.

Channel

Each channel represents an OPC UA Server instance that can be configured, started and stopped.

Folders

Content Path Usage
Assembly <CodabixInstallDir>/plugins/OpcUaServerInterfacePlugin/ Contains the plugin's assembly file.
Config <CodabixDataDir>/plugins/OpcUaServerInterfacePlugin/ Contains the plugin's configuration file.

Files

Type Path Usage
Assembly [AssemblyFolder]/CoDaBix.OpcUaServerInterfacePlugin.dll The plugin's assembly file.

This Document

Date 2016-12-21
Version 1.3

Plugin

Name OPC UA Server
Node /System/Interfaces/OPC-UA Server Interface
Version 1.0.9

Assembly

Name CoDaBix.OpcUaServerInterfacePlugin.dll
Date 2018-02-01
Version 1.0.9.0