Decentlab Liquid Level
Fra IoTwiki
Info | |
---|---|
Produktnavn | Decentlab Liquid Level |
Sensortype | |
Modelnavn | Liquid Level / Pressure and Temperature |
Producent | decentlab |
Kort beskrivelse | Tryk og temperaturmåler til måling af vandstand |
Netværk | LoRaWAN |
Dokumentation | https://www.decentlab.com/products/liquid-level-pressure-and-temperature-lorawan |
Producentens hjemmeside | https://www.decentlab.com |
Anvendes i projekterne |
Beskrivelse
Dekodning af data
Dekodning af data i Node-RED
var data = msg.data
var time = msg.ts
var pressure = (parseInt(data.slice(10,14), 16)/16384)/32768
var temp = (parseInt(data.slice(14,18), 16)-384)/64000*200-50
var bat = parseInt(data.slice(18,22), 16)/1000
var deviceID = parseInt(data.slice(2,6), 16)
msg.payload = [{
time: time,
pressure: pressure,
temperature: temp,
battery: bat
},
{
device_id : deviceID
}];
return msg;