[
{
"id": "016eb2c081373f51",
"type": "tab",
"label": "Flow 3",
"disabled": false,
"info": "",
"env": []
},
{
"id": "c39ad4c34007e8b9",
"type": "inject",
"z": "016eb2c081373f51",
"name": "meteo courante",
"props": [
{
"p": "payload"
}
],
"repeat": "180",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "true",
"payloadType": "bool",
"x": 90,
"y": 20,
"wires": [
[
"4c448ed4c64a6ce3"
]
]
},
{
"id": "4c448ed4c64a6ce3",
"type": "pws-observations",
"z": "016eb2c081373f51",
"name": "Weather",
"stationid": "IPUCEU1",
"units": "m",
"apikey": "0c25d0e62f427f92",
"x": 260,
"y": 20,
"wires": [
[
"46abe7e7e0802ce4",
"5494310f7054c656"
]
]
},
{
"id": "f26d974a891612a6",
"type": "mqtt out",
"z": "016eb2c081373f51",
"name": "mqtt:station",
"topic": "gladys/device/mqtt:station/feature/mqtt:meteo/state",
"qos": "2",
"retain": "",
"respTopic": "",
"contentType": "",
"userProps": "",
"correl": "",
"expiry": "",
"broker": "b19483b9a24a3874",
"x": 370,
"y": 120,
"wires": []
},
{
"id": "46abe7e7e0802ce4",
"type": "debug",
"z": "016eb2c081373f51",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 430,
"y": 80,
"wires": []
},
{
"id": "7b61bd6495dc3004",
"type": "ui_text",
"z": "016eb2c081373f51",
"group": "58b1939d3a5a9ac4",
"order": 3,
"width": 0,
"height": 0,
"name": "",
"label": "Temp :",
"format": "{{value}}",
"layout": "row-spread",
"className": "",
"x": 370,
"y": 160,
"wires": []
},
{
"id": "62bc4033a584587b",
"type": "function",
"z": "016eb2c081373f51",
"name": "temperature",
"func": "msg.payload=msg.payload.observations[0].metric.temp;\n//msg.payload=temper;\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 90,
"y": 160,
"wires": [
[
"93fdf8c678765f85",
"7b61bd6495dc3004",
"c43475ebeae26f8e"
]
]
},
{
"id": "5494310f7054c656",
"type": "json",
"z": "016eb2c081373f51",
"name": "",
"property": "payload",
"action": "obj",
"pretty": false,
"x": 90,
"y": 80,
"wires": [
[
"f26d974a891612a6",
"94df99c94ec5445a",
"7056f74a4fb4702c",
"1bf4900ef12e645c",
"941aa23b97daf6d2",
"62bc4033a584587b",
"e856a8e2a90a7355"
]
]
},
{
"id": "94df99c94ec5445a",
"type": "function",
"z": "016eb2c081373f51",
"name": "humidite",
"func": "var humid=msg.payload.observations[0].humidity;\nmsg.payload=humid;\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 80,
"y": 260,
"wires": [
[
"4644a48691675823"
]
]
},
{
"id": "4644a48691675823",
"type": "ui_gauge",
"z": "016eb2c081373f51",
"name": "",
"group": "58b1939d3a5a9ac4",
"order": 7,
"width": 0,
"height": 0,
"gtype": "gage",
"title": "Humidité",
"label": "%",
"format": "{{value}}",
"min": 0,
"max": "100",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"className": "",
"x": 380,
"y": 260,
"wires": []
},
{
"id": "93fdf8c678765f85",
"type": "ui_gauge",
"z": "016eb2c081373f51",
"name": "",
"group": "58b1939d3a5a9ac4",
"order": 2,
"width": 0,
"height": 0,
"gtype": "gage",
"title": "Temperature",
"label": "°C",
"format": "{{value}}",
"min": "-20",
"max": "50",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"className": "",
"x": 390,
"y": 200,
"wires": []
},
{
"id": "7056f74a4fb4702c",
"type": "function",
"z": "016eb2c081373f51",
"name": "pluie",
"func": "var pluie=msg.payload.observations[0].metric.precipRate;\nmsg.payload=pluie;\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 70,
"y": 320,
"wires": [
[
"0ca257b3fe7bb104"
]
]
},
{
"id": "0ca257b3fe7bb104",
"type": "ui_gauge",
"z": "016eb2c081373f51",
"name": "",
"group": "58b1939d3a5a9ac4",
"order": 4,
"width": 0,
"height": 0,
"gtype": "gage",
"title": "Précipitation",
"label": "mm",
"format": "{{value}}",
"min": 0,
"max": "500",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"className": "",
"x": 390,
"y": 320,
"wires": []
},
{
"id": "1bf4900ef12e645c",
"type": "function",
"z": "016eb2c081373f51",
"name": "vent",
"func": "\nvar wind=msg.payload.observations[0].winddir;\nmsg.payload=wind;\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 70,
"y": 380,
"wires": [
[
"1233944667394c99"
]
]
},
{
"id": "1233944667394c99",
"type": "ui_gauge",
"z": "016eb2c081373f51",
"name": "",
"group": "58b1939d3a5a9ac4",
"order": 6,
"width": 0,
"height": 0,
"gtype": "compass",
"title": "vent",
"label": "°",
"format": "{{value}}",
"min": 0,
"max": "360",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"className": "",
"x": 370,
"y": 380,
"wires": []
},
{
"id": "941aa23b97daf6d2",
"type": "function",
"z": "016eb2c081373f51",
"name": "date",
"func": "var periode=msg.payload.observations[0].obsTimeLocal;\nvar date=periode.split(\" \")[0];\nvar heure=periode.split(\" \")[1];\nvar msg1={};\nvar msg2={};\n//var out ={\"Date\" : date, \"Heure\": heure};\nmsg.payload=\"Le \" + date + \" à \"+ heure;\n//msg1.payload=out;\n\n\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 70,
"y": 440,
"wires": [
[
"4f581218cd160db3"
]
]
},
{
"id": "4f581218cd160db3",
"type": "ui_text",
"z": "016eb2c081373f51",
"group": "58b1939d3a5a9ac4",
"order": 1,
"width": 0,
"height": 0,
"name": "",
"label": "",
"format": "{{value}}",
"layout": "row-spread",
"className": "",
"x": 370,
"y": 440,
"wires": []
},
{
"id": "e856a8e2a90a7355",
"type": "function",
"z": "016eb2c081373f51",
"name": "pression",
"func": "var press=msg.payload.observations[0].metric.pressure;\nmsg.payload=press;\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 80,
"y": 500,
"wires": [
[
"542efb7e296e6737"
]
]
},
{
"id": "542efb7e296e6737",
"type": "ui_gauge",
"z": "016eb2c081373f51",
"name": "",
"group": "58b1939d3a5a9ac4",
"order": 5,
"width": 0,
"height": 0,
"gtype": "compass",
"title": "Pression",
"label": "mBar",
"format": "{{value}}",
"min": 0,
"max": "2000",
"colors": [
"#00b500",
"#e6e600",
"#ca3838"
],
"seg1": "",
"seg2": "",
"className": "",
"x": 380,
"y": 500,
"wires": []
},
{
"id": "c43475ebeae26f8e",
"type": "mqtt out",
"z": "016eb2c081373f51",
"name": "mqtt:station",
"topic": "gladys/device/mqtt:station/feature/mqtt:temp/state",
"qos": "2",
"retain": "",
"respTopic": "",
"contentType": "",
"userProps": "",
"correl": "",
"expiry": "",
"broker": "b19483b9a24a3874",
"x": 230,
"y": 220,
"wires": []
},
{
"id": "0c25d0e62f427f92",
"type": "pwsapikey",
"name": ""
},
{
"id": "b19483b9a24a3874",
"type": "mqtt-broker",
"name": "",
"broker": "mqtt://localhost",
"port": "1883",
"clientid": "mqtt:station",
"autoConnect": true,
"usetls": false,
"protocolVersion": "4",
"keepalive": "90",
"cleansession": false,
"birthTopic": "",
"birthQos": "2",
"birthPayload": "",
"birthMsg": {},
"closeTopic": "",
"closeQos": "0",
"closePayload": "",
"closeMsg": {},
"willTopic": "",
"willQos": "2",
"willPayload": "",
"willMsg": {},
"sessionExpiry": ""
},
{
"id": "58b1939d3a5a9ac4",
"type": "ui_group",
"name": "Meteo",
"tab": "8cf38833f27eea20",
"order": 1,
"disp": true,
"width": "6",
"collapse": false,
"className": ""
},
{
"id": "8cf38833f27eea20",
"type": "ui_tab",
"name": "Station",
"icon": "dashboard",
"disabled": false,
"hidden": false
}
]