Skip to content

[HELP] Docs for OPCUA connector configuration #1587

@andersenthomas98

Description

@andersenthomas98

Describe the issue
Hi, where can I find the documentation for the fields in the OPCUA connector configuration? The default version that comes up in thingsboard cloud looks like this:

{
  "server": {
    "url": "localhost:4840/freeopcua/server/",
    "timeoutInMillis": 5000,
    "scanPeriodInMillis": 3600000,
    "pollPeriodInMillis": 5000,
    "enableSubscriptions": true,
    "subCheckPeriodInMillis": 100,
    "showMap": false,
    "security": "Basic128Rsa15",
    "identity": {
      "type": "anonymous"
    }
  },
  "mapping": [
    {
      "deviceNodePattern": "Root\\.Objects\\.Device1",
      "deviceNodeSource": "path",
      "deviceInfo": {
        "deviceNameExpression": "Device ${Root\\.Objects\\.Device1\\.serialNumber}",
        "deviceNameExpressionSource": "path",
        "deviceProfileExpression": "Device",
        "deviceProfileExpressionSource": "constant"
      },
      "attributes": [
        {
          "key": "temperature °C",
          "type": "path",
          "value": "${ns=2;i=5}"
        }
      ],
      "timeseries": [
        {
          "key": "humidity",
          "type": "path",
          "value": "${Root\\.Objects\\.Device1\\.TemperatureAndHumiditySensor\\.Humidity}"
        },
        {
          "key": "batteryLevel",
          "type": "path",
          "value": "${Battery\\.batteryLevel}"
        }
      ],
      "rpc_methods": [
        {
          "method": "multiply",
          "arguments": [
            {
              "type": "integer",
              "value": 2
            },
            {
              "type": "integer",
              "value": 4
            }
          ]
        }
      ],
      "attributes_updates": [
        {
          "key": "deviceName",
          "type": "path",
          "value": "Root\\.Objects\\.Device1\\.serialNumber"
        }
      ]
    }
  ],
  "logLevel": "INFO",
  "name": "test",
  "enableRemoteLogging": false,
  "id": "dc087da7-8682-45b8-a4ee-10eb5cba1591"
}

However, this does not look like it matches what is documented here:

{
  "server": {
    "name": "OPC-UA Default Server",
    "url": "localhost:4840/freeopcua/server/",
    "timeoutInMillis": 5000,
    "scanPeriodInMillis": 5000,
    "disableSubscriptions":false,
    "subCheckPeriodInMillis": 100,
    "showMap": false,
    "security": "Basic128Rsa15",
    "identity": {
      "type": "anonymous"
    },
    "mapping": [
      {
        "deviceNodePattern": "Root\\.Objects\\.Device1",
        "deviceNamePattern": "Device ${Root\\.Objects\\.Device1\\.serialNumber}",
        "attributes": [
          {
            "key": "CertificateNumber",
            "path": "${ns=2;i=5}"
          }
        ],
        "timeseries": [
          {
            "key": "temperature °C",
            "path": "${Root\\.Objects\\.Device1\\.TemperatureAndHumiditySensor\\.Temperature}"
          },
          {
            "key": "batteryLevel",
            "path": "${Battery\\.batteryLevel}"
          }
        ],
        "rpc_methods": [
          {
            "method": "multiply",
            "arguments": [2, 4]
          }
        ],
        "attributes_updates": [
          {
            "attributeOnThingsBoard": "deviceName",
            "attributeOnDevice": "Root\\.Objects\\.Device1\\.serialNumber"
          }
        ]
      }
    ]
  }
}

For instance, there is a new field called "type" in the "timeseries" subsection.

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions