I created a Node Red Dashboard, which is shown on an iPad mini (1st generation) to control smart things in my home.

I will create some blogs where I explain how I made some blocks. The links can be found below:

  • https://www.fastkids.nl/node-red/clock-on-node-red-dashboard/

The complete source code can be found here (tokens are changed for security reasons)

[{"id":"783c70d8.6ab84","type":"tab","label":"Overicht pagina","disabled":false,"info":""},{"id":"c6c7c18c.c0542","type":"tab","label":"Lampen / Schakelaars","disabled":false,"info":""},{"id":"ce311d23.96814","type":"tab","label":"Batterij nivo","disabled":false,"info":""},{"id":"4edf3a72.7283e4","type":"ui_tab","z":"","name":"Home","icon":"dashboard","disabled":false,"hidden":false},{"id":"a8ed9b6.b3b9d68","type":"ui_group","z":"","name":"Beweging","tab":"4edf3a72.7283e4","order":6,"disp":true,"width":"3","collapse":false},{"id":"fb88020f.b292f","type":"hue-bridge","z":"","name":"Philips hue","bridge":"192.168.10.51","key":"ownkeyinserthere","interval":"3000","disableupdates":false},{"id":"996e522a.3c291","type":"ui_group","z":"","name":"Lampen / Schakelaars Woonkamer","tab":"afed8a0.cec4578","order":4,"disp":true,"width":"8","collapse":false},{"id":"82005cce.d8aff","type":"ui_group","z":"","name":"temperatuur","tab":"4edf3a72.7283e4","order":3,"disp":false,"width":"6","collapse":false},{"id":"8334409a.85a43","type":"ui_base","theme":{"name":"theme-custom","lightTheme":{"default":"#0094CE","baseColor":"#0094CE","baseFont":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif","edited":true,"reset":false},"darkTheme":{"default":"#097479","baseColor":"#bc4eef","baseFont":"Copperplate,Copperplate Gothic Light,fantasy","edited":true,"reset":false},"customTheme":{"name":"MR","default":"#4B7930","baseColor":"#8a3d79","baseFont":"Tahoma,Geneva,sans-serif","reset":false},"themeState":{"base-color":{"default":"#4B7930","value":"#8a3d79","edited":true},"page-titlebar-backgroundColor":{"value":"#8a3d79","edited":false},"page-backgroundColor":{"value":"#000000","edited":true},"page-sidebar-backgroundColor":{"value":"#3a313a","edited":true},"group-textColor":{"value":"#b75ca3","edited":false},"group-borderColor":{"value":"#555555","edited":false},"group-backgroundColor":{"value":"#121212","edited":true},"widget-textColor":{"value":"#eeeeee","edited":false},"widget-backgroundColor":{"value":"#8a3d79","edited":false},"widget-borderColor":{"value":"#121212","edited":true},"base-font":{"value":"Tahoma,Geneva,sans-serif"}},"angularTheme":{"primary":"indigo","accents":"blue","warn":"red","background":"grey"}},"site":{"name":"MR","hideToolbar":"true","allowSwipe":"true","lockMenu":"false","allowTempTheme":"true","dateFormat":"DD/MM/YYYY","sizes":{"sx":48,"sy":48,"gx":6,"gy":6,"cx":6,"cy":6,"px":0,"py":0}}},{"id":"9303c1d4.522ba","type":"ui_group","z":"","name":"Power consumption","tab":"4edf3a72.7283e4","order":7,"disp":false,"width":"5","collapse":false},{"id":"877eec72.9fa84","type":"ui_group","z":"","name":"Buienradar","tab":"4edf3a72.7283e4","order":1,"disp":false,"width":"6","collapse":false},{"id":"3be95e87.d97972","type":"miio-roborock-server","z":"","name":"Stoffertje 2.0","ip":"192.168.10.113","token":"Owntokenhere","polling":"10"},{"id":"fbe29703.317a48","type":"mqtt-broker","z":"","name":"myhomey","broker":"192.168.10.72","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""},{"id":"31dcf84.ea6c308","type":"ui_group","z":"","name":"Deuren / Ramen","tab":"4edf3a72.7283e4","order":5,"disp":true,"width":"4","collapse":false},{"id":"2f89a4b7.276aac","type":"ui_group","z":"","name":"Battery levels","tab":"afed8a0.cec4578","order":1,"disp":true,"width":"15","collapse":false},{"id":"afed8a0.cec4578","type":"ui_tab","z":"","name":"Lampen / Schakelaars","icon":"dashboard","order":2,"disabled":false,"hidden":false},{"id":"b8f6527b.8eefa","type":"ui_group","z":"","name":"Lampen / Schakelaars Tuin","tab":"afed8a0.cec4578","order":2,"disp":true,"width":"4","collapse":false},{"id":"a052d8d6.1a3c28","type":"ui_group","z":"","name":"Lampen / Schakelaars Keuken","tab":"afed8a0.cec4578","order":3,"disp":true,"width":"4","collapse":false},{"id":"48c5dcec.17d584","type":"ui_group","z":"","name":"Verlichting","tab":"4edf3a72.7283e4","order":2,"disp":true,"width":"6","collapse":false},{"id":"750b4872.f23ba8","type":"ui_group","z":"","name":"Diversen","tab":"4edf3a72.7283e4","order":4,"disp":false,"width":"6","collapse":false},{"id":"36361ac5.fc33b6","type":"ui_group","z":"","name":"Aanwezigheid","tab":"4edf3a72.7283e4","order":8,"disp":false,"width":"6","collapse":false},{"id":"40b5da16.fe31e4","type":"ui_group","z":"","name":"Alarm","tab":"4edf3a72.7283e4","order":9,"disp":false,"width":"7","collapse":false},{"id":"f1ef0372.e49cc","type":"ui_group","z":"","name":"Secure","tab":"","order":1,"disp":true,"width":"6"},{"id":"cd180695.c87a78","type":"ui_group","z":"","name":"pin","tab":"","order":2,"disp":false,"width":"1"},{"id":"ed1361ba.9f185","type":"ui_group","z":"","name":"Secure","tab":"4edf3a72.7283e4","order":10,"disp":true,"width":"6"},{"id":"b19f8a15.795c48","type":"ui_group","z":"","name":"pin","tab":"4edf3a72.7283e4","order":11,"disp":false,"width":"1"},{"id":"91690b3e.18d438","type":"hue-temperature","z":"783c70d8.6ab84","name":"Hue outdoor temp. sensor 1","bridge":"fb88020f.b292f","sensorid":"76","skipevents":false,"x":203.5,"y":165,"wires":[["f47159c7.93c348"]]},{"id":"1b078aaf.6f5be5","type":"hue-temperature","z":"783c70d8.6ab84","name":"Hue temperature sensor 2","bridge":"fb88020f.b292f","sensorid":"24","skipevents":false,"x":210.5,"y":39,"wires":[["4c74f597.b3c01c"]]},{"id":"31b4b0ba.3bc98","type":"ui_gauge","z":"783c70d8.6ab84","name":"","group":"82005cce.d8aff","order":1,"width":"4","height":"4","gtype":"gage","title":"Binnen temperatuur","label":"graden celsius","format":"{{msg.payload}}","min":0,"max":"50","colors":["#00b500","#e6e600","#ca3838"],"seg1":"23","seg2":"27","x":706.5,"y":43,"wires":[]},{"id":"fb707090.8a70d","type":"hue-temperature","z":"783c70d8.6ab84","name":"Hue temperature sensor 1","bridge":"fb88020f.b292f","sensorid":"2","skipevents":false,"x":1010.5,"y":24,"wires":[["6f4efe8b.f22a7"]]},{"id":"af281a3f.986b98","type":"youless","z":"783c70d8.6ab84","name":"Youless","ipaddress":"192.168.10.68","topic":"pwr","password":"","x":200,"y":522,"wires":[["3dc273d1.03dc5c"]]},{"id":"cae90ff0.bba0f","type":"ui_gauge","z":"783c70d8.6ab84","name":"Power consumption","group":"9303c1d4.522ba","order":1,"width":"5","height":"2","gtype":"gage","title":"Energie-verbruik","label":"watt","format":"{{msg.payload}}","min":0,"max":"6000","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":536.5,"y":522,"wires":[]},{"id":"24dca980.f95c76","type":"buienradar","z":"783c70d8.6ab84","name":"Buienradar","station":"6375","interval":"60000","forecast":true,"x":95,"y":897,"wires":[["eb7f293.631d7d8"]]},{"id":"eb7f293.631d7d8","type":"function","z":"783c70d8.6ab84","name":"buienradar","func":"var temp = msg.payload.buienradar.temperatuurGC;\nvar hum = msg.payload.buienradar.luchtvochtigheid;\nvar tekst = msg.payload.buienradar.icoonzin;\nvar regen = msg.payload.buienradar.regenMM24U;\nvar druk =  msg.payload.buienradar.luchtdruk;\nreturn[{payload:temp},{payload:hum},{payload:tekst}, {payload:regen}, {payload:druk}]","outputs":5,"noerr":0,"x":270,"y":897,"wires":[["ac939d8.3dc506"],["5c599695.350d48"],["252057c5.46e678"],["9cc495f9.66ecf8"],["1a1173d4.07008c"]]},{"id":"ac939d8.3dc506","type":"ui_gauge","z":"783c70d8.6ab84","name":"","group":"877eec72.9fa84","order":3,"width":"4","height":"3","gtype":"gage","title":"Weerstation","label":"graden celsius","format":"{{msg.payload}}","min":"-20","max":"50","colors":["#009eb3","#e6e600","#ca3838"],"seg1":"","seg2":"","x":457.5,"y":826,"wires":[]},{"id":"5c599695.350d48","type":"ui_gauge","z":"783c70d8.6ab84","name":"","group":"877eec72.9fa84","order":4,"width":"2","height":"2","gtype":"donut","title":"Luchtvochtigheid","label":"%","format":"{{msg.payload}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":480.5,"y":862,"wires":[]},{"id":"252057c5.46e678","type":"ui_text","z":"783c70d8.6ab84","group":"877eec72.9fa84","order":7,"width":"6","height":"1","name":"","label":"","format":"<font size=1>{{msg.payload}}</font>","layout":"row-left","x":440.5,"y":899,"wires":[]},{"id":"3dc273d1.03dc5c","type":"function","z":"783c70d8.6ab84","name":"reschrijf","func":"if (msg.topic === \"pwr\") {\nreturn msg; }","outputs":1,"noerr":0,"x":358,"y":523,"wires":[["cae90ff0.bba0f","17a11df.4485ce2"]]},{"id":"7d1fc39e.9ce44c","type":"inject","z":"783c70d8.6ab84","name":"timer","topic":"","payload":"","payloadType":"date","repeat":"3","crontab":"","once":false,"onceDelay":0.1,"x":89.5,"y":476,"wires":[["af281a3f.986b98"]]},{"id":"afdd7d1d.1521c","type":"inject","z":"783c70d8.6ab84","name":"timer","topic":"","payload":"","payloadType":"date","repeat":"600","crontab":"","once":false,"onceDelay":0.1,"x":96,"y":974,"wires":[["2c9fb68c.8690ba"]]},{"id":"da7a754d.7f8918","type":"ui_text","z":"783c70d8.6ab84","group":"750b4872.f23ba8","order":5,"width":"6","height":"1","name":"","label":"Download speed:","format":"{{payload.speeds.download}} MB/s","layout":"row-spread","x":415.5,"y":1018,"wires":[]},{"id":"b93604fb.f3cd98","type":"ui_text","z":"783c70d8.6ab84","group":"750b4872.f23ba8","order":6,"width":"6","height":"1","name":"","label":"Upload speed:","format":"{{payload.speeds.upload}} MB/s","layout":"row-spread","x":412.5,"y":1056,"wires":[]},{"id":"17a11df.4485ce2","type":"ui_chart","z":"783c70d8.6ab84","name":"","group":"9303c1d4.522ba","order":2,"width":"5","height":"3","label":"","chartType":"line","legend":"false","xformat":"HH:mm:ss","interpolate":"linear","nodata":"","dot":false,"ymin":"0","ymax":"6000","removeOlder":"15","removeOlderPoints":"","removeOlderUnit":"60","cutout":0,"useOneColor":false,"useUTC":false,"colors":["#1f77b4","#aec7e8","#ff7f0e","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5"],"useOldStyle":false,"outputs":1,"x":501.5,"y":572,"wires":[[]]},{"id":"bd846172.b992d","type":"miio-roborock-event","z":"783c70d8.6ab84","name":"status","server":"3be95e87.d97972","outputAtStartup":true,"x":134.5,"y":765,"wires":[["b17f4799.486658","6f1d75b5.c291bc"]]},{"id":"b17f4799.486658","type":"ui_text","z":"783c70d8.6ab84","group":"750b4872.f23ba8","order":3,"width":"3","height":"2","name":"","label":"Stoffertje:","format":"{{msg.status.state_text}}","layout":"col-center","x":343.5,"y":755,"wires":[]},{"id":"6f1d75b5.c291bc","type":"ui_gauge","z":"783c70d8.6ab84","name":"","group":"750b4872.f23ba8","order":4,"width":"3","height":"2","gtype":"donut","title":"Battery level","label":"%","format":"{{msg.status.battery}}","min":0,"max":"100","colors":["#b30000","#e6e600","#2bff00"],"seg1":"","seg2":"","x":354.5,"y":792,"wires":[]},{"id":"6ad575a1.a1072c","type":"mqtt in","z":"783c70d8.6ab84","name":"trap motion","topic":"homie/homey-mr/sensortrapbeneden/alarm-motion","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":137.5,"y":1174,"wires":[["f3ff0c86.0d0d6"]]},{"id":"9e0b19c2.557f68","type":"mqtt in","z":"783c70d8.6ab84","name":"trap motion","topic":"homie/homey-mr/sensortrapboven/alarm-motion","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":134,"y":1259,"wires":[["9d30a58e.8d2508"]]},{"id":"a5b8923e.97cd5","type":"mqtt in","z":"783c70d8.6ab84","name":"buiten motion","topic":"homie/homey-mr/buitensensorhue/alarm-motion","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":144,"y":1331,"wires":[["aa6ac9d2.ba6dc8"]]},{"id":"f4770542.291ed8","type":"mqtt in","z":"783c70d8.6ab84","name":"kamerdeur","topic":"homie/homey-mr/kamerdeursensor/alarm-contact","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":141,"y":1412,"wires":[["253ec189.b320ce"]]},{"id":"21d3c728.ec7fa8","type":"mqtt in","z":"783c70d8.6ab84","name":"keukendeur","topic":"homie/homey-mr/achterdeursensor/alarm-contact","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":156,"y":1495.5,"wires":[["34169ee0.942512"]]},{"id":"ba8b5810.fe3578","type":"mqtt in","z":"783c70d8.6ab84","name":"Garagedeur","topic":"homie/homey-mr/garagedeur/alarm-contact","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":160,"y":1546.5,"wires":[["584fa214.e3dd5c"]]},{"id":"64b7cd21.47b224","type":"ui_text","z":"783c70d8.6ab84","group":"31dcf84.ea6c308","order":3,"width":"2","height":"1","name":"","label":"Garagedeur","format":"{{msg.payload}}","layout":"col-center","x":514,"y":1547,"wires":[]},{"id":"584fa214.e3dd5c","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-lock fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-unlock fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":347,"y":1548,"wires":[["64b7cd21.47b224"]]},{"id":"c92854e1.7b3c78","type":"ui_text","z":"783c70d8.6ab84","group":"31dcf84.ea6c308","order":3,"width":"2","height":"1","name":"","label":"Keukendeur","format":"{{msg.payload}}","layout":"col-center","x":510,"y":1470,"wires":[]},{"id":"ea3eda08.271e18","type":"ui_text","z":"783c70d8.6ab84","group":"31dcf84.ea6c308","order":3,"width":"2","height":"1","name":"","label":"Kamerdeur","format":"{{msg.payload}}","layout":"col-center","x":505,"y":1411,"wires":[]},{"id":"253ec189.b320ce","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-lock fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-unlock fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":319,"y":1411,"wires":[["ea3eda08.271e18"]]},{"id":"34169ee0.942512","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-lock fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-unlock fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":331,"y":1483,"wires":[["c92854e1.7b3c78"]]},{"id":"4ffa071e.f4b288","type":"mqtt in","z":"783c70d8.6ab84","name":"huiskamer sensor","topic":"homie/homey-mr/huiskamersensor/measure-temperature","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":147,"y":94,"wires":[["31b4b0ba.3bc98"]]},{"id":"dd01d0e5.4b7b6","type":"mqtt in","z":"783c70d8.6ab84","name":"huiskamer sensor","topic":"homie/homey-mr/huiskamersensor/measure-humidity","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":491,"y":147,"wires":[["6c6c31d0.3231c"]]},{"id":"6c6c31d0.3231c","type":"ui_gauge","z":"783c70d8.6ab84","name":"","group":"82005cce.d8aff","order":2,"width":"2","height":"2","gtype":"donut","title":"Luchtvochtigheid","label":"%","format":"{{msg.payload}}","min":0,"max":"100","colors":["#00b500","#e6e600","#ca3838"],"seg1":"","seg2":"","x":711,"y":148,"wires":[]},{"id":"2c9fb68c.8690ba","type":"speedtest","z":"783c70d8.6ab84","name":"","maxTime":"50000","x":215,"y":1031,"wires":[["da7a754d.7f8918","b93604fb.f3cd98"]]},{"id":"7b9b4401.38e35c","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":686,"y":78,"wires":[["9f85a2c6.9a2b3"]]},{"id":"870240c1.65069","type":"hue-light","z":"c6c7c18c.c0542","name":"Erker spot links","bridge":"fb88020f.b292f","lightid":"13","colornamer":true,"skipevents":false,"x":388.5,"y":120,"wires":[["7b9b4401.38e35c"]]},{"id":"9f85a2c6.9a2b3","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Erker spot links","tooltip":"","group":"996e522a.3c291","order":1,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":157.5,"y":123,"wires":[["870240c1.65069"]]},{"id":"5e9c1e8c.d945b","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":683.5,"y":120,"wires":[["46b93a67.590254"]]},{"id":"2b6ac3d5.bad33c","type":"hue-light","z":"c6c7c18c.c0542","name":"Erker spot midden","bridge":"fb88020f.b292f","lightid":"14","colornamer":true,"skipevents":false,"x":396,"y":166,"wires":[["5e9c1e8c.d945b"]]},{"id":"46b93a67.590254","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Erker spot midden","tooltip":"","group":"996e522a.3c291","order":2,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":164,"y":173,"wires":[["2b6ac3d5.bad33c"]]},{"id":"4d8cf841.70e118","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":684.5,"y":166,"wires":[["4984665c.526ba8"]]},{"id":"ce7d998a.c23ea8","type":"hue-light","z":"c6c7c18c.c0542","name":"Erker spot rechts","bridge":"fb88020f.b292f","lightid":"15","colornamer":true,"skipevents":false,"x":396,"y":213,"wires":[["4d8cf841.70e118"]]},{"id":"4984665c.526ba8","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Erker spot rechts","tooltip":"","group":"996e522a.3c291","order":3,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":163,"y":220,"wires":[["ce7d998a.c23ea8"]]},{"id":"f0cd08ef.f17eb8","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":688.5,"y":211,"wires":[["7e62a387.3d7d6c"]]},{"id":"4df205ea.287d7c","type":"hue-light","z":"c6c7c18c.c0542","name":"Erker links","bridge":"fb88020f.b292f","lightid":"17","colornamer":true,"skipevents":false,"x":379,"y":260,"wires":[["f0cd08ef.f17eb8"]]},{"id":"7e62a387.3d7d6c","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Erker links","tooltip":"","group":"996e522a.3c291","order":4,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":146,"y":268,"wires":[["4df205ea.287d7c"]]},{"id":"320e8204.0a6cee","type":"hue-light","z":"c6c7c18c.c0542","name":"Erker rechts","bridge":"fb88020f.b292f","lightid":"10","colornamer":true,"skipevents":false,"x":360,"y":335,"wires":[["be1a165e.2b4bf8"]]},{"id":"88c6b589.cc9da8","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Erker rechts","tooltip":"","group":"996e522a.3c291","order":5,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":149,"y":336,"wires":[["320e8204.0a6cee"]]},{"id":"cf6340eb.86f1","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":607.5,"y":326,"wires":[["39082521.4de63a"]]},{"id":"66284643.b4f938","type":"hue-light","z":"c6c7c18c.c0542","name":"Kamer achter","bridge":"fb88020f.b292f","lightid":"23","colornamer":true,"skipevents":false,"x":371,"y":387,"wires":[["cf6340eb.86f1"]]},{"id":"39082521.4de63a","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Kamer achter","tooltip":"","group":"996e522a.3c291","order":6,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":160,"y":388,"wires":[["66284643.b4f938"]]},{"id":"368250d4.0db6","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":614.5,"y":376,"wires":[["83def898.9845e8"]]},{"id":"f952dded.b80cc","type":"hue-light","z":"c6c7c18c.c0542","name":"Kast kamer","bridge":"fb88020f.b292f","lightid":"34","colornamer":true,"skipevents":false,"x":368,"y":437,"wires":[["368250d4.0db6"]]},{"id":"83def898.9845e8","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Kast kamer","tooltip":"","group":"996e522a.3c291","order":7,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":157,"y":438,"wires":[["f952dded.b80cc"]]},{"id":"436e7e74.815e4","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":614.5,"y":424,"wires":[["6a8caa74.950384"]]},{"id":"101d35a2.4b88ca","type":"hue-light","z":"c6c7c18c.c0542","name":"Erker rechts","bridge":"fb88020f.b292f","lightid":"10","colornamer":true,"skipevents":false,"x":368,"y":485,"wires":[["436e7e74.815e4"]]},{"id":"6a8caa74.950384","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Erker rechts","tooltip":"","group":"996e522a.3c291","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":157,"y":486,"wires":[["101d35a2.4b88ca"]]},{"id":"8704ce6.bb6c73","type":"mqtt in","z":"c6c7c18c.c0542","name":"Staande Lamp","topic":"homie/homey-mr/staandelamp/onoff","qos":"2","datatype":"utf8","broker":"fbe29703.317a48","x":167.5,"y":535,"wires":[["2c11c29e.ae191e"]]},{"id":"2c11c29e.ae191e","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Staande lamp","tooltip":"","group":"996e522a.3c291","order":9,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"str","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"str","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":394.5,"y":537,"wires":[["993d286d.48e8d8"]]},{"id":"df630ff6.25c45","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"TV strip","tooltip":"","group":"996e522a.3c291","order":10,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":172.5,"y":607,"wires":[["b4282a8f.0114a8"]]},{"id":"b4282a8f.0114a8","type":"hue-light","z":"c6c7c18c.c0542","name":"Achter tv strip","bridge":"fb88020f.b292f","lightid":"22","colornamer":true,"skipevents":false,"x":403.5,"y":606,"wires":[["52eb6473.edfd9c"]]},{"id":"52eb6473.edfd9c","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":640,"y":545,"wires":[["df630ff6.25c45"]]},{"id":"1bdd2274.7b490e","type":"mqtt in","z":"c6c7c18c.c0542","name":"fontein","topic":"homie/homey-mr/fontein/onoff","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":168.5,"y":670,"wires":[["a69fa9a5.bba378"]]},{"id":"a69fa9a5.bba378","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Fontein","tooltip":"","group":"b8f6527b.8eefa","order":13,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"str","onicon":"fa-shower fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"str","officon":"fa-shower fa-2x","offcolor":"grey","x":347.5,"y":668,"wires":[["9d3c56a.184c9a8"]]},{"id":"9d3c56a.184c9a8","type":"mqtt out","z":"c6c7c18c.c0542","name":"","topic":"homie/homey-mr/fontein/onoff/set","qos":"0","retain":"false","broker":"fbe29703.317a48","x":609.5,"y":649,"wires":[]},{"id":"993d286d.48e8d8","type":"mqtt out","z":"c6c7c18c.c0542","name":"","topic":"homie/homey-mr/staandelamp/onoff/set","qos":"","retain":"","broker":"fbe29703.317a48","x":645.5,"y":496,"wires":[]},{"id":"be1a165e.2b4bf8","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":606.5,"y":274,"wires":[["88c6b589.cc9da8"]]},{"id":"ee80fb9d.ec8bf8","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 1","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":181,"y":945,"wires":[["859510cf.c4dff"]]},{"id":"859510cf.c4dff","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-01","bridge":"fb88020f.b292f","lightid":"25","colornamer":true,"skipevents":false,"x":379,"y":942,"wires":[["47527e59.47eec"]]},{"id":"47527e59.47eec","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":581.5,"y":893,"wires":[["ee80fb9d.ec8bf8"]]},{"id":"a62fd03d.be343","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 2","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":189,"y":998,"wires":[["381365e3.fc0cba"]]},{"id":"381365e3.fc0cba","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-02","bridge":"fb88020f.b292f","lightid":"26","colornamer":true,"skipevents":false,"x":387,"y":995,"wires":[["6b6987eb.3f90b8"]]},{"id":"6b6987eb.3f90b8","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":589.5,"y":946,"wires":[["a62fd03d.be343"]]},{"id":"65bef757.fe0768","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 3","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":184,"y":1048,"wires":[["e40d3f28.1a6eb"]]},{"id":"e40d3f28.1a6eb","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-03","bridge":"fb88020f.b292f","lightid":"27","colornamer":true,"skipevents":false,"x":382,"y":1045,"wires":[["56d4d5af.77e59c"]]},{"id":"56d4d5af.77e59c","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":584.5,"y":996,"wires":[["65bef757.fe0768"]]},{"id":"99826824.f69458","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 4","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":184,"y":1095,"wires":[["4edfcc15.bc37a4"]]},{"id":"4edfcc15.bc37a4","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-04","bridge":"fb88020f.b292f","lightid":"28","colornamer":true,"skipevents":false,"x":382,"y":1092,"wires":[["245c15e6.df58ba"]]},{"id":"245c15e6.df58ba","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":584.5,"y":1043,"wires":[["99826824.f69458"]]},{"id":"eab0a8c1.e11d18","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 5","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":188,"y":1144,"wires":[["810e2e77.7cd52"]]},{"id":"810e2e77.7cd52","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-05","bridge":"fb88020f.b292f","lightid":"29","colornamer":true,"skipevents":false,"x":386,"y":1141,"wires":[["881bb3c7.c1e56"]]},{"id":"881bb3c7.c1e56","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":588.5,"y":1092,"wires":[["eab0a8c1.e11d18"]]},{"id":"d837cd39.785a9","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 6","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":191,"y":1191,"wires":[["49a9b2ca.99278c"]]},{"id":"49a9b2ca.99278c","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-06","bridge":"fb88020f.b292f","lightid":"31","colornamer":true,"skipevents":false,"x":389,"y":1188,"wires":[["5ab46b96.fa0504"]]},{"id":"5ab46b96.fa0504","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":591.5,"y":1139,"wires":[["d837cd39.785a9"]]},{"id":"6c040daa.4d62e4","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 7","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":194,"y":1240,"wires":[["e85fa446.1764d8"]]},{"id":"e85fa446.1764d8","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-07","bridge":"fb88020f.b292f","lightid":"32","colornamer":true,"skipevents":false,"x":392,"y":1237,"wires":[["d49bf0a1.ab9ac"]]},{"id":"d49bf0a1.ab9ac","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":594.5,"y":1188,"wires":[["6c040daa.4d62e4"]]},{"id":"1e603e3f.7de852","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Keuken spot 8","tooltip":"","group":"a052d8d6.1a3c28","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":186,"y":1287,"wires":[["18ca9d95.0094c2"]]},{"id":"18ca9d95.0094c2","type":"hue-light","z":"c6c7c18c.c0542","name":"Keuken-08","bridge":"fb88020f.b292f","lightid":"33","colornamer":true,"skipevents":false,"x":384,"y":1284,"wires":[["607946ce.475318"]]},{"id":"607946ce.475318","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":586.5,"y":1235,"wires":[["1e603e3f.7de852"]]},{"id":"a11af7d2.6e4078","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Floodlight garage","tooltip":"","group":"b8f6527b.8eefa","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":202,"y":749,"wires":[["9eb909f6.61bf98"]]},{"id":"9eb909f6.61bf98","type":"hue-light","z":"c6c7c18c.c0542","name":"Garage floodlight","bridge":"fb88020f.b292f","lightid":"30","colornamer":true,"skipevents":false,"x":410,"y":746,"wires":[["f7012591.4e8758"]]},{"id":"f7012591.4e8758","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":635.5,"y":699,"wires":[["a11af7d2.6e4078"]]},{"id":"172891e0.c2d87e","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Buitenlamp poort","tooltip":"","group":"b8f6527b.8eefa","order":8,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"fa-lightbulb-o fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"bool","officon":"fa-lightbulb-o fa-2x","offcolor":"grey","x":207,"y":800,"wires":[["4dc9eef8.7b783"]]},{"id":"4dc9eef8.7b783","type":"hue-light","z":"c6c7c18c.c0542","name":"Buitenlamp poort","bridge":"fb88020f.b292f","lightid":"35","colornamer":true,"skipevents":false,"x":415,"y":797,"wires":[["25591d00.4b4444"]]},{"id":"25591d00.4b4444","type":"function","z":"c6c7c18c.c0542","name":"returnvalue onoff","func":"return { payload: msg.payload.on };","outputs":1,"noerr":0,"x":640.5,"y":750,"wires":[["172891e0.c2d87e"]]},{"id":"e09ac42d.b26708","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":1,"width":"6","height":"1","passthru":false,"label":"Alles uit","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"false","payloadType":"bool","topic":"","x":248,"y":224,"wires":[["9bf67b3.504e888","eb4a11a8.d9b4b","453e9dd0.1f16c4","29e239dc.c1b3d6","79654af8.2e2314","587b794.a9d3d88","7e5ba182.df0f1"]]},{"id":"999d6a0.ddcb898","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":3,"width":"3","height":"2","passthru":false,"label":"Woonkamer uit","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"false","payloadType":"bool","topic":"","x":212,"y":336,"wires":[["99ffe60e.a6c708","9bf67b3.504e888"]]},{"id":"99ffe60e.a6c708","type":"hue-group","z":"783c70d8.6ab84","name":"Huiskamer","bridge":"fb88020f.b292f","groupid":"1","colornamer":true,"skipevents":false,"x":365.5,"y":292.5,"wires":[[]]},{"id":"43961c21.532e44","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":2,"width":"3","height":"2","passthru":false,"label":"Woonkamer aan","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"true","payloadType":"bool","topic":"","x":237,"y":387,"wires":[["29e239dc.c1b3d6","9bf67b3.504e888"]]},{"id":"29e239dc.c1b3d6","type":"hue-group","z":"783c70d8.6ab84","name":"Huiskamer","bridge":"fb88020f.b292f","groupid":"1","colornamer":true,"skipevents":false,"x":390.5,"y":343.5,"wires":[[]]},{"id":"f6481771.23ba18","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":4,"width":"3","height":"2","passthru":false,"label":"Keuken aan","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"true","payloadType":"bool","topic":"","x":627,"y":305,"wires":[["79654af8.2e2314"]]},{"id":"79654af8.2e2314","type":"hue-group","z":"783c70d8.6ab84","name":"Keuken","bridge":"fb88020f.b292f","groupid":"16","colornamer":true,"skipevents":false,"x":780.5,"y":261.5,"wires":[[]]},{"id":"7cd875e8.6e075c","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":5,"width":"3","height":"2","passthru":false,"label":"Keuken uit","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"false","payloadType":"bool","topic":"","x":602,"y":254,"wires":[["6385accd.0d9c84"]]},{"id":"6385accd.0d9c84","type":"hue-group","z":"783c70d8.6ab84","name":"Keuken","bridge":"fb88020f.b292f","groupid":"16","colornamer":true,"skipevents":false,"x":755.5,"y":210.5,"wires":[[]]},{"id":"8e4c0380.f5e1e","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":6,"width":"3","height":"1","passthru":false,"label":"Tuin aan","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"true","payloadType":"bool","topic":"","x":681,"y":407,"wires":[["587b794.a9d3d88","453e9dd0.1f16c4"]]},{"id":"587b794.a9d3d88","type":"hue-group","z":"783c70d8.6ab84","name":"Tuin","bridge":"fb88020f.b292f","groupid":"17","colornamer":true,"skipevents":false,"x":804.5,"y":373.5,"wires":[[]]},{"id":"6265c1d3.f9fa8","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":7,"width":"3","height":"2","passthru":false,"label":"Tuin uit","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"false","payloadType":"bool","topic":"","x":626,"y":366,"wires":[["703dca30.4ee134","eb4a11a8.d9b4b","453e9dd0.1f16c4","7e5ba182.df0f1"]]},{"id":"703dca30.4ee134","type":"hue-group","z":"783c70d8.6ab84","name":"Tuin","bridge":"fb88020f.b292f","groupid":"17","colornamer":true,"skipevents":false,"x":779.5,"y":322.5,"wires":[[]]},{"id":"9bf67b3.504e888","type":"mqtt out","z":"783c70d8.6ab84","name":"","topic":"homie/homey-mr/staandelamp/onoff/set","qos":"","retain":"","broker":"fbe29703.317a48","x":397,"y":440,"wires":[]},{"id":"eb4a11a8.d9b4b","type":"mqtt out","z":"783c70d8.6ab84","name":"","topic":"homie/homey-mr/fontein/onoff/set","qos":"0","retain":"false","broker":"fbe29703.317a48","x":939,"y":446,"wires":[]},{"id":"3834e342.6951ac","type":"mqtt in","z":"c6c7c18c.c0542","name":"flamingo","topic":"homie/homey-mr/flamingo/onoff","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":705,"y":605,"wires":[["580bad17.9260e4"]]},{"id":"580bad17.9260e4","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Flamingo","tooltip":"","group":"b8f6527b.8eefa","order":13,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"str","onicon":"fa-check-square fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"str","officon":"fa-check-square fa-2x","offcolor":"grey","x":874,"y":603,"wires":[["c27be944.c6b248"]]},{"id":"c27be944.c6b248","type":"mqtt out","z":"c6c7c18c.c0542","name":"","topic":"homie/homey-mr/flamingo/onoff/set","qos":"","retain":"","broker":"fbe29703.317a48","x":1136,"y":584,"wires":[]},{"id":"453e9dd0.1f16c4","type":"mqtt out","z":"783c70d8.6ab84","name":"","topic":"homie/homey-mr/flamingo/onoff/set","qos":"","retain":"","broker":"fbe29703.317a48","x":1075,"y":400,"wires":[]},{"id":"ea009e2b.3ff76","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":9,"width":"6","height":"1","passthru":false,"label":"Alles aan","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"true","payloadType":"bool","topic":"","x":143,"y":277,"wires":[["99ffe60e.a6c708","9bf67b3.504e888","6385accd.0d9c84","703dca30.4ee134","453e9dd0.1f16c4","eb4a11a8.d9b4b","7e5ba182.df0f1"]]},{"id":"9cc495f9.66ecf8","type":"ui_text","z":"783c70d8.6ab84","group":"877eec72.9fa84","order":6,"width":"6","height":"1","name":"","label":"Verwachte regen:","format":"{{msg.payload}}mm","layout":"row-spread","x":481.5,"y":938,"wires":[]},{"id":"dd49ff65.d8295","type":"ui_text","z":"783c70d8.6ab84","group":"877eec72.9fa84","order":1,"width":"6","height":"1","name":"tijd","label":"","format":"<font size=8>{{msg.payload}}</font>","layout":"row-center","x":740.5,"y":703,"wires":[]},{"id":"4a1493e.f638d6c","type":"inject","z":"783c70d8.6ab84","name":"timer","topic":"","payload":"","payloadType":"date","repeat":"5","crontab":"","once":false,"onceDelay":0.1,"x":134,"y":620,"wires":[["6ce53c71.0f4b84"]]},{"id":"215ba70a.4c0dd8","type":"moment","z":"783c70d8.6ab84","name":"","topic":"","input":"payload","inputType":"msg","inTz":"ETC/GMT","adjAmount":"2","adjType":"hours","adjDir":"add","format":"","locale":"NL","output":"payload","outputType":"msg","outTz":"Europe/Amsterdam","x":334.5,"y":669,"wires":[["18b7580f.d8a258"]]},{"id":"6ce53c71.0f4b84","type":"function","z":"783c70d8.6ab84","name":"splitter date","func":"var date = new Date();\ndate = (date.getFullYear() + '-' + ('00' + (date.getMonth()+1)).slice(-2) + '-' + ('00' + date.getDate()).slice(-2) + ' ' + ('00' + date.getHours()).slice(-2) + ':' + ('00' + date.getMinutes()).slice(-2) + ':' + ('00' + date.getSeconds()).slice(-2));\nreturn[{payload:date}]","outputs":1,"noerr":0,"x":320.5,"y":625,"wires":[["215ba70a.4c0dd8"]]},{"id":"18b7580f.d8a258","type":"function","z":"783c70d8.6ab84","name":"splitter date","func":"var date = msg.payload;\nvar datefull = date.split(\"T\");\nvar datesplit = datefull[0].split(\"-\");\nif (datesplit[1] === \"01\") { datesplit[1] = \"januari\";}\nif (datesplit[1] === \"02\") { datesplit[1] = \"februari\";}\nif (datesplit[1] === \"03\") { datesplit[1] = \"maart\";}\nif (datesplit[1] === \"04\") { datesplit[1] = \"april\";}\nif (datesplit[1] === \"05\") { datesplit[1] = \"mei\";}\nif (datesplit[1] === \"06\") { datesplit[1] = \"juni\";}\nif (datesplit[1] === \"07\") { datesplit[1] = \"juli\";}\nif (datesplit[1] === \"08\") { datesplit[1] = \"augustus\";}\nif (datesplit[1] === \"09\") { datesplit[1] = \"september\";}\nif (datesplit[1] === \"10\") { datesplit[1] = \"oktober\";}\nif (datesplit[1] === \"11\") { datesplit[1] = \"novmber\";}\nif (datesplit[1] === \"12\") { datesplit[1] = \"december\";}\n\nvar mydate = datesplit[2] + \" \" + datesplit[1] + \" \" + datesplit[0];\n\n\nvar timesplit = datefull[1].split(\":\");\nvar mytime = timesplit[0] + \":\" + timesplit[1];\nreturn[{payload:mydate},{payload:mytime}]","outputs":2,"noerr":0,"x":581,"y":674,"wires":[["fe198c52.de161"],["dd49ff65.d8295"]]},{"id":"fe198c52.de161","type":"ui_text","z":"783c70d8.6ab84","group":"877eec72.9fa84","order":2,"width":"6","height":"1","name":"datum","label":"","format":"<font size=4>{{msg.payload}}</font>","layout":"row-center","x":736,"y":659,"wires":[]},{"id":"7e5ba182.df0f1","type":"mqtt out","z":"783c70d8.6ab84","name":"","topic":"homie/homey-mr/fontein-lichten/onoff/set","qos":"0","retain":"false","broker":"fbe29703.317a48","x":957,"y":497,"wires":[]},{"id":"ab230597.fa4b98","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"48c5dcec.17d584","order":8,"width":"3","height":"1","passthru":false,"label":"Tuinfontein aan","tooltip":"","color":"","bgcolor":"","icon":"lightbulb_outline","payload":"true","payloadType":"bool","topic":"","x":607,"y":472,"wires":[["7e5ba182.df0f1","eb4a11a8.d9b4b"]]},{"id":"db5c24b.9a4c5d8","type":"ui_text","z":"783c70d8.6ab84","group":"a8ed9b6.b3b9d68","order":3,"width":"3","height":"1","name":"","label":"Trap beneden","format":"{{msg.payload}}","layout":"row-spread","x":515,"y":1170,"wires":[]},{"id":"f3ff0c86.0d0d6","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-male fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-male fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":322,"y":1170,"wires":[["db5c24b.9a4c5d8"]]},{"id":"86daaccb.40a3","type":"ui_text","z":"783c70d8.6ab84","group":"a8ed9b6.b3b9d68","order":3,"width":"3","height":"1","name":"","label":"Overloop","format":"{{msg.payload}}","layout":"row-spread","x":487,"y":1255,"wires":[]},{"id":"9d30a58e.8d2508","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-male fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-male fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":314,"y":1255,"wires":[["86daaccb.40a3"]]},{"id":"de68218b.25e21","type":"ui_text","z":"783c70d8.6ab84","group":"a8ed9b6.b3b9d68","order":3,"width":"3","height":"1","name":"","label":"Tuin","format":"{{msg.payload}}","layout":"row-spread","x":483,"y":1328,"wires":[]},{"id":"aa6ac9d2.ba6dc8","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-male fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-male fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":320,"y":1328,"wires":[["de68218b.25e21"]]},{"id":"f816a635.807c98","type":"mqtt in","z":"ce311d23.96814","name":"huiskamer seonsor batt","topic":"homie/homey-mr/huiskamersensor/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":154,"y":75,"wires":[["7eaecfb3.90c32"]]},{"id":"78a62a9d.8a6f14","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"huiskamer sensor","format":"{{msg.payload}}","layout":"row-spread","x":581,"y":75,"wires":[]},{"id":"1aadf135.1fcdbf","type":"mqtt in","z":"ce311d23.96814","name":"kamerdeur sensor batt","topic":"homie/homey-mr/kamerdeursensor/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":165,"y":164,"wires":[["945cba5e.cac3d8"]]},{"id":"d6f1496a.1e5638","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"kamerdeur sensor","format":"{{msg.payload}}","layout":"row-spread","x":573,"y":131,"wires":[]},{"id":"87684479.5597a8","type":"mqtt in","z":"ce311d23.96814","name":"keukendeur sensor batt","topic":"homie/homey-mr/achterdeursensor/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":162,"y":229,"wires":[["70059336.7f21dc"]]},{"id":"86430d30.0244a","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"keukendeur sensor","format":"{{msg.payload}}","layout":"row-spread","x":519,"y":228,"wires":[]},{"id":"5c666cbb.3de444","type":"mqtt in","z":"ce311d23.96814","name":"keukendeur sensor batt","topic":"homie/homey-mr/garagedeur/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":162,"y":289,"wires":[["9300f13b.c454f"]]},{"id":"be3c3a4.81ba9c8","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"garagedeur sensor","format":"{{msg.payload}}","layout":"row-spread","x":515,"y":281,"wires":[]},{"id":"11ffa08d.e248ff","type":"mqtt in","z":"ce311d23.96814","name":"trap motion","topic":"homie/homey-mr/sensortrapbeneden/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":120,"y":349,"wires":[["9ffc5efa.529e4"]]},{"id":"1502f81f.282978","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"trap benedensensor","format":"{{msg.payload}}","layout":"row-spread","x":516,"y":337,"wires":[]},{"id":"e2738dcd.3b3ab","type":"mqtt in","z":"ce311d23.96814","name":"trap motion","topic":"homie/homey-mr/sensortrapboven/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":127,"y":407,"wires":[["9daa6323.0feb1"]]},{"id":"eaceea3b.94f9e8","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"trap boven sensor","format":"{{msg.payload}}","layout":"row-spread","x":508,"y":394,"wires":[]},{"id":"8806e901.ef0e38","type":"mqtt in","z":"ce311d23.96814","name":"buiten motion","topic":"homie/homey-mr/buitensensorhue/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":139,"y":453.5,"wires":[["4ac6c291.d735bc"]]},{"id":"33759ea4.47e412","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"buiten sensor","format":"{{msg.payload}}","layout":"row-spread","x":494,"y":448.5,"wires":[]},{"id":"945cba5e.cac3d8","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":374,"y":161.5,"wires":[["d6f1496a.1e5638"]]},{"id":"7eaecfb3.90c32","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":370,"y":75,"wires":[["78a62a9d.8a6f14"]]},{"id":"70059336.7f21dc","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":358,"y":226,"wires":[["86430d30.0244a"]]},{"id":"9300f13b.c454f","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":351,"y":284,"wires":[["be3c3a4.81ba9c8"]]},{"id":"9ffc5efa.529e4","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":295,"y":340,"wires":[["1502f81f.282978"]]},{"id":"9daa6323.0feb1","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":301,"y":400,"wires":[["eaceea3b.94f9e8"]]},{"id":"4ac6c291.d735bc","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":318,"y":450,"wires":[["33759ea4.47e412"]]},{"id":"611c236d.80b6cc","type":"mqtt in","z":"ce311d23.96814","name":"rookmelder keuken","topic":"homie/homey-mr/rookmelderkeuken/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":162,"y":511,"wires":[["e1255c30.7c27d"]]},{"id":"9817a568.028b28","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"rookmelder keuken","format":"{{msg.payload}}","layout":"row-spread","x":507,"y":506,"wires":[]},{"id":"e1255c30.7c27d","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":321,"y":507.5,"wires":[["9817a568.028b28"]]},{"id":"6715e43c.e72dac","type":"mqtt in","z":"ce311d23.96814","name":"rookmelder kamer","topic":"homie/homey-mr/rookmelderwoonkamer/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":162,"y":566,"wires":[["92f3a63.ad54458"]]},{"id":"5f6183b3.438fec","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"rookmelder kamer","format":"{{msg.payload}}","layout":"row-spread","x":507,"y":561,"wires":[]},{"id":"92f3a63.ad54458","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":321,"y":562.5,"wires":[["5f6183b3.438fec"]]},{"id":"976d3182.afd9b","type":"mqtt in","z":"ce311d23.96814","name":"rookmelder overloop","topic":"homie/homey-mr/rookmelderoverloop/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":162,"y":625,"wires":[["2e0a3961.62f0c6"]]},{"id":"2e0a3961.62f0c6","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":321,"y":621.5,"wires":[["2416db3b.bf07e4"]]},{"id":"2416db3b.bf07e4","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"rookmelder overloop","format":"{{msg.payload}}","layout":"row-spread","x":517,"y":620,"wires":[]},{"id":"c5cd999f.dd2fe8","type":"mqtt in","z":"ce311d23.96814","name":"rookmelder jill","topic":"homie/homey-mr/rookmelderjill/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":150,"y":685,"wires":[["a0de6e82.69db8"]]},{"id":"a0de6e82.69db8","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":329,"y":681.5,"wires":[["c02ec54a.b9d318"]]},{"id":"c02ec54a.b9d318","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"rookmelder jill","format":"{{msg.payload}}","layout":"row-spread","x":505,"y":680,"wires":[]},{"id":"f4467f29.7982d","type":"mqtt in","z":"ce311d23.96814","name":"rookmelder jesse","topic":"homie/homey-mr/rookmelderjesse/measure-battery","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":155,"y":739,"wires":[["96b71146.28ab4"]]},{"id":"96b71146.28ab4","type":"function","z":"ce311d23.96814","name":"splitter","func":"var first = msg.payload;\nif (msg.payload <= 20) {\n   var second = \"<font color=red size=1><i class='fa fa-battery-empty fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 40 && msg.payload > 20) {\n   var second = \"<font color=orange size=1><i class='fa fa-battery-quarter fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 50 && msg.payload > 40) {\n   var second = \"<font color=yellow size=1><i class='fa fa-battery-half fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse if (msg.payload <= 80 && msg.payload > 50) {\n   var second = \"<font color=green size=1><i class='fa fa-battery-three-quarters fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n}\nelse \n    var second = \"<font color=green size=1><i class='fa fa-battery-full fa-2x'></i> (\" + msg.payload + \"%)</font>\";\n\nreturn[{payload:second}]","outputs":1,"noerr":0,"x":324,"y":735.5,"wires":[["170524ec.d1f28b"]]},{"id":"170524ec.d1f28b","type":"ui_text","z":"ce311d23.96814","group":"2f89a4b7.276aac","order":0,"width":"5","height":"1","name":"","label":"rookmelder jesse","format":"{{msg.payload}}","layout":"row-spread","x":510,"y":734,"wires":[]},{"id":"a1b89247.ad6d5","type":"mqtt in","z":"783c70d8.6ab84","name":"aanwezig maik","topic":"Aanwezig-maik","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":798,"y":861,"wires":[["6852a8a2.79b7f8"]]},{"id":"6852a8a2.79b7f8","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"False\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (msg.payload === \"True\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":998,"y":857,"wires":[["4628ba05.16c084"]]},{"id":"4628ba05.16c084","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Maik","format":"{{msg.payload}}","layout":"row-spread","x":1161,"y":857,"wires":[]},{"id":"c4f205b3.3b36c8","type":"mqtt in","z":"783c70d8.6ab84","name":"aanwezig demy","topic":"Aanwezig-demy","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":795,"y":920,"wires":[["3698fcd0.c54cb4"]]},{"id":"3698fcd0.c54cb4","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"False\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (msg.payload === \"True\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":995,"y":916,"wires":[["c4ae286d.c4a228"]]},{"id":"c4ae286d.c4a228","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Demy","format":"{{msg.payload}}","layout":"row-spread","x":1158,"y":916,"wires":[]},{"id":"160ca339.8a0bfd","type":"mqtt in","z":"783c70d8.6ab84","name":"aanwezig marly","topic":"Aanwezig-marly","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":800,"y":967,"wires":[["60215b49.27f524"]]},{"id":"60215b49.27f524","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"False\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (msg.payload === \"True\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":1000,"y":963,"wires":[["2ccab0b6.a21ce"]]},{"id":"2ccab0b6.a21ce","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Marly","format":"{{msg.payload}}","layout":"row-spread","x":1163,"y":963,"wires":[]},{"id":"bdbf4ce3.2884","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Heidi","format":"{{msg.payload}}","layout":"row-spread","x":1168,"y":1016,"wires":[]},{"id":"8f4ef41.062a408","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Jim","format":"{{msg.payload}}","layout":"row-spread","x":1164,"y":1061,"wires":[]},{"id":"9b0fbe63.00b43","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Jesse","format":"{{msg.payload}}","layout":"row-spread","x":1159,"y":1103,"wires":[]},{"id":"d1c8360a.1e6fe8","type":"ui_text","z":"783c70d8.6ab84","group":"36361ac5.fc33b6","order":3,"width":"2","height":"1","name":"","label":"Jill","format":"{{msg.payload}}","layout":"row-spread","x":1164,"y":1144,"wires":[]},{"id":"7c6d6848.76efb8","type":"ui_text","z":"783c70d8.6ab84","group":"40b5da16.fe31e4","order":2,"width":"3","height":"1","name":"","label":"Alarm status","format":"{{msg.payload}}","layout":"row-spread","x":852,"y":1373,"wires":[]},{"id":"81f8e5e.74dd718","type":"mqtt out","z":"c6c7c18c.c0542","name":"","topic":"homie/homey-mr/fontein-lichten/onoff/set","qos":"0","retain":"false","broker":"fbe29703.317a48","x":1159,"y":641,"wires":[]},{"id":"6f91512f.5df5f","type":"mqtt in","z":"c6c7c18c.c0542","name":"fontein licht","topic":"homie/homey-mr/fontein-lichten/onoff","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":846,"y":688,"wires":[["5590d064.e6e8c"]]},{"id":"5590d064.e6e8c","type":"ui_switch","z":"c6c7c18c.c0542","name":"","label":"Fontein licht","tooltip":"","group":"b8f6527b.8eefa","order":13,"width":"4","height":"1","passthru":false,"decouple":"true","topic":"","style":"","onvalue":"true","onvalueType":"str","onicon":"fa-bullseye fa-2x","oncolor":"yellow","offvalue":"false","offvalueType":"str","officon":"fa-bullseye fa-2x","offcolor":"grey","x":1013,"y":688,"wires":[["81f8e5e.74dd718"]]},{"id":"968009d1.765bc8","type":"mqtt in","z":"783c70d8.6ab84","name":"aanwezig onbekend","topic":"Aanwezig-onbekend","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":620,"y":1069,"wires":[["c51fa5de.f7f698","90dbf2e2.eb2eb","b9961278.e0e7","a71d891c.f9dc88"]]},{"id":"c51fa5de.f7f698","type":"function","z":"783c70d8.6ab84","name":"rewrite lock with mac heidi","func":"var input = msg.payload;\nvar inputsplit = input.split(\" -\");\nif (inputsplit[0] === \"44:91:60:CC:B5:D7\") {\n\nif (inputsplit[1] === \"false\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (inputsplit[1] === \"true\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\n    return[{payload:mijnding}]\n}\n","outputs":1,"noerr":0,"x":841,"y":1024,"wires":[["bdbf4ce3.2884"]]},{"id":"90dbf2e2.eb2eb","type":"function","z":"783c70d8.6ab84","name":"rewrite lock with mac jim","func":"var input = msg.payload;\nvar inputsplit = input.split(\" -\");\nif (inputsplit[0] === \"AA:BB:CC:DD:EE:FF\") {\n\nif (inputsplit[1] === \"false\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (inputsplit[1] === \"true\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\n    return[{payload:mijnding}]\n}\n","outputs":1,"noerr":0,"x":844,"y":1073,"wires":[["8f4ef41.062a408"]]},{"id":"b9961278.e0e7","type":"function","z":"783c70d8.6ab84","name":"rewrite lock with mac jesse","func":"var input = msg.payload;\nvar inputsplit = input.split(\" -\");\nif (inputsplit[0] === \"88:A9:B7:6A:6B:38\") {\n\nif (inputsplit[1] === \"false\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (inputsplit[1] === \"true\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\n    return[{payload:mijnding}]\n}\n","outputs":1,"noerr":0,"x":852,"y":1113,"wires":[["9b0fbe63.00b43"]]},{"id":"a71d891c.f9dc88","type":"function","z":"783c70d8.6ab84","name":"rewrite lock with mac jill","func":"var input = msg.payload;\nvar inputsplit = input.split(\" -\");\nif (inputsplit[0] === \"98:CA:33:83:C5:B4\") {\n\nif (inputsplit[1] === \"false\") {\n var   mijnding = \"<font color=red><i class='fa fa-sign-out fa-2x'></i></font>\";   }\nif (inputsplit[1] === \"true\") {\n    var mijnding = \"<font color=green><i class='fa fa-sign-in fa-2x'></i></font>\";   }\n\n    return[{payload:mijnding}]\n}\n","outputs":1,"noerr":0,"x":842,"y":1151,"wires":[["d1c8360a.1e6fe8"]]},{"id":"7a03a0f6.058af","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"40b5da16.fe31e4","order":0,"width":"2","height":"1","passthru":false,"label":"ALARM UIT","tooltip":"","color":"","bgcolor":"","icon":"","payload":"true","payloadType":"bool","topic":"show","x":862,"y":1265,"wires":[["29475bc5.a59f64"]]},{"id":"29475bc5.a59f64","type":"ui_template","z":"783c70d8.6ab84","group":"b19f8a15.795c48","name":"Pin_Unlock","order":0,"width":"0","height":"0","format":"<div ng-init=\"init()\" id=\"pin_insert\" class=\"dialog\">\n    \n    <div class=\"dialog_content\">\n        \n        <div class=\"dialog_header\">\n            <span ng-click=\"closeDialog()\" class=\"close\">&times;</span>\n            <h2 style=\"margin:10px\">Insert PIN</h2>\n        </div>\n        \n        <div class=\"dialog_body\">\n\n           <div layout=\"row\" layout-align=\"center\">\n                <div class=\"number_placeholder\">\n                    {{passcode.substring(0, 1)}}\n                </div>\n                <div class=\"number_placeholder\">\n                    {{passcode.substring(1, 2)}}\n                </div>\n                <div class=\"number_placeholder\">\n                    {{passcode.substring(2, 3)}}\n                </div>\n                <div class=\"number_placeholder\">\n                    {{passcode.substring(3, 4)}}\n                </div>\n            </div>\n            \n            <div layout=\"column\" layout-align=\"center\" style=\"margin-top: 10px\">\n                <div layout=\"row\" layout-align=\"center\">\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(1)\">1</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(2)\">2</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(3)\">3</md-button>\n                    </div>\n                </div>\n                 <div layout=\"row\" layout-align=\"center\">\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(4)\">4</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(5)\">5</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(6)\">6</md-button>\n                    </div>\n                </div>\n                 <div layout=\"row\" layout-align=\"center\">\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(7)\">7</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(8)\">8</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(9)\">9</md-button>\n                    </div>\n                </div>\n                 <div layout=\"row\" layout-align=\"center\">\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"confirm()\">\n                            <ng-md-icon icon=\"done\" style=\"color:#fff;\"></ng-md-icon>\n                        </md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"add(0)\">0</md-button>\n                    </div>\n                    <div class=\"number_box\">\n                        <md-button class=\"pin\" ng-click=\"delete()\">\n                            <ng-md-icon icon=\"arrow_back\" style=\"color:#fff;\"></ng-md-icon>\n                        </md-button>\n                    </div>\n                </div>\n            </div> \n          \n        </div> <!--dialog_body-->\n    </div> <!--dialog_content-->\n</div>  <!--dialog-->\n\n\n<style>\n\n/* The Dialog (background) */\n.dialog {\n    display: none; /* Hidden by default */\n    position: fixed; /* Stay in place */\n    z-index: 9999; /* Sit on top */\n    left: 0;\n    top: 0;\n    width: 100%; /* Full width */\n    height: 100%; /* Full height */\n    overflow: auto; /* Enable scroll if needed */\n    background-color: rgb(0,0,0); /* Fallback color */\n    background-color: rgba(0,0,0,0.4); /* Black w/ opacity */\n    -webkit-transform: translateZ(0px);\n    -webkit-transform: translate3d(0,0,0);\n    -webkit-perspective: 1000;\n}\n\n.dialog_content {\n    position: absolute;\n    background-color: #333;\n    left: calc(50% - 170px);\n    top: 30px;\n    border-radius: 10px;\n    padding: 0;\n    width: 340px;\n    box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2),0 6px 20px 0 rgba(0,0,0,0.19);\n    -webkit-animation-name: animatetop;\n    animation-name: animatetop;\n    animation-duration: 0.4s;\n}\n\n/* Media query for smartphones (to Fix?) */\n@media only screen and (min-device-width : 375px) and (max-device-width : 667px) { \n    .dialog_content {\n    margin-top: 5%;\n    margin-left: 5%;\n}\n}\n\n/* Add Animation */\n@-webkit-keyframes animatetop {\n    from {top: -300px; opacity: 0} \n    to {top: 0; opacity: 1}\n}\n\n@keyframes animatetop {\n    from {top: -300px; opacity: 0}\n    to {top: 0; opacity: 1}\n}\n\n/* Dialog Header */\n.dialog_header {\n    padding: 2px 16px;\n    background-color: #8A3D79;\n    border-radius: 10px 10px 0 0;\n    color: white;\n}\n\n/* Dialog Body */\n.dialog_body {padding: 5px;}\n\n/* The Close Button */\n.close {\n    color: #fff;\n    float: right;\n    font-size: 28px;\n    font-weight: bold;\n    cursor: pointer;\n}\n\n.close:hover,\n.close:focus {\n    color: #1565C0;\n    text-decoration: none;\n    cursor: pointer;\n}\n\n/* __ */\n.number_placeholder{\n    width: 50px;\n    height: 34px;\n    margin: 10px;\n    font-size: 20pt;\n    text-align: center;\n    border-bottom: 1px solid black;\n}\n\n/* Number container */\n.number_box{\n    margin: 5px;\n}\n\n/* Buttons style */\n.pin {\n    min-height: 50px;\n    min-width: 50px;\n    font-weight: bold;\n    margin: 0px 10px 10px 0px;\n    box-shadow: 4px 4px 6px 0 #dadada;\n    background-color: #8A3D79;\n    color: #fff;\n}\n\n.pin:not([disabled]):hover {\n    background-color: #555555;\n}\n\n.btn1 {\n  color : rgb(49, 46, 46);\n  background-color: rgba(255, 222, 121, 0.96);\n  border-radius: 10px 0 0 10px;\n  font-size: 16px;\n}\n\n.btn1:not([disabled]):hover {\n  background-color: rgba(107, 103, 91, 0.96);\n  color: white;\n}\n\n.btn1[disabled] {\n  color : rgb(187, 187, 187);\n  background-color: rgba(230, 230, 229, 0.96);\n}\n\n</style>\n\n<script>\n\n/**\n * pin_dialog.js\n * Node-Red UI template for Node-Red Dashboard. \n * Custom dialog that asks for a PIN to allow actions\n * Enjoy it :). \n * -- Daniel\n *\n *\n * @license The Unlicense, http://unlicense.org/\n * @version 0.2\n * @author  Daniel Lando, https://github.com/robertsLando\n * @updated 2019-03-18\n * @link    ----\n *\n *\n */\n\nvar dialog;\n\n/* ==== */\n(function(scope) {\n    \n    scope.passcode = \"\";\n    scope.payload = \"\";\n    scope.inited = false;\n    \n    scope.init = function() {\n        scope.passcode = \"\";\n        //Hide the md-panel\n        $('#pin_insert').parent().parent().css(\"display\", \"none\");\n        //This trick make it works on smartphones too :)\n        dialog = $('#pin_insert').detach();\n        //remove any previously added pin dialog\n        $('.dialog').remove();\n    }\n    \n    scope.showDialog = function() {\n        dialog.appendTo(document.body);\n        dialog.css(\"display\", \"block\");\n    }\n    \n    scope.closeDialog = function(){\n        dialog.css(\"display\", \"none\");\n    }\n    \n    scope.add = function(value) {\n        if(scope.passcode.length < 4) {\n            scope.passcode = scope.passcode + value;\n            if(scope.passcode.length == 4) {\n                console.log(\"The four digit code was entered\");\n                   \n            }\n        }\n    }\n \n    scope.delete = function() {\n        if(scope.passcode.length > 0) {\n            scope.passcode = scope.passcode.substring(0, scope.passcode.length - 1);\n        }\n    }\n    \n    scope.confirm = function() {\n        if(scope.passcode.length == 4) {\n            scope.send({passcode: scope.passcode, payload : scope.payload});\n            scope.closeDialog();\n            scope.passcode = \"\";\n            scope.payload = \"\";\n        }\n    }\n\n    scope.$watch('msg', function(data) {\n        if(data && data.topic){\n            switch(data.topic){\n               case \"show\":\n                   if(scope.inited){\n                        scope.payload = data.payload;\n                        scope.showDialog();\n                   }\n                   else\n                        scope.inited = true;\n                break;\n                case \"close\": \n                    scope.closeDialog(); \n                break;\n            }\n        }\n    });\n})(scope);\n\n</script>\n","storeOutMessages":false,"fwdInMessages":false,"resendOnRefresh":false,"templateScope":"local","x":1031.3750343322754,"y":1310.9642696380615,"wires":[["84776bae.e2faf8"]]},{"id":"84776bae.e2faf8","type":"function","z":"783c70d8.6ab84","name":"verify_pin","func":"var pins = [\"1408\"];\nvar verified = false;\n\nfor(var i=0;i<pins.length;i++){\n    if(msg.passcode == pins[i]){\n        verified = true;\n        break;\n    }\n}\n\nmsg.verified = verified;\n\nreturn msg;","outputs":1,"noerr":0,"x":1196,"y":1311,"wires":[["273bf514.efeb8a"]]},{"id":"273bf514.efeb8a","type":"switch","z":"783c70d8.6ab84","name":"check","property":"verified","propertyType":"msg","rules":[{"t":"true"},{"t":"false"}],"checkall":"false","outputs":2,"x":1346,"y":1311,"wires":[["bbfa1e31.b1a82"],["d138be9c.20ff2"]]},{"id":"bbfa1e31.b1a82","type":"function","z":"783c70d8.6ab84","name":"pin_ok","func":"var msg2 = {};\nvar msg3 = {};\nmsg2.topic = \"Alarm disabled!\";\nmsg2.payload = \"false\";\nmsg3.topic = \"Alarm disabled!\";\nmsg3.payload = \"Welkom thuis\";  \nreturn [msg3, msg2];","outputs":2,"noerr":0,"x":1511.8749961853027,"y":1290.999994277954,"wires":[["3ca50e11.5d96a2"],["7006b13c.83a1e"]]},{"id":"d138be9c.20ff2","type":"function","z":"783c70d8.6ab84","name":"pin_error","func":" msg.topic = \"Wrong PIN\";\n msg.payload = \"!\";\n    \nreturn msg;","outputs":1,"noerr":0,"x":1521.8749961853027,"y":1330.999994277954,"wires":[["3ca50e11.5d96a2"]]},{"id":"3ca50e11.5d96a2","type":"ui_toast","z":"783c70d8.6ab84","position":"top right","displayTime":"10","highlight":"","sendall":true,"outputs":0,"ok":"OK","cancel":"","raw":false,"topic":"","name":"","x":1730,"y":1304,"wires":[]},{"id":"befe4581.867428","type":"mqtt in","z":"783c70d8.6ab84","name":"","topic":"alarmstatus","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":654,"y":1311,"wires":[["de75aa93.7f64f8"]]},{"id":"de75aa93.7f64f8","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"  false\") {\n var   mijnding = \"<font color=green><i class='fa fa-home fa-2x'></i></font>\";   }\nif (msg.payload === \"  true\") {\n var   mijnding = \"<font color=red><i class='fa fa-home fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":668,"y":1374,"wires":[["7c6d6848.76efb8"]]},{"id":"43d30026.2172b","type":"ui_button","z":"783c70d8.6ab84","name":"","group":"40b5da16.fe31e4","order":0,"width":"2","height":"1","passthru":false,"label":"ALARM AAN","tooltip":"","color":"","bgcolor":"","icon":"","payload":"true","payloadType":"bool","topic":"show","x":1303,"y":1453,"wires":[["8f5defeb.a40e4"]]},{"id":"8f5defeb.a40e4","type":"function","z":"783c70d8.6ab84","name":"pin_ok","func":"var msg2 = {};\nvar msg3 = {};\nmsg2.topic = \"Alarm enabled!\";\nmsg2.payload = \"true\";\nmsg3.topic = \"Alarm enabled!\";\nmsg3.payload = \"3 minutes countdown\";\nreturn [msg3, msg2];","outputs":"2","noerr":0,"x":1522.8749961853027,"y":1448.999994277954,"wires":[["935ef6cd.3f59e8"],["7006b13c.83a1e"]]},{"id":"935ef6cd.3f59e8","type":"ui_toast","z":"783c70d8.6ab84","position":"top right","displayTime":"10","highlight":"","sendall":true,"outputs":0,"ok":"OK","cancel":"","raw":false,"topic":"","name":"","x":1741,"y":1462,"wires":[]},{"id":"7006b13c.83a1e","type":"mqtt out","z":"783c70d8.6ab84","name":"","topic":"homie/homey-mr/alarm/onoff/set","qos":"","retain":"","broker":"fbe29703.317a48","x":1793,"y":1354,"wires":[]},{"id":"5123b892.ed0848","type":"mqtt in","z":"783c70d8.6ab84","name":"","topic":"homie/homey-mr/alarm/onoff","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":1420,"y":1169,"wires":[[]]},{"id":"f4f4ccf2.0ee56","type":"mqtt in","z":"783c70d8.6ab84","name":"huiskamer sensor","topic":"homie/homey-mr/huiskamersensor/measure-pressure","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":818,"y":101,"wires":[["1ea506c4.7d5929"]]},{"id":"1ea506c4.7d5929","type":"ui_gauge","z":"783c70d8.6ab84","name":"","group":"82005cce.d8aff","order":3,"width":"2","height":"2","gtype":"donut","title":"Druk","label":"mbar","format":"{{msg.payload}}","min":"800","max":"1200","colors":["#ff0000","#00e600","#ca3838"],"seg1":"950","seg2":"1050","x":998,"y":102,"wires":[]},{"id":"f47159c7.93c348","type":"ui_text","z":"783c70d8.6ab84","group":"82005cce.d8aff","order":3,"width":0,"height":0,"name":"","label":"Buiten","format":"{{msg.payload.celsius}}&deg","layout":"row-spread","x":358,"y":110,"wires":[]},{"id":"4c74f597.b3c01c","type":"ui_text","z":"783c70d8.6ab84","group":"82005cce.d8aff","order":4,"width":0,"height":0,"name":"","label":"Gang","format":"{{msg.payload.celsius}}&deg","layout":"row-spread","x":411,"y":34,"wires":[]},{"id":"6f4efe8b.f22a7","type":"ui_text","z":"783c70d8.6ab84","group":"82005cce.d8aff","order":4,"width":0,"height":0,"name":"","label":"Overloop","format":"{{msg.payload.celsius}}&deg","layout":"row-spread","x":1225,"y":27,"wires":[]},{"id":"e99ab598.0fdaa8","type":"ui_text","z":"783c70d8.6ab84","group":"82005cce.d8aff","order":4,"width":0,"height":0,"name":"","label":"Dummy","format":"{{msg.payload.celsius}}&deg","layout":"row-spread","x":1228,"y":104,"wires":[]},{"id":"ad42bf6d.80746","type":"ui_text","z":"783c70d8.6ab84","group":"82005cce.d8aff","order":4,"width":0,"height":0,"name":"","label":"Dummy2","format":"{{msg.payload.celsius}}&deg","layout":"row-spread","x":1227,"y":158,"wires":[]},{"id":"1a1173d4.07008c","type":"ui_text","z":"783c70d8.6ab84","group":"877eec72.9fa84","order":5,"width":"2","height":"1","name":"","label":"Druk:","format":"<font size=2>{{msg.payload}}</font>","layout":"row-center","x":548,"y":976,"wires":[]},{"id":"978401ad.40ca8","type":"mqtt in","z":"783c70d8.6ab84","name":"kamerdeur","topic":"homie/homey-mr/kamerdeursensor/alarm-contact","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":147,"y":1608,"wires":[["6c5c4acc.2d4564"]]},{"id":"a1f1283d.b20138","type":"mqtt in","z":"783c70d8.6ab84","name":"keukendeur","topic":"homie/homey-mr/achterdeursensor/alarm-contact","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":162,"y":1691.5,"wires":[["1487407b.8bbbd"]]},{"id":"a0a3e92e.0d1368","type":"mqtt in","z":"783c70d8.6ab84","name":"Garagedeur","topic":"homie/homey-mr/garagedeur/alarm-contact","qos":"2","datatype":"auto","broker":"fbe29703.317a48","x":166,"y":1742.5,"wires":[["ed7c0ada.9bb738"]]},{"id":"209b3a44.735c66","type":"ui_text","z":"783c70d8.6ab84","group":"31dcf84.ea6c308","order":3,"width":"2","height":"1","name":"","label":"Bovenraam","format":"{{msg.payload}}","layout":"col-center","x":520,"y":1743,"wires":[]},{"id":"ed7c0ada.9bb738","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-lock fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-unlock fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":353,"y":1744,"wires":[["209b3a44.735c66"]]},{"id":"4c1ba104.add3","type":"ui_text","z":"783c70d8.6ab84","group":"31dcf84.ea6c308","order":3,"width":"2","height":"1","name":"","label":"Voorraam","format":"{{msg.payload}}","layout":"col-center","x":506,"y":1666,"wires":[]},{"id":"458b3fca.93fe2","type":"ui_text","z":"783c70d8.6ab84","group":"31dcf84.ea6c308","order":3,"width":"2","height":"1","name":"","label":"Voordeur","format":"{{msg.payload}}","layout":"col-center","x":501,"y":1607,"wires":[]},{"id":"6c5c4acc.2d4564","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-lock fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-unlock fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":325,"y":1607,"wires":[["458b3fca.93fe2"]]},{"id":"1487407b.8bbbd","type":"function","z":"783c70d8.6ab84","name":"rewrite lock","func":"if (msg.payload === \"false\") {\n    mijnding = \"<font color=green><i class='fa fa-lock fa-2x'></i></font>\";   }\nif (msg.payload === \"true\") {\n    mijnding = \"<font color=red><i class='fa fa-unlock fa-2x'></i></font>\";   }\n\nreturn[{payload:mijnding}]","outputs":1,"noerr":0,"x":337,"y":1679,"wires":[["4c1ba104.add3"]]}]

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.