Hallo zusammen,
hier mein formatierter Flow.
[
{
"id": "7f6c67de.46317",
"type": "tab",
"label": "Test",
"disabled": false,
"info": ""
},
{
"id": "37a66629.28430a",
"type": "json",
"z": "7f6c67de.46317",
"name": "",
"property": "payload",
"action": "",
"pretty": false,
"x": 210,
"y": 160,
"wires": [
[
"8ce219df.de524",
"4d533e28.c1021",
"b59dea49.d0d7e8"
]
]
},
{
"id": "8ce219df.de524",
"type": "template",
"z": "7f6c67de.46317",
"name": "Temperatur",
"field": "payload",
"fieldType": "msg",
"format": "handlebars",
"syntax": "mustache",
"template": "{{payload.payload_fields.temperature}}",
"output": "str",
"x": 370,
"y": 160,
"wires": [
[
"b3149017.73a2b",
"51734cc3.d7457c"
]
]
},
{
"id": "4d533e28.c1021",
"type": "template",
"z": "7f6c67de.46317",
"name": "Humidity",
"field": "payload",
"fieldType": "msg",
"format": "handlebars",
"syntax": "mustache",
"template": "{{payload.payload_fields.humidity}}",
"output": "str",
"x": 340,
"y": 220,
"wires": [
[
"2f4245b4.de7712",
"da7df988.1483e8"
]
]
},
{
"id": "51734cc3.d7457c",
"type": "ui_gauge",
"z": "7f6c67de.46317",
"name": "",
"group": "834de424.aa51c8",
"order": 1,
"width": "6",
"height": "6",
"gtype": "gage",
"title": "Temperture",
"label": "C",
"format": "{{value}}",
"min": "-20",
"max": "+50",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"x": 630,
"y": 160,
"wires":
},
{
"id": "2f4245b4.de7712",
"type": "ui_gauge",
"z": "7f6c67de.46317",
"name": "",
"group": "ae53f947.6d7ae8",
"order": 1,
"width": "6",
"height": "6",
"gtype": "gage",
"title": "Humidity",
"label": "%",
"format": "{{value}}",
"min": 0,
"max": "100",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"x": 640,
"y": 260,
"wires":
},
{
"id": "5b071e0d.913978",
"type": "change",
"z": "7f6c67de.46317",
"name": "globalTempMax",
"rules": [
{
"t": "set",
"p": "maxtemp",
"pt": "global",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 320,
"y": 460,
"wires": [
[
"92bb8cd7.41dab8"
]
]
},
{
"id": "6ebf7e8.215d5",
"type": "ui_slider",
"z": "7f6c67de.46317",
"name": "",
"label": "Max Temperature",
"tooltip": "",
"group": "834de424.aa51c8",
"order": 4,
"width": "5",
"height": "1",
"passthru": true,
"outs": "all",
"topic": "",
"min": "-30",
"max": "60",
"step": 1,
"x": 130,
"y": 460,
"wires": [
[
"5b071e0d.913978"
]
]
},
{
"id": "b3149017.73a2b",
"type": "switch",
"z": "7f6c67de.46317",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "lt",
"v": "mintemp",
"vt": "global"
},
{
"t": "gt",
"v": "maxtemp",
"vt": "global"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 650,
"y": 120,
"wires": [
[
"8b03c7c6.070768"
],
[
"eb4c1d79.812d48"
]
]
},
{
"id": "a1a9eea7.a95d98",
"type": "ui_slider",
"z": "7f6c67de.46317",
"name": "",
"label": "Min Temperature",
"tooltip": "",
"group": "834de424.aa51c8",
"order": 2,
"width": "5",
"height": "1",
"passthru": true,
"outs": "all",
"topic": "",
"min": "-30",
"max": "60",
"step": 1,
"x": 130,
"y": 420,
"wires": [
[
"22341281.58a816"
]
]
},
{
"id": "22341281.58a816",
"type": "change",
"z": "7f6c67de.46317",
"name": "globalTempMin",
"rules": [
{
"t": "set",
"p": "mintemp",
"pt": "global",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 320,
"y": 420,
"wires": [
[
"26066f90.c90558"
]
]
},
{
"id": "eb4c1d79.812d48",
"type": "change",
"z": "7f6c67de.46317",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "Warning! Temperatur to HIGH",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 160,
"wires": [
[
"15900e08.1c9ea2"
]
]
},
{
"id": "8b03c7c6.070768",
"type": "change",
"z": "7f6c67de.46317",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "Warning! Temperatur to LOW",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 120,
"wires": [
[
"15900e08.1c9ea2"
]
]
},
{
"id": "da7df988.1483e8",
"type": "switch",
"z": "7f6c67de.46317",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "lt",
"v": "minhum",
"vt": "global"
},
{
"t": "gt",
"v": "maxhum",
"vt": "global"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 650,
"y": 220,
"wires": [
[
"b829e49.c4e7a18"
],
[
"205cb4c8.fc12b4"
]
]
},
{
"id": "205cb4c8.fc12b4",
"type": "change",
"z": "7f6c67de.46317",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "Warning! Humidity to HIGH",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 260,
"wires": [
[
"15900e08.1c9ea2"
]
]
},
{
"id": "b829e49.c4e7a18",
"type": "change",
"z": "7f6c67de.46317",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "Warning! Humidity to LOW",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 220,
"wires": [
[
"15900e08.1c9ea2"
]
]
},
{
"id": "3eb50d13.d7be1a",
"type": "change",
"z": "7f6c67de.46317",
"name": "globalHumMax",
"rules": [
{
"t": "set",
"p": "maxhum",
"pt": "global",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 460,
"wires": [
[
"856c61d2.cd14c8"
]
]
},
{
"id": "6a29c82.7464938",
"type": "ui_slider",
"z": "7f6c67de.46317",
"name": "",
"label": "Max Humidity",
"group": "ae53f947.6d7ae8",
"order": 4,
"width": "5",
"height": "1",
"passthru": true,
"topic": "",
"min": "-1",
"max": "101",
"step": 1,
"x": 640,
"y": 460,
"wires": [
[
"3eb50d13.d7be1a"
]
]
},
{
"id": "4f3f620f.0f69ec",
"type": "ui_slider",
"z": "7f6c67de.46317",
"name": "",
"label": "Min Humidity",
"group": "ae53f947.6d7ae8",
"order": 2,
"width": "5",
"height": "1",
"passthru": true,
"topic": "",
"min": "-1",
"max": "101",
"step": 1,
"x": 630,
"y": 420,
"wires": [
[
"8bb67b95.b8b098"
]
]
},
{
"id": "8bb67b95.b8b098",
"type": "change",
"z": "7f6c67de.46317",
"name": "globalHumMin",
"rules": [
{
"t": "set",
"p": "minhum",
"pt": "global",
"to": "payload",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 420,
"wires": [
[
"85378aaf.6a53e8"
]
]
},
{
"id": "26066f90.c90558",
"type": "ui_text",
"z": "7f6c67de.46317",
"group": "834de424.aa51c8",
"order": 3,
"width": "1",
"height": "1",
"name": "",
"label": "",
"format": "{{msg.payload}}",
"layout": "row-spread",
"x": 470,
"y": 420,
"wires":
},
{
"id": "92bb8cd7.41dab8",
"type": "ui_text",
"z": "7f6c67de.46317",
"group": "834de424.aa51c8",
"order": 5,
"width": "1",
"height": "1",
"name": "",
"label": "",
"format": "{{msg.payload}}",
"layout": "row-spread",
"x": 470,
"y": 460,
"wires":
},
{
"id": "85378aaf.6a53e8",
"type": "ui_text",
"z": "7f6c67de.46317",
"group": "ae53f947.6d7ae8",
"order": 3,
"width": "1",
"height": "1",
"name": "",
"label": "",
"format": "{{msg.payload}}",
"layout": "row-spread",
"x": 970,
"y": 420,
"wires":
},
{
"id": "856c61d2.cd14c8",
"type": "ui_text",
"z": "7f6c67de.46317",
"group": "ae53f947.6d7ae8",
"order": 5,
"width": "1",
"height": "1",
"name": "",
"label": "",
"format": "{{msg.payload}}",
"layout": "row-spread",
"x": 970,
"y": 460,
"wires":
},
{
"id": "b59dea49.d0d7e8",
"type": "debug",
"z": "7f6c67de.46317",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"x": 290,
"y": 80,
"wires":
},
{
"id": "15900e08.1c9ea2",
"type": "pushover",
"z": "7f6c67de.46317",
"name": "Temperaturwarnung",
"device": "",
"title": "",
"priority": 0,
"sound": "",
"url": "",
"url_title": "",
"html": false,
"x": 1080,
"y": 180,
"wires":
},
{
"id": "4c4ad82f.f54c68",
"type": "rbe",
"z": "7f6c67de.46317",
"name": "",
"func": "rbe",
"gap": "",
"start": "",
"inout": "out",
"property": "payload",
"x": 580,
"y": 60,
"wires": [
]
},
{
"id": "f43614e9.3a0728",
"type": "mqtt in",
"z": "7f6c67de.46317",
"name": "",
"topic": "",
"qos": "2",
"datatype": "auto",
"x": 80,
"y": 180,
"wires": [
[
"37a66629.28430a"
]
]
},
{
"id": "834de424.aa51c8",
"type": "ui_group",
"name": "Temperatur",
"tab": "1c35aa81.8b6a65",
"order": 2,
"disp": true,
"width": "6",
"collapse": false
},
{
"id": "ae53f947.6d7ae8",
"type": "ui_group",
"name": "Humidity",
"tab": "1c35aa81.8b6a65",
"order": 3,
"disp": true,
"width": "6",
"collapse": false
},
{
"id": "1c35aa81.8b6a65",
"type": "ui_tab",
"name": "Day20",
"icon": "dashboard",
"order": 15
}
]
Hier habe ich es erst mal mit einem Bme 280 und ein Heltec Cubecell Board probiert. Daten kommen von TTN.
Das läuft alles.
Ich möchte auf dieser Basis, das jetzt die Temperaturveränderung zwischen den einzelnen Messungen gemessen wird.(Alternativ Wasserstand,Luftfeuchtigkeit,Geschwindigkeit....)
Es soll jetzt angezeigt werden, wieviel Grad ist der Wert zwischen der jetzigen und der letzten Meldung gestiegen/gesenkt hat.
Ich versuche das mal anhand eines Autotachos zu beschreiben:
Im aktuellen Flow wird gewarnt, wenn man zu langsam oder zu schnell fährt(einstellungen im Dashboard.
Jetzt möchte ich aber die Beschleunigung/Verzögerung messen. Wird zuviel "Gas" gegeben Alarm.
Alle 1 Sekunde soll gemessen werden(Warnwert s.B. 1 km/h)....Letzter Wert 50 km/h ...jetzt 50,5 km/h---> keine Warnung ab 51 km/h soll dan gewarnt werden.
Wie kann da so ein Flow ausehen?
LG