Skip to content
Stand with Ukraine flag

OPC-UA

This documentation will help you set up the OPC-UA connector for the ThingsBoard IoT Gateway. We’ll explain the configuration parameters in simple terms to make it easy for you to understand and follow. The OPC-UA (Open Platform Communications Unified Architecture) is a machine-to-machine communication protocol for industrial automation, and this connector allows seamless integration with the ThingsBoard platform. Use general configuration to enable this connector.

Also, if you are new to ThingsBoard IoT Gateway, we recommend you to read the Getting Started guide to understand the basic concepts of ThingsBoard IoT Gateway and how it works with OPC-UA protocol.

The connector can be configured via the user interface form, which helps you set up a connection to the OPC-UA server, collect data and write data to nodes. Let’s look at all the available settings and explain each one clearly. This will help you understand how everything works.

The OPC-UA connector can be configured in two modes: Basic and Advanced.

  • Basic mode is designed for users who are new to ThingsBoard IoT Gateway and want to quickly set up the connector with minimal configuration. It provides a simplified interface with essential settings.
  • Advanced mode is intended for experienced users who need more control over the configuration. It offers additional options and flexibility for advanced use cases.

You can switch between these modes using the toggle button at the top of the configuration page:

This configuration section contains general connector settings, such as:

  • Name - connector name used for logs and saving to persistent devices;
  • Logs configuration - settings for local and remote logging:
    • Enable remote logging - enables remote logging for the connector;
    • Logging level - logging level for local and remote logs: NONE, ERROR, CRITICAL, WARNING, INFO, DEBUG, TRACE;
  • Report strategy - strategy for sending data to ThingsBoard:
    • Report period - period for sending data to ThingsBoard in milliseconds;
    • Type - type of the report strategy:
      • On report period - sends data to ThingsBoard after the report period;
      • On value change - sends data to ThingsBoard when the value changes;
      • On value change or report period - sends data to ThingsBoard when the value changes or after the report period;
      • On received - sends data to ThingsBoard after receiving data from the device (default strategy).

Connection settings define how the OPC-UA connector establishes and maintains communication with the OPC-UA server. These settings cover the basic connection parameters, server discovery behavior, security configuration, and authentication modes.

This subsection specifies the target OPC-UA server and how the gateway interacts with it. It includes the server’s URL, timeout settings, scan intervals, and the option to use either subscriptions or polling to monitor data nodes.

This configuration section contains settings of the OPC-UA server connection, such as:

  • Server endpoint url - hostname or ip address of OPC-UA server;
  • Timeout in milliseconds - timeout in milliseconds for connecting to OPC-UA server;
  • Security policy - security policy (Basic128Rsa15, Basic256, Basic256Sha256);
  • Scan period in milliseconds - period in milliseconds to rescan the server;
  • Poll period - period in milliseconds to poll the server;
  • Subscription check period in milliseconds - period to check the subscriptions in the OPC-UA server;
  • Enable subscription - if true - the gateway will subscribe to interesting nodes and wait for data update and if false - the gateway will rescan OPC-UA server every scanPeriodInMillis;
  • Show map - show nodes on scanning true or false.

OPC-UA server connections offer three distinct security types:

  1. Anonymous - the simplest option of identity;

  2. Basic - using this option, you can provide the username and password to connect to the OPC-UA server;

  3. Certificates - the safest option of identity. Using this option, you can also provide path on machine with the gateway to certificate, private key and CA certificate. Optionally, you can provide the username/password pair.

Data mapping is a section that allows you to configure which node from the OPC-UA server will be assigned to which device in ThingsBoard. You can also use this section to configure which data will be sent as device attributes or telemetry. Data mapping contains all the necessary settings for flexible device and data management.

The following parameters are used to configure the base node of the device, its name and profile, as well as for report strategy:

  • Device node - the base node for the device. Paths to the device name, profile, attributes, and telemetry can be specified relative to this node.
  • Device name - the name of the device in ThingsBoard. It can be specified as a path or identifier to the node or as a static value (more information about types can be found in the Additional information section).
  • Device profile - the profile of the device in ThingsBoard. It can be specified as a path or identifier to the node or as a static value (more information about types can be found in the Additional information section).
  • Report strategy - strategy for sending data to ThingsBoard:
    • Report period - period for sending data to ThingsBoard in milliseconds;
    • Type - type of the report strategy:
      • On report period - sends data to ThingsBoard after the report period;
      • On value change - sends data to ThingsBoard when the value changes;
      • On value change or report period - sends data to ThingsBoard when the value changes or after the report period;
      • On received - sends data to ThingsBoard after receiving data from the device (default strategy).

To add a new device, use the following steps:

  1. Click the + Add mapping button.

  2. Provide the following fields in the opened model window: Device node, Device name and Profile name (all of them can be path or identifier).

Subsection “Attributes” and “Time series”

Section titled “Subsection “Attributes” and “Time series””

The configuration in this subsection provides settings for processing data from the OPC-UA node. These settings will be interpreted in ThingsBoard platform instance as attributes/time series of the device.

The following parameters are used to configure device attributes and time series:

  • Key - the key of the attribute/time series in ThingsBoard. It can be specified as a static value.
  • Type - the type of expression in the Value field (more information about types can be found in the Additional information section):
    • Path - can be absolute or relative path to the node in the OPC-UA server. The value will be taken from the node with the specified path.
    • Identifier - can be numeric, string, byte string or GUID identifier of the node in the OPC-UA server. The value will be taken from the node with the specified identifier.
    • Constant - a static value that will be sent to the device as an attribute/time series key.
  • Value - the value of the attribute/time series that will be sent to the platform device. It should be specified depending on the selected type (Path, Identifier or Constant).

To add new time series or attribute key, follow these steps:

  1. Click the “pencil” icon in the “Attributes” section to add new attribute key;

  2. Click on “Add attribute” in the opened window;

  3. Enter the “Key” field, select the “Type” (can be path, identifier or constant), enter “Value” and click “Apply” button;

  4. Now click on the “pencil” icon in the “Time series” section to add new time series key;

  5. Click on “Add time series” in the opened window;

  6. Enter the “Key” field, select the “Type” (can be path, identifier or constant), enter “Value” and click “Apply” button.

You can enable a specific report strategy for each time series or attribute. This strategy defines how often data is sent to the ThingsBoard server. The following strategies are available:

  • On report period - sends data to ThingsBoard after the report period;
  • On value change - sends data to ThingsBoard when the value changes;
  • On value change or report period - sends data to ThingsBoard when the value changes or after the report period;
  • On received - sends data to ThingsBoard after receiving data from the device (default strategy).

The device name and profile can be set dynamically using node values. In this example, we will use an absolute path to specify the device name and profile.

As an example, we will use Prosys OPC-UA Simulation Server, which is available at opc.tcp://0.0.0.0:53530/OPCUA/SimulationServer. The server has the following structure:

We are interested in nodes: “DeviceModelName” and “DeviceSeries”. We will use these nodes to set the device name and profile, respectively.

Let’s configure the device name and profile in the OPC-UA connector. For this purpose, follow these steps:

  1. Go to “Entities” → “Gateways” in the right sidebar and select your gateway.

  2. Click on the “Connectors configuration” button on the right side menu.

  3. Select the created OPC-UA connector, click on the “Data mapping” tab. Firstly, we need to configure parent (or device) node. Click on the ”+ Add mapping” button.

  4. In the opened window, fill in “Device node” field with Root\.Objects\.DemoDevice, also select “Path” in “Source” field. This is an absolute path to the parent node of the device we want to create.

  5. In the “Name” field, enter ${Root\.Objects\.DemoDeviceInfo\.DeviceModelName}, also select “Path” in “Source” field. This is an absolute path to the node that contains the device name.

  6. In the “Profile name” field, enter ${Root\.Objects\.DemoDeviceInfo\.DeviceSeries}, also select “Path” in “Source” field. This is an absolute path to the node that contains the device profile.

  7. Also, we need to add one attribute/time series because the connector will not add a device without any data to read (you can use any pre-installed Prosys OPC-UA Simulation Server node). Click on the “pencil” icon next to the “Attributes” section.

  8. In the opened window, click on the “Add attribute” button and fill the fields as on the corresponding image.

  9. Remember to save your changes by clicking the “Save” button.

Now we can check if the device name and profile are set correctly. Go to “Entities” > “Devices” and as you can see, the device name is set to Demo Device and the profile is set to Demo Series.

If you are using advanced configuration mode and want to set the device name and profile using an absolute path, you can use the following configuration:

{
"name": "OPC-UA",
"server": {
"url": "opc.tcp://0.0.0.0:53530/OPCUA/SimulationServer",
"timeoutInMillis": 5000,
"scanPeriodInMillis": 3600000,
"pollPeriodInMillis": 5000,
"enableSubscriptions": false,
"subCheckPeriodInMillis": 100,
"showMap": false,
"security": "Basic128Rsa15",
"identity": {
"type": "anonymous"
}
},
"mapping": [
{
"deviceNodeSource": "path",
"deviceNodePattern": "Root\\.Objects\\.DemoDevice",
"deviceInfo": {
"deviceNameExpression": "${Root\\.Objects\\.DemoDeviceInfo\\.DeviceModelName}",
"deviceNameExpressionSource": "path",
"deviceProfileExpressionSource": "path",
"deviceProfileExpression": "${Root\\.Objects\\.DemoDeviceInfo\\.DeviceSeries}"
},
"attributes": [
{
"key": "some_key",
"type": "identifier",
"value": "${ns=3;i=1001}"
}
],
"timeseries": [],
"rpc_methods": [],
"attributes_updates": []
}
]
}

The Requests mapping section allows you to configure how the ThingsBoard platform instance will interact with the devices. That is, how the platform will request data from the devices, how it will update device attributes, and how it will send RPC commands to the devices.

OPC-UA connector supports the following requests mapping:

  • Attribute updates - allows update device nodes values from ThingsBoard platform instance.
  • RPC methods - allows sending RPC commands to devices. Using RPC methods, you can get or set values of the OPC-UA nodes. OPC-UA connector supports different types of RPC methods, such as:
    • Reserved GET/SET methods - these methods are automatically created for each attribute and time series parameter. You can use them to get or set values of the OPC-UA nodes.
    • RPC method to connector - this method allows you to send a command to the connector from the ThingsBoard IoT Gateway UI. The command will be processed by the connector, and the result will be sent back to the ThingsBoard platform instance.
    • Configurable RPC methods to device - these methods allow you to configure custom RPC commands in connector configuration that can be sent to the devices.

This subsection contains configuration for attribute updates request from ThingsBoard platform instance.

ThingsBoard allows the provisioning of device attributes and fetches some of them from the device application. You can treat this as a remote configuration for devices, enabling them to request shared attributes from ThingsBoard. See user guide for more details.

The following parameters are used to configure attribute updates:

  • Key - the key of the shared attribute in ThingsBoard. It can be specified as a static value.
  • Type - the type of expression in the Value field (more information about types can be found in the Additional information section):
    • Path - can be absolute or relative path to the node in the OPC-UA server. The value will be taken from the node with the specified path.
    • Identifier - can be numeric, string, byte string or GUID identifier of the node in the OPC-UA server. The value will be taken from the node with the specified identifier.
    • Constant - a static value that will be sent to the device.
  • Value - the node in which the shared attribute value will be written. It should be specified depending on the selected type (Path, Identifier or Constant).

In order to add new attribute update, follow these steps:

  1. Click the “pencil” icon in the “Attribute updates” section to add new attribute update;

  2. Click on “Add attribute update” in the opened window;

  3. Enter the “Key” field, select the “Type” (can be path, identifier or constant), enter “Value” and click “Apply” button.

ThingsBoard allows sending RPC commands to devices connected directly to ThingsBoard or via Gateway. The following parameters are used to configure RPC methods:

  • Method name - the name of the method on OPC-UA server.
  • Arguments - list of arguments that will pass to OPC-UA server method.

In order to add new RPC method, follow these steps:

  1. Click the “pencil” icon in the “RPC methods” section to add new RPC method;

  2. Click on “Add method” in the opened window;

  3. Fill in “Method name” field. If the method has arguments, click on “Add argument” button and select the type of argument. Fill in the “Value” field and click “Apply” button.

Attribute updates allow you to update node values in the OPC-UA server. You can add new attribute updates in the “Attribute updates” section of the device configuration page.

As an example, we will use Prosys OPC-UA Simulation Server, which is available at opc.tcp://0.0.0.0:53530/OPCUA/SimulationServer. The server has the following structure:

Example: Relay Controlling (Relative Path)

Section titled “Example: Relay Controlling (Relative Path)”

We are interested in node “Relay”, we added this node as a telemetry parameter with the key relay. We used telemetry so that later it would be convenient for us to see if the value we changed using the attribute update has changed. You, also, can add this telemetry datapoint to the device configuration or use the reserved get RPC method to check the value of the node.

Let’s add an attribute update to our configuration. For this purpose, follow these steps:

  1. Go to “Entities” → “Gateways” in the right sidebar and select your gateway.

  2. Click on the “Connectors configuration” button on the right side menu.

  3. Select the created OPC-UA connector, click on the “Data mapping” tab. Make sure you have configured and connected device (if you do not know how to do it, see Getting Started guide or Connection settings and Data mapping sections of this guide). Click on the “Pencil” icon on a device you want to configure attribute updates for.

  4. Scroll down to the “Attribute updates” section and click on the “Pencil” icon to edit the attribute updates.

  5. Click on the “Add attribute update” button. In our case, we will add relay attribute update, so the “Key” field, enter relay, select the “Type” as Path, and in the “Value” field enter ${Relay}. This is a relative path to the device node we want to update.

  6. Remember to save your changes by clicking the “Apply” button.

Now we can check if the attribute update works. Go to “Entities” → “Devices” → select a created device → “Attributes” tab → select “Shared attributes” → click on the ”+” icon and add relay attribute with type “Boolean” set it to “True”.

Now, let’s check the value of the relay node. In the selected device, go to the “Last telemetry” tab and check the value of the relay telemetry. It should be true since we set the shared attribute to true.

Try to change the value of the relay shared attribute to false. After a few seconds, you should see that the relay telemetry value has changed to false, which means that the attribute update worked correctly.

Full configuration for OPC-UA connector for the examples above will look like this:

{
"server": {
"url": "opc.tcp://0.0.0.0:53530/OPCUA/SimulationServer",
"timeoutInMillis": 5000,
"scanPeriodInMillis": 3600000,
"enableSubscriptions": true,
"subCheckPeriodInMillis": 100,
"showMap": false,
"security": "Basic128Rsa15",
"identity": {
"type": "anonymous"
},
"pollPeriodInMillis": 5000
},
"mapping": [
{
"deviceNodePattern": "Root\\.Objects\\.DemoDevice",
"deviceNodeSource": "path",
"deviceInfo": {
"deviceNameExpression": "Demo Device",
"deviceNameExpressionSource": "constant",
"deviceProfileExpression": "default",
"deviceProfileExpressionSource": "constant"
},
"attributes": [],
"attributes_updates": [
{
"key": "relay",
"type": "path",
"value": "${Relay}"
}
],
"timeseries": [
{
"key": "relay",
"type": "identifier",
"value": "${ns=3;i=1012}"
}
],
"rpc_methods": []
}
]
}

The advanced configuration section provides a detailed overview of all available parameters for the OPC-UA connector.

The server object specifies the target OPC-UA server and how the gateway interacts with it.

ParameterDefault valueDescription
serverThe server object specifies the target OPC-UA server and how the gateway interacts with it.
server.urlHostname or ip address of OPC-UA server.
server.timeoutInMillis (in ms)5000Timeout in seconds for connecting to OPC-UA server.
server.scanPeriodInMillis (in ms)3600000Period in milliseconds for scanning the OPC-UA server for changes. If your OPC-UA server structure doesn’t change often, you can set a big period for gateway resource saving.
server.pollPeriodInMillis (in ms)5000Period in milliseconds to poll the server. If enableSubscriptions is set to true, pollPeriodInMillis does not affect data reading.
server.enableSubscriptionstrueIf true - the gateway will subscribe to interesting nodes and wait for data update and if false - the gateway will rescan OPC-UA server every scanPeriodInMillis.
server.subCheckPeriodInMillis (in ms)100Defines the publishing/check interval that the connector requests when creating OPC-UA subscriptions.
server.subKeepAlivePeriodInSeconds (in seconds) **0The interval at which the connector checks whether OPC-UA subscriptions are still “alive” (i.e., the publish/data-change flow is not stalled). This check is disabled by default (set to 0). If a subscription shows no activity longer than this threshold, the connector treats it as expired and triggers resubscription to restore updates.
server.subDataMaxBatchSize1000Maximum number of data items in a single subscription update. This is useful for performance optimization.
server.subDataMinBatchCreationTimeMs (in ms)200Minimum time in milliseconds to wait before creating a new batch of data items in a subscription update. This helps to reduce the number of updates sent to ThingsBoard.
server.subscriptionProcessBatchSize2000Maximum number of data items to process in a single batch when handling subscription updates. This is useful for performance optimization.
server.sessionTimeoutInMillis (in ms)120000Session timeout in milliseconds. This is the maximum time the session can be inactive before it is closed by the server.
server.showMapfalseIf true - the gateway will show a map of OPC-UA server nodes in the terminal. This is useful for debugging and understanding the structure of the OPC-UA server.
server.securityBasic128Rsa15Security policy (Basic128Rsa15, Basic256, Basic256Sha256).

Example of the server configuration:

"server": {
"url": "localhost:4840/freeopcua/server/",
"timeoutInMillis": 5000,
"scanPeriodInMillis": 3600000,
"pollPeriodInMillis": 5000,
"enableSubscriptions": true,
"subCheckPeriodInMillis": 100,
"subDataMaxBatchSize": 1000,
"subDataMinBatchCreationTimeMs": 200,
"subscriptionProcessBatchSize": 2000,
"sessionTimeoutInMillis": 120000,
"showMap": false,
"security": "Basic128Rsa15",
"identity": {
"type": "anonymous"
}
}

The identity object specifies the authentication method used to connect to the OPC-UA server. It can be one of the following: anonymous, basic, certificates.

ParameterDefault valueDescription
server.identity.typeanonymousType of identity on OPC-UA server.
ParameterDefault valueDescription
server.identity.typebasicType of identity on OPC-UA server.
server.identity.usernameUsername for logging into the OPC-UA server.
server.identity.passwordPassword for logging into the OPC-UA server.

Example of the basic identity configuration:

"identity": {
"type": "basic",
"username": "user",
"password": "5Tr0nG?@$sW0rD"
},
ParameterDefault valueDescription
server.identity.typecert.PEMType of identity on OPC-UA server.
server.identity.caCertPath to the CA certificate.
server.identity.certPath to the client certificate.
server.identity.privateKeyPath to the client private key.
server.identity.modeSignAndEncryptSecurity mode, there are 2 options – Sign and SignAndEncrypt.
username(Optional) Username for logging into the OPC-UA server.
password(Optional) Password for logging into the OPC-UA server.

Example of the basic certificates configuration:

"identity": {
"type": "cert.PEM",
"caCert": "etc/thingsboard-gateway/ca.pem",
"privateKey": "etc/thingsboard-gateway/private_key.pem",
"cert": "etc/thingsboard-gateway/cert.pem",
"mode": "SignAndEncrypt",
"username": "user",
"password": "5Tr0nG?@$sW0rD"
},

The Mapping list is used to configure how the OPC-UA connector will map data from the OPC-UA server to ThingsBoard devices. It allows you to specify which nodes from the OPC-UA server will be used as device names, device profiles, device attributes, and telemetry data.

ParameterDescription
mapping[].deviceNodeSourceSource of the device node, can be: path, identifier or constant.
mapping[].deviceNodePatternAbsolute or relative path, or identifier, which is used for looking up the node for a current device. Paths to the device name, profile, attributes, and telemetry can be specified relative to this node.
mapping[].deviceInfoDevice info object using for configuring device name and profile.
mapping[].deviceInfo.deviceNameExpressionSourceSource of the device name (can be path, identifier or constant).
mapping[].deviceInfo.deviceNameExpressionPath to a variable with device name, which is used for looking up the device name in a variable.
mapping[].deviceInfo.deviceProfileSourceSource of the device profile (can be path, identifier or constant).
mapping[].deviceInfo.deviceProfileExpressionPath to a variable with device profile, is used for looking the device profile in some variable.
mapping[].reportStrategyReport strategy object using for configuring report strategy for device.

Example of the device mapping configuration:

"mapping": [
{
"deviceNodeSource": "path",
"deviceNodePattern": "Root\\.Objects\\.MyObject",
"deviceInfo": {
"deviceNameExpression": "OPCUA New Advanced Device",
"deviceNameExpressionSource": "path",
"deviceProfileExpression": "some other default 1",
"deviceProfileExpressionSource": "constant"
},
"attributes": [],
"timeseries": [],
"attributes_updates": [],
"rpc_methods": [],
},
]
ParameterDescription
mapping[].attributes[]List of attributes that will be sent to the ThingsBoard platform instance.
mapping[].attributes[].keyKey name of the attribute in ThingsBoard. It can be specified as a static value.
mapping[].attributes[].typeType of the expression in the value field (can be path, identifier or constant).
mapping[].attributes[].valueValue of the attribute that will be sent to the platform. It should be specified depending on the selected type (path, identifier or constant).
mapping[].attributes[].reportStrategy(Optional) Report strategy for the attributes data. If not specified, the device report strategy will be used.
mapping[].timeseries[]List of telemetry data that will be sent to the ThingsBoard platform instance.
mapping[].timeseries[].keyKey name of the telemetry data in ThingsBoard. It can be specified as a static value.
mapping[].timeseries[].typeType of the expression in the value field (can be path, identifier or constant).
mapping[].timeseries[].valueValue of the telemetry data that will be sent to the platform. It should be specified depending on the selected type (path, identifier or constant).
mapping[].timeseries[].timestampLocation(Optional) Location of the timestamp for the attribute. If not specified, the current time will be used. Can be: sourcetimestamp, servertimestamp
mapping[].timeseries[].reportStrategy(Optional) Report strategy for the time series data. If not specified, the device report strategy will be used.

Example of the attributes and telemetry configuration:

"attributes": [
{
"key": "Power",
"type": "path",
"value": "${Power}"
},
{
"key": "Frequency",
"type": "path",
"value": "${Frequency}"
}
],
"timeseries": [
{
"key": "Humidity",
"type": "path",
"value": "${ns=2;i=16}"
},
{
"key": "Temperature",
"type": "path",
"value": "${Root\\.Objects\\.MyObject\\.Temperature}"
}
],
ParameterDefault valueDescription
mapping[].attributes_updates[]List of attributes that will be updated on the device.
mapping[].attributes_updates[].keyKey name of the shared attribute in ThingsBoard. It can be specified as a static value.
mapping[].attributes_updates[].typeType of the expression in the value field (can be path, identifier or constant).
mapping[].attributes_updates[].valueValue of the attribute that will be sent to the device. It should be specified depending on the selected type (path, identifier or constant).
mapping[].attributes_updates[].timeout (in ms)5000Timeout in milliseconds for the attribute update request.

Example of the attributes updates configuration:

"attributes_updates": [
{
"key": "nodeById",
"type": "path",
"value": "ns=2;i=23"
"timeout": 5000
},
]
ParameterDefault valueDescription
mapping[].rpc_methods[]List of RPC methods that will be sent to the device.
mapping[].rpc_methods[].methodName of the method on the OPC-UA server.
mapping[].rpc_methods[].arguments(Optional) List of default arguments that will pass to the OPC-UA server method.
mapping[].rpc_methods[].arguments[].typeType of the argument.
mapping[].rpc_methods[].arguments[].value(Optional) Value of the argument.
mapping[].rpc_methods[].timeout (in ms)5000Timeout in milliseconds for the RPC method execution.

Example of the RPC methods configuration:

"rpc_methods": [
{
"timeout": 3000,
"method": "multiply",
"arguments": [
{
"type": "integer",
"value": 2
},
{
"type": "integer",
"value": 4
}
]
},
]

A Path type refers to the hierarchical address within the OPC-UA server’s namespace. It is used to navigate to specific nodes in the server.

The path for the attribute value can be absolute or relative.

An absolute path specifies the full hierarchical address from the root of the OPC-UA server’s namespace to the target node.

Example:

Gateway expects the node to exist and the value of “Root.Objects.TempSensor.Temperature” to be 23.54.

Expression:

${Root\\.Objects\\.TempSensor\\.Temperature}

Converted data:

23.54

A relative path specifies the address relative to a predefined starting point in the OPC-UA server’s namespace.

Example:

Gateway expects the node to exist and the value of “Root.Objects.TempSensor.Temperature” to be 23.56.

Device Node Expression:

Root\\.Objects\\.TempSensor

Expression:

${Temperature}

Converted data:

23.56

An Identifier type is a unique ID assigned to a node within the OPC-UA server. It is used to directly reference specific nodes without navigating through the namespace hierarchy.

The Identifier type in the OPC-UA connector configuration can take various forms to uniquely reference nodes in the OPC-UA server’s address space. Identifiers can be of different types, such as numeric (i), string (s), byte string (b), and GUID (g). Below is an explanation of each identifier type with examples.

  • Numeric Identifier (i)

    A numeric identifier uses an integer value to uniquely reference a node in the OPC-UA server.

    Expression:

    ${ns=2;i=1235}

    Converted data:

    21.34

  • String Identifier (s)

    A string identifier uses a string value to uniquely reference a node in the OPC-UA server.

    Expression:

    ${ns=3;s=TemperatureSensor}

    Converted data:

    21.34

  • Byte String Identifier (b)

    A byte string identifier uses a byte string to uniquely reference a node in the OPC-UA server. This is useful for binary data that can be converted to a byte string.

    Expression:

    ${ns=3;b=Q2xpZW50RGF0YQ==}

    Converted data:

    21.34

  • GUID Identifier (g)

    A GUID identifier uses a globally unique identifier (GUID) to uniquely reference a node in the OPC-UA server.

    Expression:

    ${ns=3;g=550e8400-e29b-41d4-a716-446655440000}

    Converted data:

    21.34