With Ubidots you can monitor your values remotely and get notifications when they go over set thresholds.

Sign up to Ubidots and get an API Token

  • Create an Ubidots account

  • Click on the profile icon in the top-right corner and select API Credentials, then copy your Default Token

Node-RED flow

Here is the complete flow which you can import to Node-RED:

[{"id":"6c6622f5.06be2c","type":"mqtt in","z":"2c41a2bd.aa36ae","name":"","topic":"node/#","qos":"2","broker":"29fba84a.b2af58","x":70,"y":40,"wires":[["f3036e8f.15107"]]},{"id":"f3036e8f.15107","type":"function","z":"2c41a2bd.aa36ae","name":"Ubidots Decode","func":"// Declare variables\nvar ubi_payload = {}\nvar ubi_msg = {};\nvar topic = msg.topic.split(\"/\");\n\n// Get device label, variable name and value from HARDWARIO message\nvar device_label = topic[1];\nvar variable = topic[4];\nvar value = msg.payload;\n\n// Build Ubidots MQTT payload\nubi_msg['device_label'] = device_label;\nubi_payload[variable] = value;\nubi_msg['payload'] = ubi_payload;\nreturn ubi_msg;","outputs":1,"noerr":0,"x":280,"y":40,"wires":[["3ae188a9.accc48"]]},{"id":"3ae188a9.accc48","type":"ubidots_out","z":"2c41a2bd.aa36ae","name":"","token":"YOUR-TOKEN-HERE","label_device":"","device_label":"","tier":"educational","x":530,"y":40,"wires":[]},{"id":"29fba84a.b2af58","type":"mqtt-broker","z":"","broker":"","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","willTopic":"","willQos":"0","willPayload":""}]

To send your data to your Ubidots account just double click on the Ubidots out node and enter your Ubidots TOKEN.

The Ubidots Node

HARDWARIO TOWER utilizes Ubidots official Node-RED node, which connects to Ubidots’ MQTT broker and expects a Node-RED message with the following format:

2    "device_label": YOUR_DEVICE_NAME,

To aggregate HARDWARIO’s messages into the expected Ubidots format, a function called Ubidots Decode is used (this function is already included in the Node-RED flow above):

 1// Declare variables
 2var ubi_payload = {}
 3var ubi_msg = {};
 4var topic = msg.topic.split("/");
 6// Get device label, variable name and value from HARDWARIO message
 7var device_label = topic[1];
 8var variable = topic[4];
 9var value = msg.payload;
11// Build Ubidots MQTT payload
12ubi_msg['device_label'] = device_label;
13ubi_payload[variable] = value;
14ubi_msg['payload'] = ubi_payload;
15return ubi_msg;


This simple setup will automatically create a new Ubidots device for every new HARDWARIO module detected by your HARDWARIO gateway.

There’s more

In the Dashboard tab you can create a preview of all your important values. In the Event tab you can set rules so you’ll get notified when some value gets out of the limits. The SMS notification is easy to set-up and just works.