📌Note: This article applies to all TeamViewer IoT users and requires TeamViewer IoT Agent 2.11 or higher.
OPC Technology stands for “Open Platform Communications” and is an approved communication standard for the process industry. The OPC Unified Architecture (UA) is an interoperability standard and provides a secure and reliable data exchange mechanism. OPC UA is a platform-independent system and ensures information flow between devices from multiple vendors. For real-time data access, the OPC Data Access specification is being used.
TeamViewer IoT provides an OPC UA Connector that connects to the OPC UA Server and collects values from OPC UA Variables. The connector communicates with TeamViewer IoT Cloud with the help of the IoT Agent.
The setup contains three basic steps. Follow the sections in this article:
- Connector Configuration
- Adding a Sensor via OPC UA Connector
- Access the edge device remotely (Access the Edge Device via Remote Terminal).
- In the terminal type in the following command and press return.
sudo teamviewer-iot-agent install opcua
In most cases, the OPC UA servers are configured by other companies. And the configuration is specific to the installation and the environment where it is being used. You need to configure the OPC UA Connector according to your server’s configuration by providing the URL of the server, security settings, and authentication options.
- Edit the opcua.conf file. The file is located in /var/lib/teamviewer-iot-agent/scripts/opcua/ directory of the Edge Device.
- Below are the parameters included in the file:
# Server Information
# Security Policy
# 0 - None
# 1 - Basic128Rsa15
# 2 - Basic256
# 3 - Basic256Sha256
# 4 - Aes128Sha256RsaOaep
# 5 - Aes256Sha256RsaPss
# Message Security Mode
# 0 - None
# 1 - Sign
# 2 - Sign & Encrypt
# Authentication Settings
# 0 - Anonymous
# 1 - Username & Password
# 2 - Certificate & Private Key
# If "Username & Password" is selected
Adding a sensor via OPC UA connector
- Sign in to https://iot.teamviewer.com/.
- From the navigation panel click on Inventory.
- Select the Edge Device where the Connector is installed and from the dropdown menu on the right select Add Sensor.
- Choose the OPC UA from the Connectors section.
- Provide the Node IDs as they are specified in the server.
- Associate the OPC UA Nodes with a metric name that will be displayed in Teamviewer IoT Cloud. All the metrics are grouped in a sensor instance.
- Provide the scan rate at which the data will be requested from the server and save your configuration.
- Monitor the values received from the OPC UA Server by pining the configured metrics to the Dashboard.