Adding sensors with Easy Setup - TeamViewer Support
<main>
<article class="userContent">
<p><em>This article applies to all TeamViewer IoT users and requires TeamViewer IoT Agent 2.8.14 or higher.</em></p><h2 data-id="general">General</h2><p>The “Easy Setup“ feature for adding sensors is intended to provide an intuitive and easy user experience which will lead through the setup steps in adding the sensors.</p><h2 data-id="how-to-setup">How to setup</h2><p><br></p><p>Login in <a href="https://teamviewer-iot.com/" rel="nofollow noreferrer ugc"><em>TeamViewer IoT Management Console</em></a> from navigation panel click on <em>Inventory</em> and from the <em>ADD</em> dropdown menu on the right select <em>Add Sensor.</em></p><div class="embedExternal embedImage display-large float-none">
<div class="embedExternal-content">
<a class="embedImage-link" href="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15094iEC9779F6395419D7.jpg" rel="nofollow noreferrer noopener ugc" target="_blank">
<img class="embedImage-img" src="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15094iEC9779F6395419D7.jpg" alt="TeamViewer_IoT_Management_Console.png" height="180" width="320" loading="lazy" data-display-size="large" data-float="none"></img></a>
</div>
</div>
<p><br></p><p> </p><p>After, click on <em>Easy setup</em> button.</p><p><br></p><div class="embedExternal embedImage display-large float-none">
<div class="embedExternal-content">
<a class="embedImage-link" href="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15095i1E53CCE0B2E79245.jpg" rel="nofollow noreferrer noopener ugc" target="_blank">
<img class="embedImage-img" src="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15095i1E53CCE0B2E79245.jpg" alt="easy_setup.png" height="180" width="320" loading="lazy" data-display-size="large" data-float="none"></img></a>
</div>
</div>
<p><br></p><p> </p><p><strong><em>Note: There are thousands of different sensors in the world. Some of them would need special libraries or custom development to get a data from. That’s why we provide a custom solution which will help to setup sensors easily from </em></strong><a href="https://teamviewer-iot.com/" rel="nofollow noreferrer ugc"><strong><em>TeamViewer IoT Management Console</em></strong></a></p><p>Here, select the <em>Device</em> for which you add a sensor (when you used the <em>Device menu</em>, it will come preselected). Make sure the latest version of <em>Agent</em> installed on the device, otherwise a warning will be displayed, and it will not be possible to continue with the setup. </p><p>After selecting the device, you need to provide a unique <em>Sensor</em> name along with <em>Metric</em> name and <em>ID</em>. </p><p>Value <em>Type</em> and Value <em>Unit</em> fields are optional.</p><p> </p><div class="embedExternal embedImage display-large float-none">
<div class="embedExternal-content">
<a class="embedImage-link" href="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15099i37BE844729A69C93.jpg" rel="nofollow noreferrer noopener ugc" target="_blank">
<img class="embedImage-img" src="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15099i37BE844729A69C93.jpg" alt="value.jpg" height="180" width="320" loading="lazy" data-display-size="large" data-float="none"></img></a>
</div>
</div>
<p><br></p><p> </p><p><strong><em>Note:</em></strong></p><p><strong><em>Sensor name is limited to 50 characters and alphanumeric and special characters can be used.</em></strong></p><p><strong><em>Metric name has a limitation of 30 characters.</em></strong></p><p><strong><em>Metric ID is limited to 32 characters and only Latin letters and numbers can be used (no special characters are allowed). You will get an error message if these rules are not followed.</em></strong></p><p><strong><em>Value Type default selection is “Number”. </em></strong></p><p>Once you are done with configuring one metric, you can add the next one, as well as delete already configured metrics. Up to 10 metrics can be configured per sensor.</p><p><br></p><p>Now, when the <em>Sensor</em> and <em>Metrics</em> are configured, click on <em>“download the generated template”</em>. The zip downloaded file contains the template examples in<em> Python</em> and <em>Bash</em>.</p><p>Unzip the file and select your preferred template.</p><p>The template script prints metric values of a sensor in <em>JSON</em> format and each metric is described as a variable which gets a random value in between 1 and 20.</p><p>If you don't have a ready script, you might need to search for tutorials on how to read your sensor data, find a library or script that works with your sensor and make sure that your script's output prints the <em>JSON</em> formatted example as presented in the template.</p><p>Then place the ready script on the edge device and provide the full path information into the configuration page.</p><p> </p><div class="embedExternal embedImage display-large float-none">
<div class="embedExternal-content">
<a class="embedImage-link" href="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15100iD9A6DE7EAD418FBD.jpg" rel="nofollow noreferrer noopener ugc" target="_blank">
<img class="embedImage-img" src="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15100iD9A6DE7EAD418FBD.jpg" alt="pathtoscript.png" height="180" width="320" loading="lazy" data-display-size="large" data-float="none"></img></a>
</div>
</div>
<p><br></p><p> </p><p><strong><em>Note: The script path and name validations are done with predefined standards and the scripts are checked to have python or shell file extensions. </em></strong></p><p>Don't forget to run "sudo chmod +x /<path to script>" on edge device to provide execution permissions to the script. It is advised also to manually execute the script on the device and check if the output matches the required <em>JSON</em> format. This will prevent further confusions.</p><p>Next, select the frequency by which the data will be sent to the <em>TeamViewer IoT Cloud</em>. It can be defined in seconds or minutes.</p><p>Press <em>ADD</em> button to send the configuration to the <em>Agent</em>, and once the <em>Agent</em> receives the configuration it will process with the data collection.</p><p> </p><div class="embedExternal embedImage display-large float-none">
<div class="embedExternal-content">
<a class="embedImage-link" href="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15101i18D7B7BE8BDC5712.jpg" rel="nofollow noreferrer noopener ugc" target="_blank">
<img class="embedImage-img" src="https://us.v-cdn.net/6032394/uploads/lithium_attachments/15101i18D7B7BE8BDC5712.jpg" alt="end.png" height="180" width="320" loading="lazy" data-display-size="large" data-float="none"></img></a>
</div>
</div>
<p><br></p><p> </p>
</article>
</main>