TeamViewer IoT SDK

TeamViewer IoT Documentation


TeamViewer IoT SDK

Introduction to TeamViewer IoT SDK #

The software development kits (SDK) are collections of software development tools in a installable package.

The SDKs enable advanced users to create custom applications within the TeamViewer IoT Solution, e.g. automation of processes.

The following SDKs are available:

TeamViewer IoT C-SDK #

The TeamViewer IoT C-SDK is a development kit to facilitate integration of sensors to the IoT Agent MQTT API to allow for secure data registration and transfer to your TeamViewer IoT Cloud.

See:

Download the C-SDK #

Depending on your operating system and architecure, select the correct SDK Installation Package.

 

Linux

 

Architecture Installation Package
ARM v5 hf TeamViewer IoT C SDK for ARM v5 hf
ARM v5 el TeamViewer IoT C SDK for ARM v5 el
ARM v7 hf TeamViewer IoT C SDK for ARM v7 hf
i386 (x86 32 Bit) TeamViewer IoT C SDK for i386 (x86_32 Bit)
AMD64 (x86 64 Bit) TeamViewer IoT C SDK for AMD64 (x86_64 Bit)

 

Windows

 

Architecture Installation Package
Windows 8 (or newer) compatible device TeamViewer IoT C SDK for Microsoft Windows

 

 

 

 

Set up the C-SDK with Visual Studio #

What you will need

Make sure that you have prepared the following points:

Setup

  1. On your PC open Visual Studio.
  2. Create or open a C project you would like to use to create solutions for your edge device.
  3. Open the Solution Explorer (default: CRTL+ALT+L).
  4. Right click the project name and from the popup menu select Properties.
  5. On the left side click General > C/C++.
  6. On the right side click Additional Include Directories then select Edit from the drop-down-menu.
  1. Add the directory /include/ from the downloaded SDK to the project and click OK.
  2. On the left side click Linker > General.
  3. On the right side click Additional Library Directories then select Edit from the drop-down-menu.
  1. Add the directories which contain the library files from the downloaded SDK to the project and click OK.
  2. In the Properties dialog click OK.

TeamViewer IoT Node-SDK #

The TeamViewer IoT Node-SDK (JavaScript) is a development kit to facilitate the integration of sensors to the IoT Agent MQTT API to allow for secure data registration and transfer to your TeamViewer IoT Cloud.

See:

Set up the Node-SDK (Linux) #

What you will need

Make sure that you have prepared the following points:

Setup

  1. Access the edge device remotely (Access the Edge Device via Remote Terminal).
  2. Download the SDK on the edge device. In the terminal type in the following command and press return.
wget https://download.teamviewer-iot.com/sdks/nodejs/v1.0.3/teamviewer-iot-sdk-nodejs-v1.0.3.tar.gz
  1. Extract and install the SDK. In the terminal type in the following commands and press return.
sudo tar -zxvf teamviewer-iot-sdk-nodejs-v1.0.3.tar.gz
cd teamviewer-iot-sdk-nodejs
sudo npm install
  1. Optional: run the SDKs’ examples. In the terminal type in the following command and press return.
sudo node ./examples/create_metric.js
 

 

TeamViewer IoT Python-SDK #

The TeamViewer IoT Python-SDK is a development kit to facilitate the integration of sensors to the IoT Agent MQTT API to allow for secure data registration and transfer to your TeamViewer IoT Cloud.

See:

Set up the Python-SDK (Linux) #

What you will need

Make sure that you have prepared the following points:

Setup

  1. Access the edge device remotely (Access the Edge Device via Remote Terminal).
  2. Download the SDK files. In the terminal type in the following command and press return.
wget https://download.teamviewer-iot.com/sdks/python/v1.1.0/teamviewer_iot_python_sdk-1.1.0-py3-none-any.whl
  1. Install the SDK. In the terminal type in the following command and press return.
sudo pip3 install teamviewer_iot_python_sdk-1.1.0-py3-none-any.whl
  1. Extract the package files. In the terminal type in the following command and press return.
unzip teamviewer_iot_python_sdk-1.1.0-py3-none-any.whl -d
teamviewer_iot_python_sdk
  1. Optional: Run the SDK example. In the terminal type in the following command and press return.
cd teamviewer_iot_python_sdk
sudo python3 ./examples/create_metric.py
 

 

TeamViewer IoT Node-Red Plugin #

For the Node-Red programming environment, TeamViewer provides a plugin which can be used to interact with TeamViewer IoT Agent.

The plugin enables advanced users to create sensors/metrics and to push data to the TeamViewer IoT Cloud. The plugin is available at the Node-Red Flows and can be installed directly from the Node-Red environment.

See:

Set up the TeamViewer IoT Node-Red Plugin #

What you will need

Make sure that you have prepared the following points:

Setup

  1. Access the edge device remotely (Access the Edge Device via Remote Terminal).
  2. Edit the ~/.node-red/settings.js file in your user directory and uncomment the contextStorage section.
contextStorage: {
 default: {
  module:"localfilesystem"
 },
},

Note: The location of the file is depending how you start the node-red. Could be under root or your user directory.

  1. Install Teamviewer IoT Node-Red Plugin directly from the Node-Red environment.

Access your Node-Red webpage. From the menu, select Manage Palette, search for “teamviewer” and click Install.

Node-Red Plugin Download
  1. Alternatively, install Teamviewer IoT Node-Red Plugin using npm by running in terminal the command:
npm install @teamviewer/node-red-contrib-teamviewer-iot

 

Application Development with the TeamViewer IoT Node-Red Plugin #

What you will need

Make sure that you have prepared the following points:

  1. Open the node-red web interface from your web browser and in the left panel you will find the teamviewer iot node. Configure it as described in the help window.
Node-Red Plugin App
  1. Use the TeamViewer IoT node to create instances in TeamViewer IoT Cloud.
  2. Each node represents a TeamViewer IoT Metric in Node-Red environment.
  3. Each Metric needs to be assigned to a Sensor.
  4. For each Sensor, select or add a Client.
  5. The green dot at the node indicates a successful connection to the TeamViewer IoT Agent.
  6. In the TeamViewer IoT Cloud, the created sensors and metrics can be seen.

 

Suggest Edit
Want more? Exclusive deals, the latest news: Our Newsletter!