TAGO Q + A topic

DgDkUJrXUAEf0_e
Store, visualize and act on sensor data after activating the integration in our Developer Console.

TAGO - https://tago.io

TAGO helpcenter - https://tago.elevio.help/en
TAGO / TTN tutorial - https://tago.elevio.help/en/articles/102
TAGO docs - https://tago.io/developers
TAGO blog - https://blog.tago.io/

new TAGO FORUM - https://community.tago.io/latest

1 Like

I have given Tago a go, I have registered a device in a new bucket, and can add widgets on a dashboard using the payload fields that have come across from TTN (f_XXXX etc). I can see my bucket filling up with each new message but no data values seem to be coming through. I have some leading empty spaces and leading zeros in some of my data, can the dashboard handle those?

1 Like

@rcanoff from TAGO … welcome :sunglasses:

1 Like

Some of the widgets accept number only, like the gauge for example.
You can add a display or a table with your variable so that you can see exactly how your data is getting to Tago.
Also, you can add number formats to some of those widgets, and if you need, you can parse your data using actions and analysis

We have a lot of video tutorials on different features,
https://tago.io/videos
also we have a written documentation
https://tago.elevio.help/en

2 Likes

TAGO-1

Script Editor is now integrated

TAGO-2

TAGO-3

1 Like

Using Analysis
1 Like

Has anyone ever tried sending GPS coordinates to tago.io?

I am using a GPS sensor from Zane (zTrack Tube) and decoding the payload in TTN. All the data appear in tago.io. However, when trying to visualize the data on the map, it stays empty.

TTN Console:
image

tiago.io Dashboard:
Longitude and Latitude appear in the table:
image

However, the map stays empty when configuring the diagram:
image

Result:
image

Does anyone know, where my thinking error is?

@rcanoff ? :sunglasses:

Hello @lombi The problem is that the map is expecting the latitude and longitude in a different key of the json, something like this

  "variable": "any_variable_name",
  "location": {
    "lat": 42.2974279,
    "lng": -85.628292
  },
}```
to do that you would have to create a conversion for this value.
You could follow our parse tutorial, and instead of parsing the data, just build the json with the location key.
Link to the tutorial:
https://tago.elevio.help/en/articles/118-parsing-raw-payloads-into-actual-values
you would have to change a few things, instead of getting the raw payload, you can get your latitude and longitude and instead of doing some calculation, just put them into one variable
1 Like

Thank you for the link. I used the tutorial and built something that works. It’s probably not very sexy, but it fulfils it’s purpose. Here’s my solution:

/* 
 * Analysis Example
 * Generic Payload Parse
 * 
 * Learn how to parse from a hexadecimal raw payload into temperature and humidity variables
 * Tutorial: https://tago.elevio.help/en/articles/118
 */

const Analysis = require('tago/analysis');
const Device = require('tago/device');

// The function myAnalysis will run when you execute your analysis
async function myAnalysis(context, scope) {
  // Create a variable called payload with the value sent by the device
  const latVal = Number(scope[12].value);
  const lngVal = Number(scope[13].value);
  const port = Number(scope[8].value);

    if(port == 204){
      const variables = {
            variable: "location_action",
            location: {
                lat : latVal,
                lng : lngVal
            }
    };

        // Instantiate the device with your device token
        const device = new Device('507b2b6a-1657-4e54-93b7-7f36956d2798');

        // Insert the actual variables temperature and humidity to TagoIO
        await device.insert(variables).then(context.log).catch(context.log);
    }
}


// The analysis token in only necessary to run the analysis outside Tago
module.exports = new Analysis(myAnalysis, 'YOUR-ANALYSIS-TOKEN');
1 Like

Thats very nice, one thing I would change as you have a lot of scope variables is to find the variable instead of using the position

something like this:
const latVal = Number(scope.find(x => x.variable === 'latitude variable').value);

HI I am trying to work out why my payload Data is encrypted when it is sent to Tago IO
All Other Data like the Counter and App Id are fine and not encrypted except for the payload Data.
The data when sent to other platforms is fine and works with them just not with the Tago IO.
Any Ideas out there or anyone who is using Tago IO successfully ?

Ok So the Payload is not Encoded but in Base 64 and the rest of the Data like counter and App Id are either not sent in Base 64 or are correctly decoded by the Tago IO system ? As these display correctly on my dashboard in Tago IO but the Payload Data appears in Base 64 format ?
Any pointers as to why this Payload data is still in Base 64 ?

Well if anyone is interested Tago IO have fixed this problem at there end and it all appears to be working now.
Data is now showing up in Hex payload format like I expected.
Thanks to all those that help solve my problem.

1 Like

acme

Try out our new demo that shows you what your solution could look like with TagoIO. We created a website that presents a cold chain management solution to monitor temperature in refrigerators and freezers for users in different levels. You can access the dashboards logged as a Super Admin (that visualizes the whole operation), as a Supervisor (that visualizes only a determined region, or as Operation User that only has access to the freezers of his local store. Take a look here.