[{"id":"32b0f0895be4305f","type":"tab","label":"Raspi reboot","disabled":false,"info":"","env":[]},{"id":"0e94cbdf3aba280c","type":"tab","label":"zigbee2mqtt/bridge","disabled":false,"info":"","env":[]},{"id":"53dfc2cb99488ae4","type":"tab","label":"RGB Lampe Office","disabled":false,"info":"","env":[]},{"id":"11d377bc371aaddb","type":"tab","label":"Terasse","disabled":false,"info":"","env":[]},{"id":"bd03ffdc8594c98a","type":"tab","label":"DGWZ Kerzen Lampe","disabled":false,"info":"","env":[]},{"id":"daac90608a03ccb6","type":"tab","label":"Shelly RGBW2 color","disabled":false,"info":""},{"id":"9469147d85cf6677","type":"tab","label":"AQARA thp sensor","disabled":false,"info":"","env":[]},{"id":"92c3eb361cb6c77d","type":"junction","z":"53dfc2cb99488ae4","x":1800,"y":1180,"wires":[["17726287d0bcc963"]]},{"id":"96f39294113c492b","type":"junction","z":"53dfc2cb99488ae4","x":600,"y":320,"wires":[["ce085137d438a808"]]},{"id":"8a9692d4e4b9ae62","type":"junction","z":"53dfc2cb99488ae4","x":1280,"y":1180,"wires":[["92c3eb361cb6c77d"]]},{"id":"270fd4f99dc973d3","type":"junction","z":"9469147d85cf6677","x":380,"y":1060,"wires":[["351be0c5a6dda773"]]},{"id":"9f2971a7bac745d7","type":"junction","z":"9469147d85cf6677","x":380,"y":1220,"wires":[["20259be369dd9959"]]},{"id":"1eda39b888839225","type":"junction","z":"9469147d85cf6677","x":380,"y":1300,"wires":[["fbfbe084ad1f0915"]]},{"id":"ef5be74544e6ddb9","type":"junction","z":"9469147d85cf6677","x":380,"y":1460,"wires":[["db26efcf274c2041"]]},{"id":"2017768f0e2fcfb2","type":"junction","z":"9469147d85cf6677","x":380,"y":1540,"wires":[["c9c789dd2f7cce7f"]]},{"id":"8979154ad312dcc8","type":"junction","z":"9469147d85cf6677","x":380,"y":1700,"wires":[["66c1c61c4427500d"]]},{"id":"67e7ccc7233608f6","type":"mqtt-broker","name":"mqtt-broker","broker":"10.0.0.43:1883","port":"1883","clientid":"","autoConnect":true,"usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"sessionExpiry":""},{"id":"a0e9babcc72feb61","type":"ui_base","theme":{"name":"theme-light","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":"#097479","baseFont":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif","edited":false},"customTheme":{"name":"Untitled Theme 1","default":"#4B7930","baseColor":"#4B7930","baseFont":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"},"themeState":{"base-color":{"default":"#0094CE","value":"#0094CE","edited":false},"page-titlebar-backgroundColor":{"value":"#0094CE","edited":false},"page-backgroundColor":{"value":"#fafafa","edited":false},"page-sidebar-backgroundColor":{"value":"#ffffff","edited":false},"group-textColor":{"value":"#1bbfff","edited":false},"group-borderColor":{"value":"#ffffff","edited":false},"group-backgroundColor":{"value":"#ffffff","edited":false},"widget-textColor":{"value":"#111111","edited":false},"widget-backgroundColor":{"value":"#0094ce","edited":false},"widget-borderColor":{"value":"#ffffff","edited":false},"base-font":{"value":"-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif"}},"angularTheme":{"primary":"indigo","accents":"blue","warn":"red","background":"grey","palette":"light"}},"site":{"name":"LED-Licht","hideToolbar":"false","allowSwipe":"false","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":"82e2027f20ecc4d1","type":"ui_tab","name":"RGB Testlampe","icon":"dashboard","order":1,"disabled":false,"hidden":false},{"id":"968c808df1508cf1","type":"ui_group","name":"RGB Testlampe 1","tab":"82e2027f20ecc4d1","order":1,"disp":true,"width":"6","collapse":false,"className":""},{"id":"87554c7c0c0ec713","type":"ui_tab","name":"Terrasse","icon":"dashboard","order":2,"disabled":false,"hidden":false},{"id":"8af0f4c0aa346a6b","type":"ui_group","name":"Terrassenlampen","tab":"87554c7c0c0ec713","order":1,"disp":true,"width":"6","collapse":false,"className":""},{"id":"c0496ae00046f887","type":"ui_tab","name":"DGWZ-Kerzen-Lampe","icon":"dashboard","order":3,"disabled":false,"hidden":false},{"id":"0b814fa0435beb6f","type":"ui_group","name":"Kerzenlampe","tab":"c0496ae00046f887","order":1,"disp":true,"width":"6","collapse":false,"className":""},{"id":"16fd4d067dd7510f","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":6,"width":1,"height":1},{"id":"74b7dbf18e4459fa","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":8,"width":1,"height":1},{"id":"1ac18bdbb298029c","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":9,"width":1,"height":1},{"id":"ad58819ad6bf6145","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":10,"width":1,"height":1},{"id":"fd346a9620c6984c","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":11,"width":1,"height":1},{"id":"6399dc9c421a40e8","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":12,"width":1,"height":1},{"id":"c627c008ec270a47","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":13,"width":1,"height":1},{"id":"eaf7766f38db1911","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"0b814fa0435beb6f","order":14,"width":1,"height":1},{"id":"812ca6d766cc07af","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":6,"width":1,"height":1},{"id":"096bebb436f62ec4","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":8,"width":1,"height":1},{"id":"a9e364999a888574","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":9,"width":1,"height":1},{"id":"32cc8442e2e1c5d2","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":10,"width":1,"height":1},{"id":"bd68b6670efcdc3e","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":11,"width":1,"height":1},{"id":"d72cf14d163d3db2","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":12,"width":1,"height":1},{"id":"abe5cf4cbcd0f4de","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":13,"width":1,"height":1},{"id":"d794760eac80a35c","type":"ui_spacer","z":"32b0f0895be4305f","name":"spacer","group":"968c808df1508cf1","order":14,"width":1,"height":1},{"id":"717ed9cc3def7013","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":5,"width":1,"height":1},{"id":"f7f869220c5d167d","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":7,"width":1,"height":1},{"id":"04b40d636b670349","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":8,"width":1,"height":1},{"id":"216889c6cc88dd41","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":9,"width":1,"height":1},{"id":"3703baf2a9fd21a1","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":10,"width":1,"height":1},{"id":"49ab5fc2d0462510","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":11,"width":1,"height":1},{"id":"ae5014d4e4fd550e","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":12,"width":1,"height":1},{"id":"562179355ce5b281","type":"ui_spacer","z":"daac90608a03ccb6","name":"spacer","group":"b2305ba99da3446d","order":13,"width":1,"height":1},{"id":"b2305ba99da3446d","type":"ui_group","name":"Color","tab":"fcb6f0e9766f7cfb","order":1,"disp":false,"width":"6","collapse":false},{"id":"fcb6f0e9766f7cfb","type":"ui_tab","name":"DGWZ TV-LED","icon":"dashboard","order":38,"disabled":false,"hidden":false},{"id":"f107620a99de236b","type":"ui_tab","name":"Sensors","icon":"dashboard","order":5,"disabled":false,"hidden":false},{"id":"e25da20c3f5e7e14","type":"ui_group","name":"Aquara Sensors WSDCGQ11LM (temperature, humidity, pressure)","tab":"f107620a99de236b","order":1,"disp":true,"width":"22","collapse":false,"className":""},{"id":"c0ee80a67e33b38e","type":"ui_spacer","z":"9469147d85cf6677","name":"spacer","group":"e25da20c3f5e7e14","order":20,"width":2,"height":1},{"id":"d3e18cccb1ed8148","type":"ui_spacer","z":"9469147d85cf6677","name":"spacer","group":"e25da20c3f5e7e14","order":23,"width":2,"height":1},{"id":"0ea5572706b9a79b","type":"ui_spacer","z":"9469147d85cf6677","name":"spacer","group":"e25da20c3f5e7e14","order":24,"width":2,"height":1},{"id":"53fd7fc44fbede26","type":"ui_spacer","z":"9469147d85cf6677","name":"spacer","group":"e25da20c3f5e7e14","order":25,"width":2,"height":1},{"id":"f82b38d2019d5fc2","type":"ui_spacer","z":"9469147d85cf6677","name":"spacer","group":"e25da20c3f5e7e14","order":26,"width":2,"height":1},{"id":"58724090944c5d8b","type":"function","z":"32b0f0895be4305f","name":"reconnect WiFi","func":"msg.payload = \"sudo ip link set wlan0 down && sleep 1 && sudo ip link set wlan0 up\"\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":380,"y":120,"wires":[["22f1b275fb4fa70a"]]},{"id":"a003aa447adda2de","type":"inject","z":"32b0f0895be4305f","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":200,"y":120,"wires":[["58724090944c5d8b"]]},{"id":"22f1b275fb4fa70a","type":"exec","z":"32b0f0895be4305f","command":"sudo","addpay":"payload","append":"","useSpawn":"false","timer":"","oldrc":false,"name":"","x":530,"y":120,"wires":[[],[],[]]},{"id":"0ee6bc8cb3276b06","type":"exec","z":"32b0f0895be4305f","command":"sudo reboot","addpay":"","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"","x":370,"y":200,"wires":[[],[],[]]},{"id":"fa5af2fb16e3ed48","type":"inject","z":"32b0f0895be4305f","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":200,"y":200,"wires":[["0ee6bc8cb3276b06"]]},{"id":"5c1a93c1bc8ebc8e","type":"inject","z":"32b0f0895be4305f","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"60","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":210,"y":320,"wires":[["488197169c2c2e6f"]]},{"id":"488197169c2c2e6f","type":"mqtt out","z":"32b0f0895be4305f","name":"","topic":"zigbee/test","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":390,"y":320,"wires":[]},{"id":"1350b2f00560eeb8","type":"mqtt out","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/request/health_check","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":580,"y":120,"wires":[]},{"id":"01c5793c1a7005bc","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{}","payloadType":"json","x":230,"y":120,"wires":[["1350b2f00560eeb8"]]},{"id":"ddbb2640c97f26b3","type":"mqtt in","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/response/health_check","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":1000,"y":120,"wires":[["240bfc3ffedb16d8"]]},{"id":"240bfc3ffedb16d8","type":"debug","z":"0e94cbdf3aba280c","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1330,"y":120,"wires":[]},{"id":"f2e84f63260211a6","type":"mqtt in","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/info","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":940,"y":200,"wires":[["eaacc94c04fd445c"]]},{"id":"eaacc94c04fd445c","type":"debug","z":"0e94cbdf3aba280c","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1330,"y":200,"wires":[]},{"id":"a4e8b3a0c37655dd","type":"mqtt out","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/request/device/ota_update/check","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":540,"y":280,"wires":[]},{"id":"4f091fa15a28a360","type":"mqtt in","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/response/device/ota_update/check","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":1040,"y":280,"wires":[["7beaccfc491b0d52"]]},{"id":"7beaccfc491b0d52","type":"debug","z":"0e94cbdf3aba280c","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1330,"y":280,"wires":[]},{"id":"f4eea9ffa3fb9318","type":"mqtt out","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/request/device/ota_update/update","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":540,"y":540,"wires":[]},{"id":"40532bf60abec268","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"Button 1\"}","payloadType":"json","x":200,"y":520,"wires":[["f4eea9ffa3fb9318"]]},{"id":"d924c67be0335402","type":"inject","z":"0e94cbdf3aba280c","name":"{\"id\":\"Terrasse rechts\"}","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"Terrasse rechts\"}","payloadType":"json","x":180,"y":560,"wires":[["f4eea9ffa3fb9318"]]},{"id":"e35f823727ea6baa","type":"mqtt in","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/#","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":940,"y":540,"wires":[["5dd3d115be5d2303"]]},{"id":"5dd3d115be5d2303","type":"debug","z":"0e94cbdf3aba280c","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1350,"y":540,"wires":[]},{"id":"bb4a164e69e47f7e","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"Terrasse links\"}","payloadType":"json","x":190,"y":600,"wires":[["f4eea9ffa3fb9318"]]},{"id":"d61f860e80f15f04","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"RGB_Testlampe\"}","payloadType":"json","x":180,"y":480,"wires":[["f4eea9ffa3fb9318"]]},{"id":"e359a1af60cab9b2","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"Button 1\"}","payloadType":"json","x":200,"y":260,"wires":[["a4e8b3a0c37655dd"]]},{"id":"310632cd9cddf9f4","type":"inject","z":"0e94cbdf3aba280c","name":"{\"id\":\"Terrasse rechts\"}","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"Terrasse rechts\"}","payloadType":"json","x":180,"y":300,"wires":[["a4e8b3a0c37655dd"]]},{"id":"46d60e36689f389b","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"Terrasse links\"}","payloadType":"json","x":190,"y":340,"wires":[["a4e8b3a0c37655dd"]]},{"id":"1b149ac5212f038c","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\":\"RGB_Testlampe\"}","payloadType":"json","x":180,"y":220,"wires":[["a4e8b3a0c37655dd"]]},{"id":"e8ce0470a4d5092a","type":"mqtt out","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/request/touchlink/scan","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":580,"y":760,"wires":[]},{"id":"54c4731bbee59cc5","type":"mqtt in","z":"0e94cbdf3aba280c","name":"","topic":"zigbee2mqtt/bridge/response/touchlink/scan","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":1010,"y":760,"wires":[["6c49aaddc8e8861e"]]},{"id":"6c49aaddc8e8861e","type":"debug","z":"0e94cbdf3aba280c","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1350,"y":760,"wires":[]},{"id":"f73d58e4f702d167","type":"inject","z":"0e94cbdf3aba280c","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{}","payloadType":"json","x":230,"y":760,"wires":[["e8ce0470a4d5092a"]]},{"id":"83f04e32c39bde6a","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nlet c = \"#\" + msg.payload;\nmsg.payload = {\"color\":{\"hex\":c},\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":540,"wires":[["de11d57f36ef9d74"]]},{"id":"cff61bb6f8f9c5d5","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"brightness\": msg.payload,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":460,"wires":[["de11d57f36ef9d74"]]},{"id":"e98e0b1e16d83240","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"color_temp\": msg.payload,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":420,"wires":[["de11d57f36ef9d74"]]},{"id":"035750972755edbd","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_move_onoff\":-10}","payloadType":"json","x":1170,"y":920,"wires":[["de11d57f36ef9d74"]]},{"id":"de11d57f36ef9d74","type":"function","z":"53dfc2cb99488ae4","name":"","func":"return msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1460,"y":600,"wires":[["36b1e0c155f09b08","17726287d0bcc963"]]},{"id":"36b1e0c155f09b08","type":"debug","z":"53dfc2cb99488ae4","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1470,"y":560,"wires":[]},{"id":"c62fbfe18383c308","type":"mqtt in","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/0xf0d1b8000018a6a7/#","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":300,"y":120,"wires":[["0b411274bc93cef8"]]},{"id":"0b411274bc93cef8","type":"debug","z":"53dfc2cb99488ae4","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":590,"y":120,"wires":[]},{"id":"d9fcd3fe6e2fc650","type":"mqtt in","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/#","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":370,"y":60,"wires":[["55205158cc01eeea"]]},{"id":"076282113a635f29","type":"change","z":"53dfc2cb99488ae4","name":"","rules":[{"t":"set","p":"transition","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1130,"y":380,"wires":[["de11d57f36ef9d74"]]},{"id":"4d6ed5f3138c46eb","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"state\": msg.payload,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":340,"wires":[["de11d57f36ef9d74"]]},{"id":"b83161ad8a174667","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"0","payloadType":"num","x":650,"y":380,"wires":[["076282113a635f29"]]},{"id":"79cadfcd1cf6991e","type":"function","z":"53dfc2cb99488ae4","name":"","func":"msg.payload = {\"brightness_move\":0,\"brightness_step\":100,\"brightness_step\":-100};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":980,"wires":[["de11d57f36ef9d74"]]},{"id":"d0479e3035038399","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":1020,"y":980,"wires":[["79cadfcd1cf6991e"]]},{"id":"17726287d0bcc963","type":"mqtt out","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/RGB_Testlampe/set","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1740,"y":600,"wires":[]},{"id":"a38c749285698046","type":"mqtt out","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/RGB_Testlampe/get","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":620,"y":1000,"wires":[]},{"id":"c5153fa0f4c55976","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"state\": \"\"}","payloadType":"json","x":240,"y":1040,"wires":[["86fd7876233e41f2"]]},{"id":"86fd7876233e41f2","type":"function","z":"53dfc2cb99488ae4","name":"","func":"zigbee_get({\"state\":\"\"});\n//zigbee_set('{\"brightness_move\": 12}');\nreturn null;\n\nfunction zigbee_get(command){\n msg.payload = command;\n msg.topic = \"zigbee2mqtt/RGB_Testlampe/get\"\n node.send(msg);\n}\n\nfunction zigbee_set(command){\n msg.payload = command;\n msg.topic = \"zigbee2mqtt/RGB_Testlampe/set\"\n node.send(msg);\n}","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":380,"y":1040,"wires":[["ddefc008fb06df6b"]]},{"id":"b132a4dc7a8e0397","type":"mqtt in","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/RGB_Testlampe/#","qos":"0","datatype":"json","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":310,"y":240,"wires":[["79e15d0cc8e48ea2","5204b2d8eb1b311e"]]},{"id":"79e15d0cc8e48ea2","type":"debug","z":"53dfc2cb99488ae4","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":570,"y":200,"wires":[]},{"id":"aeab254011d7f0d3","type":"mqtt in","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/Office/#","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":350,"y":160,"wires":[["b35cfefdc587b9b8"]]},{"id":"b35cfefdc587b9b8","type":"debug","z":"53dfc2cb99488ae4","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":590,"y":160,"wires":[]},{"id":"4ad0756bbd4246df","type":"mqtt out","z":"53dfc2cb99488ae4","name":"Update Device","topic":"zigbee2mqtt/bridge/request/device/ota_update/update","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1200,"y":180,"wires":[]},{"id":"2c089e3a33227c9e","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\": \"0xf0d1b8000018a6a7\"}","payloadType":"json","x":1050,"y":180,"wires":[["4ad0756bbd4246df"]]},{"id":"426fc8f90a176645","type":"mqtt out","z":"53dfc2cb99488ae4","name":"Check for update","topic":"zigbee2mqtt/bridge/request/device/ota_update/check","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1210,"y":120,"wires":[]},{"id":"42817bad57c55e42","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"id\": \"0xf0d1b8000018a6a7\"}","payloadType":"json","x":1050,"y":120,"wires":[["426fc8f90a176645"]]},{"id":"fee674e4732cdef0","type":"range","z":"53dfc2cb99488ae4","minin":"0","maxin":"100","minout":"153","maxout":"526","action":"scale","round":false,"property":"payload","name":"","x":1020,"y":420,"wires":[["e98e0b1e16d83240"]]},{"id":"09215a5187e3d0bb","type":"range","z":"53dfc2cb99488ae4","minin":"0","maxin":"100","minout":"0","maxout":"254","action":"scale","round":false,"property":"payload","name":"","x":1020,"y":460,"wires":[["cff61bb6f8f9c5d5"]]},{"id":"c9239a7decba424e","type":"mqtt out","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/Office/set","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1780,"y":660,"wires":[]},{"id":"5204b2d8eb1b311e","type":"debug","z":"53dfc2cb99488ae4","name":"","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload.update.state","targetType":"msg","statusVal":"payload.update.state","statusType":"auto","x":630,"y":240,"wires":[]},{"id":"8ed7a1b385d082d3","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":true,"onceDelay":"1","topic":"","payload":"50","payloadType":"num","x":650,"y":420,"wires":[["fee674e4732cdef0"]]},{"id":"7f310dd12f45635e","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let h = msg.payload;\nlet t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":h,\"s\":100,\"b\":100},\"transition\":t}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":780,"wires":[["de11d57f36ef9d74"]]},{"id":"6834648bd491cef9","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":240,\"s\":100,\"b\":100},\"brightness\":254,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":740,"wires":[["de11d57f36ef9d74"]]},{"id":"4f8705c391c3d633","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":120,\"s\":100,\"b\":100},\"brightness\":254,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":700,"wires":[["de11d57f36ef9d74"]]},{"id":"84a262f3b096eb1a","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":360,\"s\":100,\"b\":100},\"brightness\":254,\"transition\":t}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":660,"wires":[["de11d57f36ef9d74"]]},{"id":"396963e65e786657","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color_temp\": 400, \"brightness\": 200, \"transition\":t}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":820,"wires":[["de11d57f36ef9d74"]]},{"id":"55205158cc01eeea","type":"debug","z":"53dfc2cb99488ae4","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":570,"y":60,"wires":[]},{"id":"ce085137d438a808","type":"ui_switch","z":"53dfc2cb99488ae4","name":"","label":"Lampe ein aus","tooltip":"","group":"968c808df1508cf1","order":1,"width":0,"height":0,"passthru":false,"decouple":"false","topic":"topic","topicType":"msg","style":"","onvalue":"ON","onvalueType":"str","onicon":"fa-2x fa-toggle-on","oncolor":"red","offvalue":"OFF","offvalueType":"str","officon":"fa-2x fa-toggle-off","offcolor":"grey","animate":true,"className":"","x":880,"y":320,"wires":[["4d6ed5f3138c46eb","2c999ff0f7fe4874"]]},{"id":"e85414dc3d2e5cea","type":"ui_slider","z":"53dfc2cb99488ae4","name":"Weiss","label":"Weiss","tooltip":"","group":"968c808df1508cf1","order":3,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":870,"y":420,"wires":[["fee674e4732cdef0"]]},{"id":"554312a1b762a9b4","type":"ui_slider","z":"53dfc2cb99488ae4","name":"Dimmer","label":"Dimmer","tooltip":"","group":"968c808df1508cf1","order":4,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":860,"y":460,"wires":[["09215a5187e3d0bb"]]},{"id":"dfe1b1a138d1c456","type":"ui_slider","z":"53dfc2cb99488ae4","name":"Transition","label":"Transition","tooltip":"","group":"968c808df1508cf1","order":2,"width":0,"height":0,"passthru":true,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":10,"step":1,"className":"","x":860,"y":380,"wires":[["076282113a635f29"]]},{"id":"434482bc7706c811","type":"ui_slider","z":"53dfc2cb99488ae4","name":"Sättigung","label":"Sättigung","tooltip":"","group":"968c808df1508cf1","order":5,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":860,"y":500,"wires":[["2a59852ef3a193c3"]]},{"id":"fb6463579839e661","type":"ui_colour_picker","z":"53dfc2cb99488ae4","name":"color picker","label":"","group":"968c808df1508cf1","format":"hex","outformat":"string","showSwatch":false,"showPicker":true,"showValue":false,"showHue":false,"showAlpha":false,"showLightness":true,"square":"false","dynOutput":"false","order":7,"width":4,"height":4,"passthru":true,"topic":"topic","topicType":"msg","className":"","x":850,"y":540,"wires":[["83f04e32c39bde6a"]]},{"id":"67876b9149844b75","type":"ui_slider","z":"53dfc2cb99488ae4","name":"HUE","label":"HUE","tooltip":"","group":"968c808df1508cf1","order":15,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"359","step":1,"className":"","x":870,"y":780,"wires":[["7f310dd12f45635e"]]},{"id":"b3924e94c583ad47","type":"ui_button","z":"53dfc2cb99488ae4","name":"","group":"968c808df1508cf1","order":17,"width":2,"height":1,"passthru":false,"label":"grün","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":870,"y":700,"wires":[["4f8705c391c3d633"]]},{"id":"e5f66a2b00447555","type":"ui_button","z":"53dfc2cb99488ae4","name":"","group":"968c808df1508cf1","order":18,"width":2,"height":1,"passthru":false,"label":"blau","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":870,"y":740,"wires":[["6834648bd491cef9"]]},{"id":"3bf84b9c03253436","type":"ui_button","z":"53dfc2cb99488ae4","name":"","group":"968c808df1508cf1","order":21,"width":0,"height":0,"passthru":false,"label":"TV","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":870,"y":820,"wires":[["396963e65e786657"]]},{"id":"9318a527c46bb174","type":"ui_button","z":"53dfc2cb99488ae4","name":"rot","group":"968c808df1508cf1","order":16,"width":2,"height":1,"passthru":false,"label":"rot","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":870,"y":660,"wires":[["84a262f3b096eb1a"]]},{"id":"bc2311d0d1a3986e","type":"function","z":"53dfc2cb99488ae4","name":"","func":"return [\n {payload:msg.payload.state},\n {payload:msg.payload.color_temp}, \n {payload:msg.payload.brightness}, \n {payload:msg.payload.color.saturation},\n {payload:msg.payload.color.hue} \n];\n","outputs":5,"noerr":0,"initialize":"","finalize":"","libs":[],"x":460,"y":540,"wires":[["96f39294113c492b"],["85e94a67788a2ba6"],["bc82eca9a288f2dd"],["1a6993dbe8a8b1f5"],["d9962ed1a1a9f6be"]]},{"id":"bc82eca9a288f2dd","type":"range","z":"53dfc2cb99488ae4","minin":"0","maxin":"254","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":630,"y":540,"wires":[["554312a1b762a9b4"]]},{"id":"85e94a67788a2ba6","type":"range","z":"53dfc2cb99488ae4","minin":"153","maxin":"526","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":630,"y":500,"wires":[["e85414dc3d2e5cea"]]},{"id":"1a6993dbe8a8b1f5","type":"function","z":"53dfc2cb99488ae4","name":"NoOp","func":"\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":630,"y":580,"wires":[["434482bc7706c811"]]},{"id":"2a59852ef3a193c3","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let s = msg.payload;\nmsg.payload = {\"color\":{\"saturation\":s}}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":500,"wires":[["de11d57f36ef9d74"]]},{"id":"d9962ed1a1a9f6be","type":"function","z":"53dfc2cb99488ae4","name":"NoOp","func":"\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":630,"y":620,"wires":[["67876b9149844b75"]]},{"id":"bcedbc900796f491","type":"mqtt in","z":"53dfc2cb99488ae4","name":"","topic":"zigbee2mqtt/RGB_Testlampe","qos":"0","datatype":"json","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":240,"y":540,"wires":[["bc2311d0d1a3986e","dd1f390681c0f4a0"]]},{"id":"e2e0bae7f8f7d8a6","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"color_temp\":526,\"brightness\": 254,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":620,"wires":[["de11d57f36ef9d74"]]},{"id":"04837410ed198983","type":"function","z":"53dfc2cb99488ae4","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"color_temp\":153,\"brightness\": 254,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1160,"y":580,"wires":[["de11d57f36ef9d74"]]},{"id":"cd14408495c74bd8","type":"ui_button","z":"53dfc2cb99488ae4","name":"kaltweiss","group":"968c808df1508cf1","order":20,"width":0,"height":0,"passthru":false,"label":"kaltweiss","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"str","topic":"topic","topicType":"msg","x":860,"y":580,"wires":[["04837410ed198983"]]},{"id":"d32ee2b9bcf020b4","type":"ui_button","z":"53dfc2cb99488ae4","name":"warmweiss","group":"968c808df1508cf1","order":19,"width":0,"height":0,"passthru":false,"label":"warmweiss","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"str","topic":"topic","topicType":"msg","x":850,"y":620,"wires":[["e2e0bae7f8f7d8a6"]]},{"id":"b27197adbdbe8fa0","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_step_onoff\":-30}","payloadType":"json","x":1170,"y":880,"wires":[["de11d57f36ef9d74"]]},{"id":"dd1f390681c0f4a0","type":"debug","z":"53dfc2cb99488ae4","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":250,"y":600,"wires":[]},{"id":"2c999ff0f7fe4874","type":"debug","z":"53dfc2cb99488ae4","name":"debug 1","active":false,"tosidebar":true,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":1160,"y":280,"wires":[]},{"id":"48c5808aaf8c39bc","type":"function","z":"53dfc2cb99488ae4","name":"LED Dimmer","func":"let delta = 0;\nlet brightness\n\nif(msg.payload === \"on\"){\n brightness = context.get('brightness');\n context.set('myInterval', setInterval(myDimmer, 150));\n //node.warn(\"on\");\n return null;\n}\nelse if (msg.payload === \"off\"){\n clearInterval(context.get('myInterval'));\n context.set('brightness',brightness);\n return null; \n}\nelse if (msg.payload === \"reset\") {\n clearInterval(context.get('myInterval'));\n brightness = 0;\n context.set('brightness', brightness);\n node.send({ payload: { \"brightness\": brightness }});\n return null;\n}\n\n//--------------------------------------------------------------------\n\nfunction myDimmer() {\n // node.warn(brightness);\n node.send({ payload: { \"brightness\": brightness}});\n brightness += delta;\n if (brightness === 255) {\n delta = -5;\n }\n if (brightness === 0) {\n delta = 5;\n }\n}\n\n//--------------------------------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n \ncontext.set('brightness',0);\n","finalize":"","libs":[],"x":1570,"y":920,"wires":[["a7df9deb1460b059","92c3eb361cb6c77d"]]},{"id":"f7dd55a08c6ae087","type":"inject","z":"53dfc2cb99488ae4","name":"press","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"on","payloadType":"str","x":1410,"y":880,"wires":[["48c5808aaf8c39bc"]]},{"id":"49b6c29373b19858","type":"inject","z":"53dfc2cb99488ae4","name":"release","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"off","payloadType":"str","x":1410,"y":920,"wires":[["48c5808aaf8c39bc"]]},{"id":"b484c0d9eb75194c","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":"1","topic":"","payload":"reset","payloadType":"str","x":1410,"y":960,"wires":[["48c5808aaf8c39bc"]]},{"id":"a7df9deb1460b059","type":"debug","z":"53dfc2cb99488ae4","name":"debug 66","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1580,"y":880,"wires":[]},{"id":"49cb8d3e6d9ced57","type":"inject","z":"53dfc2cb99488ae4","name":"brightness_move\": -12","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_move\": -12}","payloadType":"json","x":1480,"y":1240,"wires":[["92c3eb361cb6c77d"]]},{"id":"58bb13af6ca41a82","type":"inject","z":"53dfc2cb99488ae4","name":"brightness_move\": 0","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_move\": 0}","payloadType":"json","x":1490,"y":1280,"wires":[["92c3eb361cb6c77d"]]},{"id":"4fd7b9e17b580a14","type":"inject","z":"53dfc2cb99488ae4","name":"brightness_move\": 12","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_move\": 12}","payloadType":"json","x":1480,"y":1200,"wires":[["92c3eb361cb6c77d"]]},{"id":"1977af61ee33e436","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"hue_move\": 10}","payloadType":"json","x":1500,"y":1120,"wires":[["92c3eb361cb6c77d"]]},{"id":"b001448163815b09","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"hue_move\": 0}","payloadType":"json","x":1500,"y":1160,"wires":[["92c3eb361cb6c77d"]]},{"id":"fc88acc0cb404c98","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"color_temp_move\": 25}","payloadType":"json","x":1470,"y":1000,"wires":[["92c3eb361cb6c77d"]]},{"id":"649428cb94d3b601","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"color_temp_move\": 0}","payloadType":"json","x":1480,"y":1080,"wires":[["92c3eb361cb6c77d"]]},{"id":"4e62fe9a02159ab8","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"saturation_move\":10}","payloadType":"json","x":1480,"y":1320,"wires":[["92c3eb361cb6c77d"]]},{"id":"b48e05e802782686","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"saturation_move\":0}","payloadType":"json","x":1480,"y":1400,"wires":[["92c3eb361cb6c77d"]]},{"id":"ddefc008fb06df6b","type":"mqtt out","z":"53dfc2cb99488ae4","name":"","topic":"","qos":"","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":530,"y":1080,"wires":[]},{"id":"39107050b70423b7","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"saturation_move\":-10}","payloadType":"json","x":1480,"y":1360,"wires":[["92c3eb361cb6c77d"]]},{"id":"69c540045b7348c6","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"color_temp_move\":-50}","payloadType":"json","x":1470,"y":1040,"wires":[["92c3eb361cb6c77d"]]},{"id":"bca20b6fb6f31325","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"effect\":\"blink\"}","payloadType":"json","x":1080,"y":1080,"wires":[["8a9692d4e4b9ae62"]]},{"id":"767cfb75c78bf6f2","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"effect\":\"breathe\"}","payloadType":"json","x":1070,"y":1120,"wires":[["8a9692d4e4b9ae62"]]},{"id":"24a074a92e415377","type":"inject","z":"53dfc2cb99488ae4","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"effect\":\"okay\"}","payloadType":"json","x":1080,"y":1160,"wires":[["8a9692d4e4b9ae62"]]},{"id":"8a880a718d5a0861","type":"inject","z":"53dfc2cb99488ae4","name":"{\"effect\":\"channel_change\"}","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"effect\":\"channel_change\"}","payloadType":"json","x":1050,"y":1200,"wires":[["8a9692d4e4b9ae62"]]},{"id":"e32520d88ba54baf","type":"inject","z":"53dfc2cb99488ae4","name":"{\"effect\":\"finish_effect\"}","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"effect\":\"finish_effect\"}","payloadType":"json","x":1060,"y":1240,"wires":[["8a9692d4e4b9ae62"]]},{"id":"0aae2e818e7aa7a3","type":"inject","z":"53dfc2cb99488ae4","name":"{\"effect\":\"stop_effect\"}","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"effect\":\"stop_effect\"}","payloadType":"json","x":1060,"y":1280,"wires":[["8a9692d4e4b9ae62"]]},{"id":"1c9bb126f3da0c70","type":"mqtt in","z":"11d377bc371aaddb","name":"","topic":"zigbee2mqtt/Lampe links/#","qos":"0","datatype":"json","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":150,"y":260,"wires":[["954e78e6974e58d7","30c412e78752c0f0"]]},{"id":"30c412e78752c0f0","type":"debug","z":"11d377bc371aaddb","name":"","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload.update.state","targetType":"msg","statusVal":"payload.update.state","statusType":"auto","x":430,"y":220,"wires":[]},{"id":"67cbe9f545cf8f0b","type":"mqtt in","z":"11d377bc371aaddb","name":"","topic":"zigbee2mqtt/Lampe rechts/#","qos":"0","datatype":"json","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":160,"y":360,"wires":[["25793d1079042c3c"]]},{"id":"25793d1079042c3c","type":"debug","z":"11d377bc371aaddb","name":"","active":false,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload.update.state","targetType":"msg","statusVal":"payload.update.state","statusType":"auto","x":450,"y":360,"wires":[]},{"id":"2283f35f0c34f7cc","type":"mqtt in","z":"11d377bc371aaddb","name":"","topic":"zigbee2mqtt/Terasse/#","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":140,"y":420,"wires":[["bf51a99884dcd681"]]},{"id":"bf51a99884dcd681","type":"debug","z":"11d377bc371aaddb","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":410,"y":420,"wires":[]},{"id":"57afce045830f81c","type":"inject","z":"11d377bc371aaddb","name":"ON","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"ON","payloadType":"str","x":830,"y":340,"wires":[["50629ba69451edaa"]]},{"id":"cb7b9815c7965142","type":"inject","z":"11d377bc371aaddb","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"OFF","payloadType":"str","x":830,"y":380,"wires":[["50629ba69451edaa"]]},{"id":"a6377e7f5a2ff31c","type":"function","z":"11d377bc371aaddb","name":"Dimmer","func":"let b = msg.payload;\nreturn{payload:{\"brightness\": b}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1280,"y":260,"wires":[["9cdf6596d0607129"]]},{"id":"d77e0ca85c9d6cee","type":"ui_slider","z":"11d377bc371aaddb","name":"","label":"Dimmer Terrasse","tooltip":"","group":"8af0f4c0aa346a6b","order":15,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":930,"y":260,"wires":[["82864b644f9ed40a"]]},{"id":"82864b644f9ed40a","type":"range","z":"11d377bc371aaddb","minin":"0","maxin":"100","minout":"0","maxout":"254","action":"scale","round":false,"property":"payload","name":"","x":1100,"y":260,"wires":[["a6377e7f5a2ff31c"]]},{"id":"954e78e6974e58d7","type":"function","z":"11d377bc371aaddb","name":"","func":"return{payload:msg.payload.brightness};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":620,"y":260,"wires":[["03bc37c3f9edc5c0"]]},{"id":"03bc37c3f9edc5c0","type":"range","z":"11d377bc371aaddb","minin":"0","maxin":"254","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":760,"y":260,"wires":[["d77e0ca85c9d6cee"]]},{"id":"50629ba69451edaa","type":"ui_switch","z":"11d377bc371aaddb","name":"","label":"Terassenlampen ein aus","tooltip":"","group":"8af0f4c0aa346a6b","order":1,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"topic","topicType":"msg","style":"","onvalue":"ON","onvalueType":"str","onicon":"fa-2x fa-toggle-on","oncolor":"red","offvalue":"OFF","offvalueType":"str","officon":"fa-2x fa-toggle-off","offcolor":"grey","animate":true,"className":"","x":1090,"y":300,"wires":[["47de07cb93b53ed0"]]},{"id":"47de07cb93b53ed0","type":"function","z":"11d377bc371aaddb","name":"ON/OFF","func":"return{payload:{\"state\": msg.payload}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1280,"y":300,"wires":[["9cdf6596d0607129"]]},{"id":"3ab755f71ea0d25f","type":"mqtt in","z":"11d377bc371aaddb","name":"","topic":"zigbee2mqtt/Button 1/#","qos":"0","datatype":"json","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":300,"y":680,"wires":[["c32ce8a22f836e07","6910df201fa292de","bf6e314f722380d3","2ced540e52c69aa4","ee77c16cc6506468","7e96503aa43f2eba","dd095e003c50c7a5","6abe5c4f917c5a65","62b92bfd5151225d","c612f5aa2d3b7450","542ec2d08c99f18b"]]},{"id":"07b6dbf899e1fd90","type":"change","z":"11d377bc371aaddb","name":"ON","rules":[{"t":"set","p":"payload","pt":"msg","to":"ON","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":830,"y":500,"wires":[["50629ba69451edaa"]]},{"id":"98f34e8c2a458933","type":"change","z":"11d377bc371aaddb","name":"OFF","rules":[{"t":"set","p":"payload","pt":"msg","to":"OFF","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":830,"y":540,"wires":[["50629ba69451edaa"]]},{"id":"8fa52321bf3042b0","type":"debug","z":"11d377bc371aaddb","name":"battery","active":false,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":970,"y":780,"wires":[]},{"id":"8ec26df5fea95523","type":"debug","z":"11d377bc371aaddb","name":"linkquality","active":false,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":960,"y":840,"wires":[]},{"id":"804770d7a555def8","type":"debug","z":"11d377bc371aaddb","name":"update.state","active":false,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":950,"y":900,"wires":[]},{"id":"542ec2d08c99f18b","type":"debug","z":"11d377bc371aaddb","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":270,"y":760,"wires":[]},{"id":"89585b823ac13a97","type":"debug","z":"11d377bc371aaddb","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1210,"y":660,"wires":[]},{"id":"1caa333f2f2fb30c","type":"debug","z":"11d377bc371aaddb","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1210,"y":700,"wires":[]},{"id":"0c7037beb38e11ee","type":"debug","z":"11d377bc371aaddb","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload.action","targetType":"msg","statusVal":"","statusType":"auto","x":1230,"y":740,"wires":[]},{"id":"c32ce8a22f836e07","type":"switch","z":"11d377bc371aaddb","name":"on","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"on","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":630,"y":500,"wires":[["07b6dbf899e1fd90"]]},{"id":"6910df201fa292de","type":"switch","z":"11d377bc371aaddb","name":"off","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":630,"y":540,"wires":[["98f34e8c2a458933"]]},{"id":"2ced540e52c69aa4","type":"switch","z":"11d377bc371aaddb","name":"brightness_step_up","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"brightness_step_up","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":670,"y":620,"wires":[["08219c778c25c473"]]},{"id":"bf6e314f722380d3","type":"switch","z":"11d377bc371aaddb","name":"brightness_step_down","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"brightness_step_down","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":680,"y":580,"wires":[["934d531d92277877"]]},{"id":"7e96503aa43f2eba","type":"switch","z":"11d377bc371aaddb","name":"release","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"release","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":640,"y":700,"wires":[["0c01c7988cdde1e8"]]},{"id":"ee77c16cc6506468","type":"switch","z":"11d377bc371aaddb","name":"press","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"press","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":630,"y":660,"wires":[["84abf125f4721ca5"]]},{"id":"dd095e003c50c7a5","type":"switch","z":"11d377bc371aaddb","name":"hold","property":"payload.action","propertyType":"msg","rules":[{"t":"eq","v":"hold","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":630,"y":740,"wires":[["7831ade8a28c34fd"]]},{"id":"84abf125f4721ca5","type":"change","z":"11d377bc371aaddb","name":"press","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.action","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":970,"y":660,"wires":[["89585b823ac13a97"]]},{"id":"0c01c7988cdde1e8","type":"change","z":"11d377bc371aaddb","name":"release","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.action","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":960,"y":700,"wires":[["1caa333f2f2fb30c"]]},{"id":"7831ade8a28c34fd","type":"change","z":"11d377bc371aaddb","name":"hold","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.action","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":970,"y":740,"wires":[["0c7037beb38e11ee"]]},{"id":"62b92bfd5151225d","type":"change","z":"11d377bc371aaddb","name":"linkquality","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.linkquality","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":640,"y":840,"wires":[["8ec26df5fea95523"]]},{"id":"c612f5aa2d3b7450","type":"change","z":"11d377bc371aaddb","name":"update.state","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.update.state","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":650,"y":900,"wires":[["804770d7a555def8"]]},{"id":"6abe5c4f917c5a65","type":"change","z":"11d377bc371aaddb","name":"battery","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.battery","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":630,"y":780,"wires":[["8fa52321bf3042b0"]]},{"id":"934d531d92277877","type":"function","z":"11d377bc371aaddb","name":"","func":"\n//msg.payload = \"step down \" + msg.payload*-1;\nlet step = msg.payload.action_step_size*-1;\nlet t =msg.payload.action_transition_time;\nmsg.payload = {\"brightness_step_onoff\":-36};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":960,"y":580,"wires":[["71f2e6a6d5b8aeeb"]]},{"id":"08219c778c25c473","type":"function","z":"11d377bc371aaddb","name":"","func":"//msg.payload = \"step down \" + msg.payload*-1;\nlet step = msg.payload.action_step_size;\nlet t = msg.payload.action_transition_time;\nmsg.payload = {\"brightness_step_onoff\":36};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":960,"y":620,"wires":[["71f2e6a6d5b8aeeb"]]},{"id":"71f2e6a6d5b8aeeb","type":"function","z":"11d377bc371aaddb","name":"Step","func":"return msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1290,"y":340,"wires":[["9cdf6596d0607129"]]},{"id":"a6bcaa1a63898c9a","type":"mqtt in","z":"11d377bc371aaddb","name":"","topic":"home/alarmlicht","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":640,"y":300,"wires":[["1c932e48b508ad4c"]]},{"id":"1c932e48b508ad4c","type":"function","z":"11d377bc371aaddb","name":"uppercase","func":"return{payload:msg.payload.toUpperCase()};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":810,"y":300,"wires":[["50629ba69451edaa"]]},{"id":"9cdf6596d0607129","type":"mqtt out","z":"11d377bc371aaddb","name":"","topic":"zigbee2mqtt/Terasse/set ","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1550,"y":300,"wires":[]},{"id":"2433107682985fd5","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nlet c = \"#\" + msg.payload;\nmsg.payload = {\"color\":{\"hex\":c},\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":420,"wires":[["ce75a4252c8b1cd5"]]},{"id":"177e80fa0ed3618d","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"brightness\": msg.payload,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":340,"wires":[["ce75a4252c8b1cd5"]]},{"id":"db2157389961708c","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"color_temp\": msg.payload,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":300,"wires":[["ce75a4252c8b1cd5"]]},{"id":"9b26ff91e476a329","type":"inject","z":"bd03ffdc8594c98a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_move_onoff\":-10}","payloadType":"json","x":1190,"y":800,"wires":[["ce75a4252c8b1cd5"]]},{"id":"ce75a4252c8b1cd5","type":"function","z":"bd03ffdc8594c98a","name":"","func":"return msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1480,"y":480,"wires":[["0888025eb1df7d83","bb63954997803bf5"]]},{"id":"0888025eb1df7d83","type":"debug","z":"bd03ffdc8594c98a","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1660,"y":440,"wires":[]},{"id":"8ad80a1ecc027e70","type":"change","z":"bd03ffdc8594c98a","name":"","rules":[{"t":"set","p":"transition","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1150,"y":260,"wires":[["ce75a4252c8b1cd5"]]},{"id":"bdcb9816608165ac","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"state\": msg.payload,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":220,"wires":[["ce75a4252c8b1cd5"]]},{"id":"7386c1ef0226e3b5","type":"inject","z":"bd03ffdc8594c98a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"0","payloadType":"num","x":670,"y":260,"wires":[["8ad80a1ecc027e70"]]},{"id":"9630e557ad06c675","type":"function","z":"bd03ffdc8594c98a","name":"","func":"msg.payload = {\"brightness_move\":0,\"brightness_step\":100,\"brightness_step\":-100};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":860,"wires":[["ce75a4252c8b1cd5"]]},{"id":"debdc15c9954e876","type":"inject","z":"bd03ffdc8594c98a","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":1040,"y":860,"wires":[["9630e557ad06c675"]]},{"id":"bb63954997803bf5","type":"mqtt out","z":"bd03ffdc8594c98a","name":"","topic":"zigbee2mqtt/DGWZ-Kerzen-Lampe/set","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1750,"y":480,"wires":[]},{"id":"f7c49b1e743bdaad","type":"range","z":"bd03ffdc8594c98a","minin":"0","maxin":"100","minout":"153","maxout":"526","action":"scale","round":false,"property":"payload","name":"","x":1040,"y":300,"wires":[["db2157389961708c"]]},{"id":"2cb85543529a8957","type":"range","z":"bd03ffdc8594c98a","minin":"0","maxin":"100","minout":"0","maxout":"254","action":"scale","round":false,"property":"payload","name":"","x":1030,"y":340,"wires":[["177e80fa0ed3618d"]]},{"id":"1fb88ae19e5dc489","type":"mqtt out","z":"bd03ffdc8594c98a","name":"","topic":"zigbee2mqtt/Office/set","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1700,"y":540,"wires":[]},{"id":"2240279e2ed39b25","type":"inject","z":"bd03ffdc8594c98a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":true,"onceDelay":"1","topic":"","payload":"50","payloadType":"num","x":670,"y":300,"wires":[["f7c49b1e743bdaad"]]},{"id":"f57211305d91f192","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let h = msg.payload;\nlet t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":h,\"s\":100,\"b\":100},\"transition\":t}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":660,"wires":[["ce75a4252c8b1cd5"]]},{"id":"abb8740e34399f42","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":240,\"s\":100,\"b\":100},\"brightness\":254,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":620,"wires":[["ce75a4252c8b1cd5"]]},{"id":"be58c76fa6aaf321","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":120,\"s\":100,\"b\":100},\"brightness\":254,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":580,"wires":[["ce75a4252c8b1cd5"]]},{"id":"3056c044a1384d6c","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color\":{\"h\":360,\"s\":100,\"b\":100},\"brightness\":254,\"transition\":t}};\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":540,"wires":[["ce75a4252c8b1cd5"]]},{"id":"550b5090145fd726","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nreturn {payload:{\"color_temp\": 526, \"brightness\": 180, \"transition\":t}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":700,"wires":[["ce75a4252c8b1cd5"]]},{"id":"f6b7bdeb91388648","type":"ui_switch","z":"bd03ffdc8594c98a","name":"","label":"Lampe ein aus","tooltip":"","group":"0b814fa0435beb6f","order":1,"width":0,"height":0,"passthru":false,"decouple":"true","topic":"topic","topicType":"msg","style":"","onvalue":"ON","onvalueType":"str","onicon":"fa-2x fa-toggle-on","oncolor":"red","offvalue":"OFF","offvalueType":"str","officon":"fa-2x fa-toggle-off","offcolor":"grey","animate":true,"className":"","x":860,"y":220,"wires":[["bdcb9816608165ac"]]},{"id":"b16f771bea3982d3","type":"ui_slider","z":"bd03ffdc8594c98a","name":"Weiss","label":"Weiss","tooltip":"","group":"0b814fa0435beb6f","order":3,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":890,"y":300,"wires":[["f7c49b1e743bdaad"]]},{"id":"d2e95803dbb5f064","type":"ui_slider","z":"bd03ffdc8594c98a","name":"Dimmer","label":"Dimmer","tooltip":"","group":"0b814fa0435beb6f","order":4,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":880,"y":340,"wires":[["2cb85543529a8957"]]},{"id":"078e7c9544ec69b3","type":"ui_slider","z":"bd03ffdc8594c98a","name":"Transition","label":"Transition","tooltip":"","group":"0b814fa0435beb6f","order":2,"width":0,"height":0,"passthru":true,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":10,"step":1,"className":"","x":880,"y":260,"wires":[["8ad80a1ecc027e70"]]},{"id":"ced6d34b73e760eb","type":"ui_slider","z":"bd03ffdc8594c98a","name":"Sättigung","label":"Sättigung","tooltip":"","group":"0b814fa0435beb6f","order":5,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"100","step":1,"className":"","x":880,"y":380,"wires":[["d6b24fbbbda3c3a4"]]},{"id":"3eaf1914a7c87804","type":"ui_colour_picker","z":"bd03ffdc8594c98a","name":"color picker","label":"","group":"0b814fa0435beb6f","format":"hex","outformat":"string","showSwatch":false,"showPicker":true,"showValue":false,"showHue":false,"showAlpha":false,"showLightness":true,"square":"false","dynOutput":"false","order":7,"width":4,"height":4,"passthru":true,"topic":"topic","topicType":"msg","className":"","x":870,"y":420,"wires":[["2433107682985fd5"]]},{"id":"b9997f458b480652","type":"ui_slider","z":"bd03ffdc8594c98a","name":"HUE","label":"HUE","tooltip":"","group":"0b814fa0435beb6f","order":15,"width":0,"height":0,"passthru":false,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"359","step":1,"className":"","x":890,"y":660,"wires":[["f57211305d91f192"]]},{"id":"e0191a65e98afa0e","type":"ui_button","z":"bd03ffdc8594c98a","name":"","group":"0b814fa0435beb6f","order":17,"width":2,"height":1,"passthru":false,"label":"grün","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":890,"y":580,"wires":[["be58c76fa6aaf321"]]},{"id":"b7afa29ad2e28964","type":"ui_button","z":"bd03ffdc8594c98a","name":"","group":"0b814fa0435beb6f","order":18,"width":2,"height":1,"passthru":false,"label":"blau","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":890,"y":620,"wires":[["abb8740e34399f42"]]},{"id":"22254ab9f7a4f032","type":"ui_button","z":"bd03ffdc8594c98a","name":"","group":"0b814fa0435beb6f","order":21,"width":0,"height":0,"passthru":true,"label":"TV","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":890,"y":700,"wires":[["550b5090145fd726"]]},{"id":"2ccf2b885a60d2db","type":"ui_button","z":"bd03ffdc8594c98a","name":"rot","group":"0b814fa0435beb6f","order":16,"width":2,"height":1,"passthru":false,"label":"rot","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":890,"y":540,"wires":[["3056c044a1384d6c"]]},{"id":"469fe40512b4848d","type":"function","z":"bd03ffdc8594c98a","name":"","func":"return [\n {payload:msg.payload.state},\n {payload:msg.payload.color_temp}, \n {payload:msg.payload.brightness}, \n {payload:msg.payload.color.saturation},\n {payload:msg.payload.color.hue},\n {payload:msg.payload.color_mode}\n];\n","outputs":6,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":420,"wires":[["80075028ceaf6b0a"],["329967110f0729b4"],["6a3a9b1d1921c143"],["5bbd015969f18d01"],["1c960c34b0c56607"],["463430df93aaa381"]]},{"id":"6a3a9b1d1921c143","type":"range","z":"bd03ffdc8594c98a","minin":"0","maxin":"254","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":650,"y":420,"wires":[["d2e95803dbb5f064"]]},{"id":"329967110f0729b4","type":"range","z":"bd03ffdc8594c98a","minin":"153","maxin":"526","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":650,"y":380,"wires":[["b16f771bea3982d3"]]},{"id":"5bbd015969f18d01","type":"function","z":"bd03ffdc8594c98a","name":"NoOp","func":"\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":650,"y":460,"wires":[["ced6d34b73e760eb"]]},{"id":"80075028ceaf6b0a","type":"function","z":"bd03ffdc8594c98a","name":"NoOp","func":"\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":220,"wires":[["f6b7bdeb91388648"]]},{"id":"d6b24fbbbda3c3a4","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let s = msg.payload;\nmsg.payload = {\"color\":{\"saturation\":s}}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":380,"wires":[["ce75a4252c8b1cd5"]]},{"id":"1c960c34b0c56607","type":"function","z":"bd03ffdc8594c98a","name":"NoOp","func":"\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":650,"y":500,"wires":[["b9997f458b480652"]]},{"id":"74385b2f5ca4280a","type":"mqtt in","z":"bd03ffdc8594c98a","name":"","topic":"zigbee2mqtt/DGWZ-Kerzen-Lampe","qos":"0","datatype":"json","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":240,"y":420,"wires":[["469fe40512b4848d","b06639a8a4fc0b30"]]},{"id":"363a4ae92752a1ee","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"color_temp\":526,\"brightness\": 254,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":500,"wires":[["ce75a4252c8b1cd5"]]},{"id":"d24ef0779374511a","type":"function","z":"bd03ffdc8594c98a","name":"","func":"let t = flow.get('transition');\nmsg.payload = {\"color_temp\":153,\"brightness\": 254,\"transition\":t};\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1180,"y":460,"wires":[["ce75a4252c8b1cd5"]]},{"id":"775ad450e5f83c84","type":"ui_button","z":"bd03ffdc8594c98a","name":"kaltweiss","group":"0b814fa0435beb6f","order":20,"width":0,"height":0,"passthru":false,"label":"kaltweiss","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"str","topic":"topic","topicType":"msg","x":880,"y":460,"wires":[["d24ef0779374511a"]]},{"id":"b1823a527ad98857","type":"ui_button","z":"bd03ffdc8594c98a","name":"warmweiss","group":"0b814fa0435beb6f","order":19,"width":0,"height":0,"passthru":false,"label":"warmweiss","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"str","topic":"topic","topicType":"msg","x":870,"y":500,"wires":[["363a4ae92752a1ee"]]},{"id":"ba716db1e15005b7","type":"inject","z":"bd03ffdc8594c98a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"brightness_step_onoff\":-30}","payloadType":"json","x":1190,"y":760,"wires":[["ce75a4252c8b1cd5"]]},{"id":"ce833c28332ed56d","type":"mqtt in","z":"bd03ffdc8594c98a","name":"","topic":"home/DGWZ/TV-Licht","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":840,"y":180,"wires":[["bdcb9816608165ac","3d8d93022160679e"]]},{"id":"b087049b387dc264","type":"link out","z":"bd03ffdc8594c98a","name":"","mode":"link","links":["83e04311a840a23c"],"x":1425,"y":180,"wires":[]},{"id":"83e04311a840a23c","type":"link in","z":"bd03ffdc8594c98a","name":"TV-Licht-2 on","links":["b087049b387dc264"],"x":725,"y":700,"wires":[["22254ab9f7a4f032"]]},{"id":"29f7c7541c8efa3b","type":"delay","z":"bd03ffdc8594c98a","name":"","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":1300,"y":180,"wires":[["b087049b387dc264"]]},{"id":"3d8d93022160679e","type":"switch","z":"bd03ffdc8594c98a","name":"ON","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"ON","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1130,"y":180,"wires":[["29f7c7541c8efa3b"]]},{"id":"b06639a8a4fc0b30","type":"debug","z":"bd03ffdc8594c98a","name":"debug 67","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":380,"y":560,"wires":[]},{"id":"c64e6d6f10c2109e","type":"mqtt out","z":"bd03ffdc8594c98a","name":"","topic":"zigbee2mqtt/DGWZ-Kerzen-Lampe/get","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":1750,"y":600,"wires":[]},{"id":"615fc88fcbda6112","type":"inject","z":"bd03ffdc8594c98a","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"color\":{\"hue\":\"\",\"saturation\":\"\"}}","payloadType":"json","x":1190,"y":920,"wires":[["c64e6d6f10c2109e"]]},{"id":"463430df93aaa381","type":"debug","z":"bd03ffdc8594c98a","name":"debug 68","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":660,"y":540,"wires":[]},{"id":"d4eb9ebed02c1a81","type":"http request","z":"daac90608a03ccb6","name":"","method":"use","ret":"txt","paytoqs":"ignore","url":"","tls":"","persist":false,"proxy":"","authType":"","senderr":false,"x":1050,"y":440,"wires":[["b1921de1ed425917"]]},{"id":"54acddba26ec5d40","type":"function","z":"daac90608a03ccb6","name":"set RGBW2 on off","func":"msg.method = \"POST\";\nif (msg.payload === \"ON\"){\n msg.url = \"http://10.0.0.152/color/0?turn=on\";\n}\nelse if (msg.payload === \"OFF\"){\n msg.url = \"http://10.0.0.152/color/0?turn=off\";\n}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":810,"y":160,"wires":[["d4eb9ebed02c1a81"]]},{"id":"8aef38b6f3bde88e","type":"function","z":"daac90608a03ccb6","name":"on off","func":"if (msg.payload.ison === true){\n msg.payload = \"ON\";\n return msg;\n}\nelse if (msg.payload.ison === false){\n msg.payload = \"OFF\";\n return msg;\n}\npayload","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1490,"y":280,"wires":[["d5a833689656f5ec"]]},{"id":"b1921de1ed425917","type":"json","z":"daac90608a03ccb6","name":"","property":"payload","action":"","pretty":false,"x":1190,"y":440,"wires":[["3066711b38491406"]]},{"id":"e61318b2c1a72f95","type":"function","z":"daac90608a03ccb6","name":"set colors to white","func":"let t = String(flow.get('transition'));\nlet w = msg.payload;\n//msg.method = \"POST\";\n//msg.url = \"http://10.0.0.152/color/0?turn=off\"\n//node.send(msg);\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=on&red=0&green=0&blue=0&white=\" + w + \"&gain=100&transition=\" + t;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":650,"y":580,"wires":[["d4eb9ebed02c1a81"]]},{"id":"b39f297b8c0cceb0","type":"function","z":"daac90608a03ccb6","name":"","func":"msg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=on&effect=1\";\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":920,"wires":[["d4eb9ebed02c1a81"]]},{"id":"e3e886324b543c0b","type":"function","z":"daac90608a03ccb6","name":"","func":"msg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=on&effect=2\";\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":960,"wires":[["d4eb9ebed02c1a81"]]},{"id":"553f0177bf5bcc1a","type":"function","z":"daac90608a03ccb6","name":"","func":"msg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=on&effect=3\";\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":1000,"wires":[["d4eb9ebed02c1a81"]]},{"id":"9e683dde0d1984ab","type":"function","z":"daac90608a03ccb6","name":"","func":"msg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=off&effect=0\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":880,"wires":[["d4eb9ebed02c1a81"]]},{"id":"d5a833689656f5ec","type":"link out","z":"daac90608a03ccb6","name":"","links":["cf1957b49aad57d8"],"x":1585,"y":280,"wires":[]},{"id":"cf1957b49aad57d8","type":"link in","z":"daac90608a03ccb6","name":"color on off","links":["d5a833689656f5ec"],"x":265,"y":160,"wires":[["085dd2ab1eefd70c"]]},{"id":"f6ce294396eecdc0","type":"switch","z":"daac90608a03ccb6","name":"","property":"payload.overpower","propertyType":"msg","rules":[{"t":"true"}],"checkall":"true","repair":false,"outputs":1,"x":630,"y":1240,"wires":[["79119915c61ee385"]]},{"id":"79119915c61ee385","type":"function","z":"daac90608a03ccb6","name":"","func":"if (msg.payload.overpower === false){\n msg.payload = \"alles ok\";\n}\nelse if (msg.payload.overpower === true){\n msg.payload = \"Achtung Überlast!\";\n}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":760,"y":1240,"wires":[[]]},{"id":"d48e01f91ccbecef","type":"function","z":"daac90608a03ccb6","name":"set colors to red","func":"let t = String(flow.get('transition'));\nlet r = msg.payload;\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=off\"\n//node.send(msg);\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?white=0&red=\" + r + \"&transition=\" + t;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":660,"y":640,"wires":[["d4eb9ebed02c1a81"]]},{"id":"2eb5c7362722f9f4","type":"function","z":"daac90608a03ccb6","name":"set colors to green","func":"let t = String(flow.get('transition'));\nlet g = msg.payload;\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=off\"\n//node.send(msg);\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?white=0&green=\" + g + \"&transition=\" + t;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":650,"y":700,"wires":[["d4eb9ebed02c1a81"]]},{"id":"801d31dae5c001c0","type":"function","z":"daac90608a03ccb6","name":"set colors to blue","func":"let t = String(flow.get('transition'));\nlet b = msg.payload;\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=off\"\n//node.send(msg);\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?white=0&blue=\" + b + \"&transition=\" + t;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":650,"y":760,"wires":[["d4eb9ebed02c1a81"]]},{"id":"7d6094b1554aa1bb","type":"inject","z":"daac90608a03ccb6","name":"ON","props":[{"p":"method","v":"POST","vt":"str"},{"p":"url","v":"http://10.0.0.85/color/0?turn=on","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":690,"y":1060,"wires":[["d4eb9ebed02c1a81"]]},{"id":"ea95ce7edfde1dcd","type":"inject","z":"daac90608a03ccb6","name":"OFF","props":[{"p":"method","v":"POST","vt":"str"},{"p":"url","v":"http://10.0.0.85/color/0?turn=off","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":690,"y":1100,"wires":[["d4eb9ebed02c1a81"]]},{"id":"e11abb57fa51fe5c","type":"mqtt in","z":"daac90608a03ccb6","name":"","topic":"shellies/shellyrgbw2-FC9422/color/0/status","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":240,"y":1220,"wires":[["f99cec266df2f4e5"]]},{"id":"f99cec266df2f4e5","type":"json","z":"daac90608a03ccb6","name":"","property":"payload","action":"","pretty":false,"x":470,"y":1220,"wires":[["f6ce294396eecdc0"]]},{"id":"9595c56227655e3e","type":"function","z":"daac90608a03ccb6","name":"set colors to RGBW2","func":"let r = msg.payload.r;\nlet g = msg.payload.g;\nlet b = msg.payload.b;\nlet t = flow.get('transition');\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?white=0&red=\" + r + \"&green=\" + g + \"&blue=\" + b + \"&transition=\" + t;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":640,"y":400,"wires":[["d4eb9ebed02c1a81"]]},{"id":"33cdeefe2381ef0e","type":"function","z":"daac90608a03ccb6","name":"set Dimmer","func":"let Gain = msg.payload;\nlet t = flow.get('transition');\nmsg.url = \"http://10.0.0.152/color/0?gain=\" + Gain + \"&transition=\" + t;\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":730,"y":280,"wires":[["d4eb9ebed02c1a81"]]},{"id":"4eef7065f9a67af8","type":"mqtt in","z":"daac90608a03ccb6","name":"","topic":"home/zw-switch/DGWZ-TV/stat","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":false,"inputs":0,"x":210,"y":60,"wires":[["7b7fc0e529fe84a3"]]},{"id":"cfa2e68aa02f47aa","type":"mqtt out","z":"daac90608a03ccb6","name":"","topic":"home/zw-switch/DGWZ-TV/in","qos":"0","retain":"","respTopic":"","contentType":"","userProps":"","correl":"","expiry":"","broker":"67e7ccc7233608f6","x":860,"y":60,"wires":[]},{"id":"7b7fc0e529fe84a3","type":"rbe","z":"daac90608a03ccb6","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","x":430,"y":60,"wires":[["9bd17f1afc73004d"]]},{"id":"3066711b38491406","type":"switch","z":"daac90608a03ccb6","name":"mode","property":"payload.mode","propertyType":"msg","rules":[{"t":"eq","v":"color","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1310,"y":440,"wires":[["8aef38b6f3bde88e","bc0bfc31236eca92","d8d5044335fb69c6","7b4191f697988c26","9ada7b5447cd9e4f","805a343356d8dc65","2abf320362c4425c"]]},{"id":"f16e7aec825fa579","type":"ui_button","z":"daac90608a03ccb6","name":"","group":"b2305ba99da3446d","order":20,"width":0,"height":0,"passthru":false,"label":"Effect 1","tooltip":"","color":"","bgcolor":"","icon":"","payload":"","payloadType":"str","topic":"","x":240,"y":920,"wires":[["b39f297b8c0cceb0"]]},{"id":"a57997a16106184f","type":"ui_button","z":"daac90608a03ccb6","name":"","group":"b2305ba99da3446d","order":21,"width":0,"height":0,"passthru":false,"label":"Effect 2","tooltip":"","color":"","bgcolor":"","icon":"","payload":"","payloadType":"str","topic":"","x":240,"y":960,"wires":[["e3e886324b543c0b"]]},{"id":"148a6d4030dd367d","type":"ui_button","z":"daac90608a03ccb6","name":"","group":"b2305ba99da3446d","order":22,"width":0,"height":0,"passthru":false,"label":"Effect 3","tooltip":"","color":"","bgcolor":"","icon":"","payload":"","payloadType":"str","topic":"","x":240,"y":1000,"wires":[["553f0177bf5bcc1a"]]},{"id":"032d6944537d1809","type":"ui_button","z":"daac90608a03ccb6","name":"","group":"b2305ba99da3446d","order":23,"width":0,"height":0,"passthru":false,"label":"Effect aus","tooltip":"","color":"","bgcolor":"","icon":"","payload":"","payloadType":"str","topic":"","x":240,"y":880,"wires":[["9e683dde0d1984ab"]]},{"id":"085dd2ab1eefd70c","type":"ui_switch","z":"daac90608a03ccb6","name":"","label":"Color on off","tooltip":"","group":"b2305ba99da3446d","order":2,"width":0,"height":0,"passthru":false,"decouple":"true","topic":"","topicType":"str","style":"","onvalue":"ON","onvalueType":"str","onicon":"fa-2x fa-toggle-on","oncolor":"red","offvalue":"OFF","offvalueType":"str","officon":"fa-2x fa-toggle-off","offcolor":"grey","animate":true,"className":"","x":390,"y":160,"wires":[["54acddba26ec5d40","0af78350784f7993"]]},{"id":"2650782db81de800","type":"ui_slider","z":"daac90608a03ccb6","name":"","label":"Dimmer","tooltip":"","group":"b2305ba99da3446d","order":4,"width":0,"height":0,"passthru":false,"outs":"end","topic":"","topicType":"str","min":0,"max":"100","step":1,"className":"","x":420,"y":280,"wires":[["7df21dff3830bc29"]]},{"id":"f74644104a27731d","type":"ui_slider","z":"daac90608a03ccb6","name":"","label":"weiss","tooltip":"","group":"b2305ba99da3446d","order":16,"width":0,"height":0,"passthru":false,"outs":"end","topic":"","topicType":"str","min":0,"max":"100","step":1,"className":"","x":350,"y":580,"wires":[["aa9d8e4eafef68d5"]]},{"id":"aa9d8e4eafef68d5","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"100","minout":"0","maxout":"255","action":"scale","round":true,"property":"payload","name":"","x":470,"y":580,"wires":[["e61318b2c1a72f95"]]},{"id":"7df21dff3830bc29","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"100","minout":"0","maxout":"100","action":"scale","round":true,"property":"payload","name":"","x":550,"y":280,"wires":[["33cdeefe2381ef0e"]]},{"id":"eecaf944f558265f","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"100","minout":"0","maxout":"255","action":"scale","round":true,"property":"payload","name":"","x":470,"y":640,"wires":[["d48e01f91ccbecef"]]},{"id":"1f6ea50835647c29","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"100","minout":"0","maxout":"255","action":"scale","round":true,"property":"payload","name":"","x":470,"y":700,"wires":[["2eb5c7362722f9f4"]]},{"id":"35889c492f510fbd","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"100","minout":"0","maxout":"255","action":"scale","round":true,"property":"payload","name":"","x":470,"y":760,"wires":[["801d31dae5c001c0"]]},{"id":"4ed2c961a84c881f","type":"range","z":"daac90608a03ccb6","minin":"1","maxin":"5","minout":"1000","maxout":"5000","action":"scale","round":true,"property":"payload","name":"","x":570,"y":240,"wires":[["3a795fd7eb95b042"]]},{"id":"fc43076baf2b8f2e","type":"ui_slider","z":"daac90608a03ccb6","name":"Transition","label":"Transition","tooltip":"","group":"b2305ba99da3446d","order":3,"width":0,"height":0,"passthru":true,"outs":"end","topic":"topic","topicType":"msg","min":0,"max":"5","step":1,"className":"","x":420,"y":240,"wires":[["4ed2c961a84c881f"]]},{"id":"3a795fd7eb95b042","type":"change","z":"daac90608a03ccb6","name":"","rules":[{"t":"set","p":"transition","pt":"flow","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":750,"y":240,"wires":[[]]},{"id":"bddd236894a9c233","type":"ui_slider","z":"daac90608a03ccb6","name":"","label":"rot","tooltip":"","group":"b2305ba99da3446d","order":17,"width":0,"height":0,"passthru":false,"outs":"end","topic":"","topicType":"str","min":0,"max":"100","step":1,"className":"","x":350,"y":640,"wires":[["eecaf944f558265f"]]},{"id":"ba026d682ca386c0","type":"ui_slider","z":"daac90608a03ccb6","name":"","label":"grün","tooltip":"","group":"b2305ba99da3446d","order":18,"width":0,"height":0,"passthru":false,"outs":"end","topic":"","topicType":"str","min":0,"max":"100","step":1,"className":"","x":350,"y":700,"wires":[["1f6ea50835647c29"]]},{"id":"8df2201f60c6d97d","type":"ui_slider","z":"daac90608a03ccb6","name":"","label":"blau","tooltip":"","group":"b2305ba99da3446d","order":19,"width":0,"height":0,"passthru":false,"outs":"end","topic":"","topicType":"str","min":0,"max":"100","step":1,"className":"","x":350,"y":760,"wires":[["35889c492f510fbd"]]},{"id":"9bd17f1afc73004d","type":"ui_switch","z":"daac90608a03ccb6","name":"","label":"DGWZ TV an aus","tooltip":"","group":"b2305ba99da3446d","order":1,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"topic","topicType":"msg","style":"","onvalue":"on","onvalueType":"str","onicon":"fa-2x fa-toggle-on","oncolor":"red","offvalue":"off","offvalueType":"str","officon":"fa-2x fa-toggle-off","offcolor":"grey","animate":true,"className":"","x":610,"y":60,"wires":[["cfa2e68aa02f47aa"]]},{"id":"bc0bfc31236eca92","type":"change","z":"daac90608a03ccb6","name":"red","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.red","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1490,"y":580,"wires":[["4417e04d795ea081"]]},{"id":"7b4191f697988c26","type":"change","z":"daac90608a03ccb6","name":"blue","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.blue","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1490,"y":700,"wires":[["1fec7525a90135d5"]]},{"id":"d8d5044335fb69c6","type":"change","z":"daac90608a03ccb6","name":"green","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.green","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1490,"y":640,"wires":[["113e5636b5d74d57"]]},{"id":"9ada7b5447cd9e4f","type":"change","z":"daac90608a03ccb6","name":"gain","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.gain","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1490,"y":320,"wires":[["2650782db81de800"]]},{"id":"805a343356d8dc65","type":"function","z":"daac90608a03ccb6","name":"color array","func":"return{payload:{r:msg.payload.red, g:msg.payload.green, b:msg.payload.blue}};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1510,"y":360,"wires":[["4d3d69d7be90e9e1"]]},{"id":"2abf320362c4425c","type":"change","z":"daac90608a03ccb6","name":"white","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.white","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":1490,"y":520,"wires":[["b5634cec7dff3d55"]]},{"id":"183cbab1428bfadb","type":"change","z":"daac90608a03ccb6","name":"init 0","rules":[{"t":"set","p":"payload","pt":"msg","to":"0","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":290,"y":240,"wires":[["fc43076baf2b8f2e"]]},{"id":"7791a874c1d8c320","type":"ui_button","z":"daac90608a03ccb6","name":"","group":"b2305ba99da3446d","order":15,"width":0,"height":0,"passthru":false,"label":"kaltweiss","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":360,"y":520,"wires":[["e8186d9e3921dd67"]]},{"id":"e8186d9e3921dd67","type":"function","z":"daac90608a03ccb6","name":"set kaltweiss","func":"let t = String(flow.get('transition'));\nlet b = msg.payload;\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=off\"\n//node.send(msg);\nmsg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?turn=on&red=255&green=255&blue=255&white=255&gain=100transition=1\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":670,"y":520,"wires":[["d4eb9ebed02c1a81"]]},{"id":"4d3d69d7be90e9e1","type":"ui_colour_picker","z":"daac90608a03ccb6","name":"colorpicker","label":"","group":"b2305ba99da3446d","format":"rgb","outformat":"object","showSwatch":false,"showPicker":true,"showValue":false,"showHue":false,"showAlpha":false,"showLightness":true,"square":"false","dynOutput":"false","order":6,"width":4,"height":4,"passthru":false,"topic":"topic","topicType":"msg","className":"","x":370,"y":400,"wires":[["9595c56227655e3e"]]},{"id":"b5634cec7dff3d55","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"255","minout":"0","maxout":"100","action":"scale","round":true,"property":"payload","name":"","x":230,"y":580,"wires":[["f74644104a27731d"]]},{"id":"4417e04d795ea081","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"255","minout":"0","maxout":"100","action":"scale","round":true,"property":"payload","name":"","x":230,"y":640,"wires":[["bddd236894a9c233"]]},{"id":"113e5636b5d74d57","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"255","minout":"0","maxout":"100","action":"scale","round":true,"property":"payload","name":"","x":230,"y":700,"wires":[["ba026d682ca386c0"]]},{"id":"1fec7525a90135d5","type":"range","z":"daac90608a03ccb6","minin":"0","maxin":"255","minout":"0","maxout":"100","action":"scale","round":true,"property":"payload","name":"","x":230,"y":760,"wires":[["8df2201f60c6d97d"]]},{"id":"27c8c383c9dc39e8","type":"ui_button","z":"daac90608a03ccb6","name":"","group":"b2305ba99da3446d","order":14,"width":0,"height":0,"passthru":true,"label":"TV Licht","tooltip":"","color":"","bgcolor":"","className":"","icon":"","payload":"","payloadType":"date","topic":"topic","topicType":"msg","x":360,"y":460,"wires":[["a337ff0492b98d6c"]]},{"id":"a337ff0492b98d6c","type":"function","z":"daac90608a03ccb6","name":"","func":"msg.method = \"POST\";\nmsg.url = \"http://10.0.0.152/color/0?gain=25&white=0&red=255&green=50&blue=0\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":680,"y":460,"wires":[["d4eb9ebed02c1a81"]]},{"id":"71ad8a962f7aa570","type":"mqtt in","z":"daac90608a03ccb6","name":"","topic":"home/DGWZ/TV-Licht","qos":"0","datatype":"auto","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":180,"y":120,"wires":[["49d7af86dbc746ab"]]},{"id":"78936e47b4fdb609","type":"link out","z":"daac90608a03ccb6","name":"TV_Licht_on","mode":"link","links":["3799d8629e8ba66a"],"x":895,"y":120,"wires":[]},{"id":"3799d8629e8ba66a","type":"link in","z":"daac90608a03ccb6","name":"","links":["78936e47b4fdb609"],"x":195,"y":460,"wires":[["27c8c383c9dc39e8"]]},{"id":"09956d7d358fe8cc","type":"delay","z":"daac90608a03ccb6","name":"","pauseType":"delay","timeout":"5","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"allowrate":false,"outputs":1,"x":780,"y":120,"wires":[["78936e47b4fdb609"]]},{"id":"0af78350784f7993","type":"switch","z":"daac90608a03ccb6","name":"if ON","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"ON","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":170,"y":240,"wires":[["183cbab1428bfadb"]]},{"id":"0bf4342fa9787f5e","type":"inject","z":"daac90608a03ccb6","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"ON","payloadType":"str","x":590,"y":180,"wires":[["54acddba26ec5d40","09956d7d358fe8cc"]]},{"id":"49d7af86dbc746ab","type":"rbe","z":"daac90608a03ccb6","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":370,"y":120,"wires":[["09956d7d358fe8cc","54acddba26ec5d40","0af78350784f7993"]]},{"id":"229830f4e674f1f9","type":"inject","z":"daac90608a03ccb6","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"OFF","payloadType":"str","x":590,"y":100,"wires":[["54acddba26ec5d40"]]},{"id":"ad033dade2c29e0d","type":"debug","z":"9469147d85cf6677","name":"debug EG","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":440,"y":580,"wires":[]},{"id":"729919e14cd5d733","type":"change","z":"9469147d85cf6677","name":"humidity","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.humidity","tot":"msg"},{"t":"set","p":"topic","pt":"msg","to":"hum_EG %","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":700,"wires":[["edea58a87596d4fa","ae7a8dfda327534b"]]},{"id":"edea58a87596d4fa","type":"debug","z":"9469147d85cf6677","name":"debug 70","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":600,"y":700,"wires":[]},{"id":"6b8648821e359c0e","type":"change","z":"9469147d85cf6677","name":"pressure","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.pressure","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":760,"wires":[["29bad4967706c36b","d28a8e6a50999b11"]]},{"id":"29bad4967706c36b","type":"debug","z":"9469147d85cf6677","name":"debug 71","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":600,"y":760,"wires":[]},{"id":"63799ce727ee9b9a","type":"change","z":"9469147d85cf6677","name":"temperature","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.temperature","tot":"msg"},{"t":"set","p":"topic","pt":"msg","to":"temp_EG °C","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":450,"y":820,"wires":[["7ce17faea574bf07","c127da1edf11c4b1"]]},{"id":"7ce17faea574bf07","type":"debug","z":"9469147d85cf6677","name":"debug 72","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":600,"y":820,"wires":[]},{"id":"d28a8e6a50999b11","type":"function","z":"9469147d85cf6677","name":"relative pressure @ 482m","func":"let P = msg.payload;\nlet x = 1 - (482/ 44330); // 482 = hight[m] above sealevel\nlet y = 5.255;\nlet P_relativ = P / Math.pow(x, y);\n\nnode.status({ fill: \"grey\", shape: \"dot\", text: P_relativ.toFixed(1) });\n\nreturn {payload : parseFloat(P_relativ.toFixed(1)), topic : \"pressure_EG hpa\"};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":790,"y":760,"wires":[["cf4c07623a4e6356"]]},{"id":"3fe7087b2b858d8c","type":"mqtt in","z":"9469147d85cf6677","name":"Sensor EG","topic":"zigbee2mqtt/Aqara-thp-sensor-1","qos":"0","datatype":"auto-detect","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":120,"y":760,"wires":[["ad033dade2c29e0d","729919e14cd5d733","6b8648821e359c0e","63799ce727ee9b9a","bdf87a6da0957f9a","f103627375f8500c","3a4ae7136b86a4bd"]]},{"id":"2e19cd9a30c0eb8a","type":"mqtt in","z":"9469147d85cf6677","name":"Sensor DG","topic":"zigbee2mqtt/Aqara-thp-sensor-2","qos":"0","datatype":"auto-detect","broker":"67e7ccc7233608f6","nl":false,"rap":true,"rh":0,"inputs":0,"x":120,"y":260,"wires":[["f6914b3ba76dc8ca","daa61cd7f1d2765e","332d63ad2b5dbf88","342a13308710a2be","2816b01f481fea81","9d8491cdd4b10cfb","32b5bab5e0845f3c"]]},{"id":"bdf87a6da0957f9a","type":"change","z":"9469147d85cf6677","name":"voltage","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.voltage","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":880,"wires":[["b4e5913b26b06e4c"]]},{"id":"f103627375f8500c","type":"change","z":"9469147d85cf6677","name":"linkquality","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.linkquality","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":940,"wires":[["33e366013bec0bb3","2dec9b9d274c61ce"]]},{"id":"b4e5913b26b06e4c","type":"function","z":"9469147d85cf6677","name":"function 1","func":"node.status({ fill: \"grey\", shape: \"dot\", text: (msg.payload + \" mVolt\") });\n//msg.payload = msg.payload/1000;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":600,"y":880,"wires":[["53a578afa55e71e9"]]},{"id":"33e366013bec0bb3","type":"range","z":"9469147d85cf6677","minin":"0","maxin":"255","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":720,"y":940,"wires":[["9243b3dda61b885d"]]},{"id":"175db285e89a2f94","type":"debug","z":"9469147d85cf6677","name":"debug 77","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":700,"y":140,"wires":[]},{"id":"f6914b3ba76dc8ca","type":"change","z":"9469147d85cf6677","name":"humidity","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.humidity","tot":"msg"},{"t":"set","p":"topic","pt":"msg","to":"hum_DG %","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":200,"wires":[["ae9cc011e6669a5c","c592dd966564bb48"]]},{"id":"ae9cc011e6669a5c","type":"debug","z":"9469147d85cf6677","name":"debug 78","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":600,"y":200,"wires":[]},{"id":"daa61cd7f1d2765e","type":"change","z":"9469147d85cf6677","name":"pressure","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.pressure","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":260,"wires":[["9ee6814913682954","e991d66646a38162"]]},{"id":"9ee6814913682954","type":"debug","z":"9469147d85cf6677","name":"debug 79","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":600,"y":260,"wires":[]},{"id":"332d63ad2b5dbf88","type":"change","z":"9469147d85cf6677","name":"temperature","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.temperature","tot":"msg"},{"t":"set","p":"topic","pt":"msg","to":"temp_DG °C","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":450,"y":320,"wires":[["33deed4c0638242b","cfc47b7f7bf05c1a"]]},{"id":"33deed4c0638242b","type":"debug","z":"9469147d85cf6677","name":"debug 80","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":600,"y":320,"wires":[]},{"id":"e991d66646a38162","type":"function","z":"9469147d85cf6677","name":"relative pressure @ 482m","func":"let P = msg.payload;\nlet x = 1 - (482/ 44330); // 482 = hight[m] above sealevel\nlet y = 5.255;\nlet P_relativ = P / Math.pow(x, y);\n\nnode.status({ fill: \"grey\", shape: \"dot\", text: P_relativ.toFixed(1) });\n\nreturn {payload : parseFloat(P_relativ.toFixed(1)), topic : \"pressure_DG hpa\"};","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":790,"y":260,"wires":[["a193dd2f9c6cfd59"]]},{"id":"342a13308710a2be","type":"change","z":"9469147d85cf6677","name":"voltage","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.voltage","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":380,"wires":[["7e36b69a32424ce0"]]},{"id":"2816b01f481fea81","type":"change","z":"9469147d85cf6677","name":"linkquality","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.linkquality","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":440,"y":440,"wires":[["fdb57c018a7f2013","5ed69056f16f9b80"]]},{"id":"fdb57c018a7f2013","type":"range","z":"9469147d85cf6677","minin":"0","maxin":"255","minout":"0","maxout":"100","action":"scale","round":false,"property":"payload","name":"","x":740,"y":440,"wires":[["896993ca0eb04572"]]},{"id":"3a4ae7136b86a4bd","type":"change","z":"9469147d85cf6677","name":"HH:mm:ss DD-MM-YYYY","rules":[{"t":"set","p":"payload","pt":"msg","to":"$moment().tz(\"Europe/Berlin\").format(\"HH:mm:ss DD-MM-YYYY\")","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":490,"y":640,"wires":[["e5bf31cb4556cd55","4a544b9e0b779fda"]]},{"id":"e5bf31cb4556cd55","type":"debug","z":"9469147d85cf6677","name":"debug 84","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":700,"y":640,"wires":[]},{"id":"9d8491cdd4b10cfb","type":"change","z":"9469147d85cf6677","name":"HH:mm:ss DD-MM-YYYY","rules":[{"t":"set","p":"payload","pt":"msg","to":"$moment().tz(\"Europe/Berlin\").format(\"HH:mm:ss DD-MM-YYYY\")","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":490,"y":140,"wires":[["175db285e89a2f94","9bee9325206cf13b"]]},{"id":"32b5bab5e0845f3c","type":"debug","z":"9469147d85cf6677","name":"debug DG","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":450,"y":80,"wires":[]},{"id":"5ed69056f16f9b80","type":"debug","z":"9469147d85cf6677","name":" ","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":590,"y":440,"wires":[]},{"id":"2dec9b9d274c61ce","type":"debug","z":"9469147d85cf6677","name":" ","active":true,"tosidebar":false,"console":false,"tostatus":true,"complete":"payload","targetType":"msg","statusVal":"payload","statusType":"auto","x":590,"y":940,"wires":[]},{"id":"112e8ed227cc02ba","type":"function","z":"9469147d85cf6677","name":"init chart temp","func":"return null;","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload: [] });\n\nnode.send({ payload: null, topic: \"temp_DG °C\" });\nnode.send({ payload: null, topic: \"temp_EG °C\" });\n","finalize":"","libs":[],"x":460,"y":1140,"wires":[["01f9e06f44cf57e1"]]},{"id":"01f9e06f44cf57e1","type":"ui_chart","z":"9469147d85cf6677","name":"Chart temp","group":"e25da20c3f5e7e14","order":1,"width":0,"height":0,"label":"","chartType":"line","legend":"true","xformat":"dd HH:mm","interpolate":"linear","nodata":"","dot":false,"ymin":"","ymax":"","removeOlder":"7","removeOlderPoints":"","removeOlderUnit":"86400","cutout":0,"useOneColor":false,"useUTC":false,"colors":["#f91f06","#fda308","#ff7f0e","#04a5f6","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5"],"outputs":1,"useDifferentColor":false,"className":"","x":670,"y":1140,"wires":[[]]},{"id":"161901fb99b9f39c","type":"link in","z":"9469147d85cf6677","name":"temp_DG_in","links":["70cec064a08c4d28"],"x":525,"y":1100,"wires":[["01f9e06f44cf57e1","351be0c5a6dda773","45d4333138dae825"]]},{"id":"69c3f5dcc8a95854","type":"link in","z":"9469147d85cf6677","name":"hum_DG_in","links":["dc86c5bcf1a87e95"],"x":525,"y":1340,"wires":[["f881e4cc9c61c847","712aa9f75a6c7344","fbfbe084ad1f0915"]]},{"id":"5b9eee080d2ceadf","type":"link out","z":"9469147d85cf6677","name":"link out 1","mode":"link","links":["bf9f1c4191638b51","3421be6170a64191"],"x":815,"y":820,"wires":[]},{"id":"70cec064a08c4d28","type":"link out","z":"9469147d85cf6677","name":"link out 2","mode":"link","links":["ccab11256bc7a26c","161901fb99b9f39c"],"x":815,"y":320,"wires":[]},{"id":"dc86c5bcf1a87e95","type":"link out","z":"9469147d85cf6677","name":"link out 3","mode":"link","links":["4516784da5e822c3","69c3f5dcc8a95854"],"x":815,"y":200,"wires":[]},{"id":"e0d9897067903b74","type":"link out","z":"9469147d85cf6677","name":"link out 4","mode":"link","links":["436e2a689fb09445","87808920f4c7dcfa"],"x":815,"y":700,"wires":[]},{"id":"3421be6170a64191","type":"link in","z":"9469147d85cf6677","name":"temp_EG_in","links":["5b9eee080d2ceadf"],"x":525,"y":1180,"wires":[["01f9e06f44cf57e1","20259be369dd9959","a71d1eafc3148778"]]},{"id":"87808920f4c7dcfa","type":"link in","z":"9469147d85cf6677","name":"hum_EG_in","links":["e0d9897067903b74"],"x":525,"y":1420,"wires":[["f881e4cc9c61c847","940759d7c168dd45","db26efcf274c2041"]]},{"id":"0505655c54c1508f","type":"ui_chart","z":"9469147d85cf6677","name":"Chart pressure","group":"e25da20c3f5e7e14","order":11,"width":0,"height":0,"label":"","chartType":"line","legend":"true","xformat":"dd HH:mm","interpolate":"linear","nodata":"","dot":false,"ymin":"","ymax":"","removeOlder":"7","removeOlderPoints":"","removeOlderUnit":"86400","cutout":0,"useOneColor":false,"useUTC":false,"colors":["#137000","#02f79a","#ff7f0e","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5"],"outputs":1,"useDifferentColor":false,"className":"","x":680,"y":1620,"wires":[[]]},{"id":"5f3f865faaf2ee72","type":"function","z":"9469147d85cf6677","name":"init chart pressure","func":"return null;","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload: [] });\n\nnode.send({ payload: null, topic: \"pressure_DG hpa\" });\nnode.send({ payload: null, topic: \"pressure_EG hpa\" });\n","finalize":"","libs":[],"x":450,"y":1620,"wires":[["0505655c54c1508f"]]},{"id":"48c3553c7f9d3372","type":"link in","z":"9469147d85cf6677","name":"pressure_DG_in","links":["1c8850add7c6caeb"],"x":525,"y":1580,"wires":[["0505655c54c1508f","c46b991c1fa34524","c9c789dd2f7cce7f"]]},{"id":"381e855dc851d50a","type":"link in","z":"9469147d85cf6677","name":"pressure_EG_in","links":["1639c3429e39a280"],"x":525,"y":1660,"wires":[["0505655c54c1508f","b8e2c68a2126c8d8","66c1c61c4427500d"]]},{"id":"1639c3429e39a280","type":"link out","z":"9469147d85cf6677","name":"link out 5","mode":"link","links":["292fdf519fe8a54f","381e855dc851d50a"],"x":1055,"y":760,"wires":[]},{"id":"1c8850add7c6caeb","type":"link out","z":"9469147d85cf6677","name":"link out 6","mode":"link","links":["dba9ffdd34532c2b","48c3553c7f9d3372"],"x":1055,"y":260,"wires":[]},{"id":"4a544b9e0b779fda","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":17,"width":11,"height":1,"name":"","label":"update EG","format":"{{msg.payload}}","layout":"row-center","className":"","style":false,"font":"","fontSize":16,"color":"#000000","x":870,"y":640,"wires":[]},{"id":"9bee9325206cf13b","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":16,"width":11,"height":1,"name":"","label":"update DG","format":"{{msg.payload}}","layout":"row-center","className":"","style":false,"font":"","fontSize":16,"color":"#000000","x":870,"y":140,"wires":[]},{"id":"52698ea0c28cfa18","type":"function","z":"9469147d85cf6677","name":"init EG","func":"return null;","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload: \" \" });\n","finalize":"","libs":[],"x":690,"y":580,"wires":[["4a544b9e0b779fda"]]},{"id":"f36fc0a45c7880fe","type":"function","z":"9469147d85cf6677","name":"init DG","func":"return null;","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload: \" \" });\n","finalize":"","libs":[],"x":710,"y":80,"wires":[["9bee9325206cf13b"]]},{"id":"860dde1c1b3d4d2b","type":"function","z":"9469147d85cf6677","name":"init chart hum","func":"return null;","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload: [] });\n\nnode.send({ payload: null, topic: \"hum_DG %\" });\nnode.send({ payload: null, topic: \"hum_EG %\" });\n","finalize":"","libs":[],"x":460,"y":1380,"wires":[["f881e4cc9c61c847"]]},{"id":"f881e4cc9c61c847","type":"ui_chart","z":"9469147d85cf6677","name":"Chart hum","group":"e25da20c3f5e7e14","order":6,"width":0,"height":0,"label":"","chartType":"line","legend":"true","xformat":"dd HH:mm","interpolate":"linear","nodata":"","dot":false,"ymin":"","ymax":"","removeOlder":"7","removeOlderPoints":"","removeOlderUnit":"86400","cutout":0,"useOneColor":false,"useUTC":false,"colors":["#009afa","#c905ff","#ff7f0e","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5"],"outputs":1,"useDifferentColor":false,"className":"","x":670,"y":1380,"wires":[[]]},{"id":"ece0ca3c13272297","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":9,"width":4,"height":1,"name":"Tendenz EG hum","label":"","format":"{{msg.payload}}","layout":"row-center","className":"","style":true,"font":"","fontSize":16,"color":"#c905fa","x":870,"y":1420,"wires":[]},{"id":"acf1c7535b9056df","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":7,"width":4,"height":1,"name":"Tendenz DG hum","label":"","format":"{{msg.payload}}","layout":"row-center","className":"","style":true,"font":"","fontSize":16,"color":"#009afa","x":870,"y":1340,"wires":[]},{"id":"618e5dc9dd362adf","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":4,"width":4,"height":1,"name":"Tendenz EG temp","label":"","format":"{{msg.payload}}","layout":"row-center","className":"","style":true,"font":"","fontSize":16,"color":"#fda308","x":870,"y":1180,"wires":[]},{"id":"a1ee4e75123efc29","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":2,"width":4,"height":1,"name":"Tendenz DG temp","label":"","format":"{{msg.payload}}","layout":"row-center","className":"","style":true,"font":"","fontSize":16,"color":"#f91f06","x":870,"y":1100,"wires":[]},{"id":"7136c769628a1a32","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":14,"width":4,"height":1,"name":"Tendenz EG pressure","label":"","format":"{{msg.payload}}","layout":"row-center","className":"","style":true,"font":"","fontSize":16,"color":"#02f79a","x":880,"y":1660,"wires":[]},{"id":"c46b991c1fa34524","type":"function","z":"9469147d85cf6677","name":"Tendenz 5","func":"let p = msg.payload;\nif (context.get('last_value') === 0) {\n msg.payload = date_time_string() + ' ' + p;\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\ncontext.set('last_value', p);\nreturn msg;\n\nfunction date_time_string() {\n const date = new Date(Date.now());\n //const year = date.getFullYear();\n //const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n //const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n// return(day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n return (hours + ':' + minutes + ':' + seconds);\n}","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\nnode.send({ payload: \" \" });\ncontext.set('last_value', 0);\n","finalize":"","libs":[],"x":670,"y":1580,"wires":[["f5c97f0b030c0002"]]},{"id":"f5c97f0b030c0002","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":12,"width":4,"height":1,"name":"Tendenz DG pressure","label":"","format":"{{msg.payload}}","layout":"row-center","className":"","style":true,"font":"","fontSize":16,"color":"#085a02","x":880,"y":1580,"wires":[]},{"id":"b8e2c68a2126c8d8","type":"function","z":"9469147d85cf6677","name":"Tendenz 6","func":"let p = msg.payload;\nif (context.get('last_value') === 0) {\n msg.payload = date_time_string() + ' ' + p;\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\ncontext.set('last_value', p);\nreturn msg;\n\nfunction date_time_string() {\n const date = new Date(Date.now());\n //const year = date.getFullYear();\n //const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n //const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n// return(day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n return (hours + ':' + minutes + ':' + seconds);\n}","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\nnode.send({ payload: \" \" });\ncontext.set('last_value', 0);\n","finalize":"","libs":[],"x":670,"y":1660,"wires":[["7136c769628a1a32"]]},{"id":"940759d7c168dd45","type":"function","z":"9469147d85cf6677","name":"Tendenz 4","func":"let p = msg.payload;\nif (context.get('last_value') === 0) {\n msg.payload = date_time_string() + ' ' + p;\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\ncontext.set('last_value', p);\nreturn msg;\n\nfunction date_time_string() {\n const date = new Date(Date.now());\n //const year = date.getFullYear();\n //const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n //const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n// return(day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n return (hours + ':' + minutes + ':' + seconds);\n}","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\nnode.send({ payload: \" \" });\ncontext.set('last_value', 0);\n","finalize":"","libs":[],"x":670,"y":1420,"wires":[["ece0ca3c13272297"]]},{"id":"712aa9f75a6c7344","type":"function","z":"9469147d85cf6677","name":"Tendenz 3","func":"let p = msg.payload;\nif (context.get('last_value') === 0) {\n msg.payload = date_time_string() + ' ' + p;\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\ncontext.set('last_value', p);\nreturn msg;\n\nfunction date_time_string() {\n const date = new Date(Date.now());\n //const year = date.getFullYear();\n //const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n //const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n// return(day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n return (hours + ':' + minutes + ':' + seconds);\n}","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\nnode.send({ payload: \" \" });\ncontext.set('last_value', 0);\n","finalize":"","libs":[],"x":670,"y":1340,"wires":[["acf1c7535b9056df"]]},{"id":"a71d1eafc3148778","type":"function","z":"9469147d85cf6677","name":"Tendenz 2","func":"let p = msg.payload;\nif (context.get('last_value') === 0) {\n msg.payload = date_time_string() + ' ' + p;\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\ncontext.set('last_value', p);\nreturn msg;\n\nfunction date_time_string() {\n const date = new Date(Date.now());\n //const year = date.getFullYear();\n //const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n //const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n// return(day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n return (hours + ':' + minutes + ':' + seconds);\n}","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\ncontext.set('last_value', 0);\n","finalize":"","libs":[],"x":670,"y":1180,"wires":[["618e5dc9dd362adf"]]},{"id":"45d4333138dae825","type":"function","z":"9469147d85cf6677","name":"Tendenz 1","func":"let p = msg.payload;\nif (context.get('last_value') === 0) {\n msg.payload = date_time_string() + ' ' + p;\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.payload = date_time_string() + ' ' + p + ' ' + '';\n}\ncontext.set('last_value', p);\nreturn msg;\n\nfunction date_time_string() {\n const date = new Date(Date.now());\n //const year = date.getFullYear();\n //const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n //const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n// return(day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n return (hours + ':' + minutes + ':' + seconds);\n}","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\ncontext.set('last_value', 0);\n","finalize":"","libs":[],"x":670,"y":1100,"wires":[["a1ee4e75123efc29"]]},{"id":"351be0c5a6dda773","type":"function","z":"9469147d85cf6677","name":"min-max 1","func":"\nlet s = \"&ensp\";\n\nif ('reset' in msg) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n return null;\n}\n\n//-------------------------------------------\n\nlet mm = minmax(msg.payload);\n//msg.payload = mm;\nmsg.payload = \"min:\" + mm.sensormin.min + \"@\" + mm.sensormin.timestring + \" \" + \"max:\" + mm.sensormax.max + \"@\" + mm.sensormax.timestring;\nreturn msg;\n\n//-------------------------------------------\n\nfunction minmax(value) {\n let x = parseFloat(value);\n let min = context.get('min');\n let max = context.get('max');\n\n if ((min.min === 0) && (max.max === 0)) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time);\n context.set('min', min);\n max.max = x;\n context.set('max', max);\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time);\n }\n else {\n if (x < min.min) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time); \n context.set('min', min);\n }\n if (x > max.max) {\n max.max = x;\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time); \n context.set('max', max);\n }\n }\n return { 'sensormin': min, 'sensormax': max };\n}\n\n//-------------------------------------------\n\nfunction date_time_string(type, time) {\n const date = new Date(time);\n const year = date.getFullYear();\n const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n switch (type) {\n case \"full\":\n return (day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n case \"dayhm\":\n return (day + \"-\" + month + \" @ \" + hours + ':' + minutes);\n case \"hm\":\n return (hours + ':' + minutes);\n case \"hms\":\n return (hours + ':' + minutes + ':' + seconds);\n default:\n return \"error\";\n }\n}\n//-------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\n\nif (context.get(\"min\") === undefined) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n}\n\nif (context.get(\"max\") === undefined) {\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n}\n\ncontext.set(\"max\", { \"max\": 0.0, \"time\": 0 });\ncontext.set(\"min\", { \"min\": 0.0, \"time\": 0 });","finalize":"","libs":[],"x":670,"y":1060,"wires":[["06b162aa2294ea93"]]},{"id":"06b162aa2294ea93","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":3,"width":7,"height":1,"name":"MinMax DG temp","label":"","format":"{{msg.payload}}","layout":"row-left","className":"","style":true,"font":"","fontSize":16,"color":"#f91f06","x":870,"y":1060,"wires":[]},{"id":"20259be369dd9959","type":"function","z":"9469147d85cf6677","name":"min-max 2","func":"if ('reset' in msg) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n return null;\n}\n\n//-------------------------------------------\n\nlet mm = minmax(msg.payload);\n//msg.payload = mm;\nmsg.payload = \"min:\" + mm.sensormin.min + \"@\" + mm.sensormin.timestring + \" \" + \" max:\" + mm.sensormax.max + \"@\" + mm.sensormax.timestring\nreturn msg;\n\n//-------------------------------------------\n\nfunction minmax(value) {\n let x = parseFloat(value);\n let min = context.get('min');\n let max = context.get('max');\n\n if ((min.min === 0) && (max.max === 0)) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time);\n context.set('min', min);\n max.max = x;\n context.set('max', max);\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time);\n }\n else {\n if (x < min.min) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time); \n context.set('min', min);\n }\n if (x > max.max) {\n max.max = x;\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time); \n context.set('max', max);\n }\n }\n return { 'sensormin': min, 'sensormax': max };\n}\n\n//-------------------------------------------\n\nfunction date_time_string(type, time) {\n const date = new Date(time);\n const year = date.getFullYear();\n const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n switch (type) {\n case \"full\":\n return (day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n case \"dayhm\":\n return (day + \"-\" + month + \" @ \" + hours + ':' + minutes);\n case \"hm\":\n return (hours + ':' + minutes);\n case \"hms\":\n return (hours + ':' + minutes + ':' + seconds);\n default:\n return \"error\";\n }\n}\n//-------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\n\nif (context.get(\"min\") === undefined) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n}\n\nif (context.get(\"max\") === undefined) {\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n}\n\ncontext.set(\"max\", { \"max\": 0.0, \"time\": 0 });\ncontext.set(\"min\", { \"min\": 0.0, \"time\": 0 });","finalize":"","libs":[],"x":670,"y":1220,"wires":[["d0751802dbc26f54"]]},{"id":"d0751802dbc26f54","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":5,"width":7,"height":1,"name":"MinMax DG temp","label":"","format":"{{msg.payload}}","layout":"row-left","className":"","style":true,"font":"","fontSize":16,"color":"#fda308","x":870,"y":1220,"wires":[]},{"id":"fbfbe084ad1f0915","type":"function","z":"9469147d85cf6677","name":"min-max 3","func":"if ('reset' in msg) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n return null;\n}\n\n//-------------------------------------------\n\nlet mm = minmax(msg.payload);\n//msg.payload = mm;\nmsg.payload = \"min:\" + mm.sensormin.min + \"@\" + mm.sensormin.timestring + \" \" + \" max:\" + mm.sensormax.max + \"@\" + mm.sensormax.timestring\nreturn msg;\n\n//-------------------------------------------\n\nfunction minmax(value) {\n let x = parseFloat(value);\n let min = context.get('min');\n let max = context.get('max');\n\n if ((min.min === 0) && (max.max === 0)) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time);\n context.set('min', min);\n max.max = x;\n context.set('max', max);\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time);\n }\n else {\n if (x < min.min) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time); \n context.set('min', min);\n }\n if (x > max.max) {\n max.max = x;\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time); \n context.set('max', max);\n }\n }\n return { 'sensormin': min, 'sensormax': max };\n}\n\n//-------------------------------------------\n\nfunction date_time_string(type, time) {\n const date = new Date(time);\n const year = date.getFullYear();\n const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n switch (type) {\n case \"full\":\n return (day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n case \"dayhm\":\n return (day + \"-\" + month + \" @ \" + hours + ':' + minutes);\n case \"hm\":\n return (hours + ':' + minutes);\n case \"hms\":\n return (hours + ':' + minutes + ':' + seconds);\n default:\n return \"error\";\n }\n}\n//-------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\n\nif (context.get(\"min\") === undefined) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n}\n\nif (context.get(\"max\") === undefined) {\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n}\n\ncontext.set(\"max\", { \"max\": 0.0, \"time\": 0 });\ncontext.set(\"min\", { \"min\": 0.0, \"time\": 0 });","finalize":"","libs":[],"x":670,"y":1300,"wires":[["d39eef8cce0191de"]]},{"id":"d39eef8cce0191de","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":8,"width":7,"height":1,"name":"MinMax DG hum","label":"","format":"{{msg.payload}}","layout":"row-left","className":"","style":true,"font":"","fontSize":16,"color":"#009afa","x":870,"y":1300,"wires":[]},{"id":"db26efcf274c2041","type":"function","z":"9469147d85cf6677","name":"min-max 4","func":"if ('reset' in msg) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n return null;\n}\n\n//-------------------------------------------\n\nlet mm = minmax(msg.payload);\n//msg.payload = mm;\nmsg.payload = \"min:\" + mm.sensormin.min + \"@\" + mm.sensormin.timestring + \" \" + \" max:\" + mm.sensormax.max + \"@\" + mm.sensormax.timestring\nreturn msg;\n\n//-------------------------------------------\n\nfunction minmax(value) {\n let x = parseFloat(value);\n let min = context.get('min');\n let max = context.get('max');\n\n if ((min.min === 0) && (max.max === 0)) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time);\n context.set('min', min);\n max.max = x;\n context.set('max', max);\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time);\n }\n else {\n if (x < min.min) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time); \n context.set('min', min);\n }\n if (x > max.max) {\n max.max = x;\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time); \n context.set('max', max);\n }\n }\n return { 'sensormin': min, 'sensormax': max };\n}\n\n//-------------------------------------------\n\nfunction date_time_string(type, time) {\n const date = new Date(time);\n const year = date.getFullYear();\n const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n switch (type) {\n case \"full\":\n return (day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n case \"dayhm\":\n return (day + \"-\" + month + \" @ \" + hours + ':' + minutes);\n case \"hm\":\n return (hours + ':' + minutes);\n case \"hms\":\n return (hours + ':' + minutes + ':' + seconds);\n default:\n return \"error\";\n }\n}\n//-------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\n\nif (context.get(\"min\") === undefined) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n}\n\nif (context.get(\"max\") === undefined) {\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n}\n\ncontext.set(\"max\", { \"max\": 0.0, \"time\": 0 });\ncontext.set(\"min\", { \"min\": 0.0, \"time\": 0 });","finalize":"","libs":[],"x":670,"y":1460,"wires":[["4f12df9e3a082c17"]]},{"id":"4f12df9e3a082c17","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":10,"width":7,"height":1,"name":"MinMax EG hum","label":"","format":"{{msg.payload}}","layout":"row-left","className":"","style":true,"font":"","fontSize":16,"color":"#c905fa","x":870,"y":1460,"wires":[]},{"id":"a7f1665d8c79a58d","type":"inject","z":"9469147d85cf6677","name":"reset min-max","props":[{"p":"reset","v":"0","vt":"num"}],"repeat":"","crontab":"01 00 * * *","once":true,"onceDelay":0.1,"topic":"","x":160,"y":1380,"wires":[["1eda39b888839225","ef5be74544e6ddb9","9f2971a7bac745d7","270fd4f99dc973d3","2017768f0e2fcfb2","8979154ad312dcc8"]]},{"id":"c9c789dd2f7cce7f","type":"function","z":"9469147d85cf6677","name":"min-max 5","func":"if ('reset' in msg) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n return null;\n}\n\n//-------------------------------------------\n\nlet mm = minmax(msg.payload);\n//msg.payload = mm;\nmsg.payload = \"min:\" + mm.sensormin.min + \"@\" + mm.sensormin.timestring + \" \" + \" max:\" + mm.sensormax.max + \"@\" + mm.sensormax.timestring\nreturn msg;\n\n//-------------------------------------------\n\nfunction minmax(value) {\n let x = parseFloat(value);\n let min = context.get('min');\n let max = context.get('max');\n\n if ((min.min === 0) && (max.max === 0)) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time);\n context.set('min', min);\n max.max = x;\n context.set('max', max);\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time);\n }\n else {\n if (x < min.min) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time); \n context.set('min', min);\n }\n if (x > max.max) {\n max.max = x;\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time); \n context.set('max', max);\n }\n }\n return { 'sensormin': min, 'sensormax': max };\n}\n\n//-------------------------------------------\n\nfunction date_time_string(type, time) {\n const date = new Date(time);\n const year = date.getFullYear();\n const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n switch (type) {\n case \"full\":\n return (day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n case \"dayhm\":\n return (day + \"-\" + month + \" @ \" + hours + ':' + minutes);\n case \"hm\":\n return (hours + ':' + minutes);\n case \"hms\":\n return (hours + ':' + minutes + ':' + seconds);\n default:\n return \"error\";\n }\n}\n//-------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\n\nif (context.get(\"min\") === undefined) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n}\n\nif (context.get(\"max\") === undefined) {\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n}\n\ncontext.set(\"max\", { \"max\": 0.0, \"time\": 0 });\ncontext.set(\"min\", { \"min\": 0.0, \"time\": 0 });","finalize":"","libs":[],"x":670,"y":1540,"wires":[["72fb6801bad435d7"]]},{"id":"72fb6801bad435d7","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":13,"width":7,"height":1,"name":"MinMax DG pressure","label":"","format":"{{msg.payload}}","layout":"row-left","className":"","style":true,"font":"","fontSize":16,"color":"#085a02","x":880,"y":1540,"wires":[]},{"id":"66c1c61c4427500d","type":"function","z":"9469147d85cf6677","name":"min-max 6","func":"if ('reset' in msg) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n return null;\n}\n\n//-------------------------------------------\n\nlet mm = minmax(msg.payload);\n//msg.payload = mm;\nmsg.payload = \"min:\" + mm.sensormin.min + \"@\" + mm.sensormin.timestring + \" \" + \" max:\" + mm.sensormax.max + \"@\" + mm.sensormax.timestring\nreturn msg;\n\n//-------------------------------------------\n\nfunction minmax(value) {\n let x = parseFloat(value);\n let min = context.get('min');\n let max = context.get('max');\n\n if ((min.min === 0) && (max.max === 0)) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time);\n context.set('min', min);\n max.max = x;\n context.set('max', max);\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time);\n }\n else {\n if (x < min.min) {\n min.min = x;\n min.time = Date.now();\n min.timestring = date_time_string(\"hms\", min.time); \n context.set('min', min);\n }\n if (x > max.max) {\n max.max = x;\n max.time = Date.now();\n max.timestring = date_time_string(\"hms\", max.time); \n context.set('max', max);\n }\n }\n return { 'sensormin': min, 'sensormax': max };\n}\n\n//-------------------------------------------\n\nfunction date_time_string(type, time) {\n const date = new Date(time);\n const year = date.getFullYear();\n const month = (\"0\" + (date.getMonth() + 1)).slice(-2);\n const day = (\"0\" + date.getDate()).slice(-2);\n const hours = (\"0\" + date.getHours()).slice(-2);\n const minutes = (\"0\" + date.getMinutes()).slice(-2);\n const seconds = (\"0\" + date.getSeconds()).slice(-2);\n switch (type) {\n case \"full\":\n return (day + \"-\" + month + \"-\" + year + \" \" + hours + ':' + minutes + ':' + seconds);\n case \"dayhm\":\n return (day + \"-\" + month + \" @ \" + hours + ':' + minutes);\n case \"hm\":\n return (hours + ':' + minutes);\n case \"hms\":\n return (hours + ':' + minutes + ':' + seconds);\n default:\n return \"error\";\n }\n}\n//-------------------------------------------","outputs":1,"noerr":0,"initialize":"// Code added here will be run once\n// whenever the node is started.\n\nnode.send({ payload: \" \" });\n\nif (context.get(\"min\") === undefined) {\n context.set(\"min\", { \"min\": 0.0, \"time\": 0 });\n}\n\nif (context.get(\"max\") === undefined) {\n context.set(\"max\", { \"max\": 0.0, \"time\": 0 });\n}\n\ncontext.set(\"max\", { \"max\": 0.0, \"time\": 0 });\ncontext.set(\"min\", { \"min\": 0.0, \"time\": 0 });","finalize":"","libs":[],"x":670,"y":1700,"wires":[["81412ea9a1684342"]]},{"id":"81412ea9a1684342","type":"ui_text","z":"9469147d85cf6677","group":"e25da20c3f5e7e14","order":15,"width":7,"height":1,"name":"MinMax EG pressure","label":"","format":"{{msg.payload}}","layout":"row-left","className":"","style":true,"font":"","fontSize":16,"color":"#02f79a","x":880,"y":1700,"wires":[]},{"id":"ae7a8dfda327534b","type":"rbe","z":"9469147d85cf6677","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":730,"y":700,"wires":[["e0d9897067903b74"]]},{"id":"cf4c07623a4e6356","type":"rbe","z":"9469147d85cf6677","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":970,"y":760,"wires":[["1639c3429e39a280"]]},{"id":"c127da1edf11c4b1","type":"rbe","z":"9469147d85cf6677","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":730,"y":820,"wires":[["5b9eee080d2ceadf"]]},{"id":"c592dd966564bb48","type":"rbe","z":"9469147d85cf6677","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":730,"y":200,"wires":[["dc86c5bcf1a87e95"]]},{"id":"cfc47b7f7bf05c1a","type":"rbe","z":"9469147d85cf6677","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":730,"y":320,"wires":[["70cec064a08c4d28"]]},{"id":"a193dd2f9c6cfd59","type":"rbe","z":"9469147d85cf6677","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","topi":"topic","x":970,"y":260,"wires":[["1c8850add7c6caeb"]]},{"id":"bbf73e0d92f09b71","type":"ui_gauge","z":"9469147d85cf6677","name":"Voltage Gauge DG","group":"e25da20c3f5e7e14","order":18,"width":5,"height":5,"gtype":"gage","title":"{{msg.topic}}","label":"%","format":"{{msg.payload}}","min":0,"max":"100","colors":["#ff1605","#e6e600","#15f919"],"seg1":"","seg2":"","diff":false,"className":"","x":870,"y":1780,"wires":[]},{"id":"d2774f2293a0db2e","type":"ui_gauge","z":"9469147d85cf6677","name":"Linkquality Gauge DG","group":"e25da20c3f5e7e14","order":19,"width":5,"height":5,"gtype":"gage","title":"{{msg.topic}}","label":"%","format":"{{msg.payload}}","min":0,"max":"100","colors":["#ff1605","#e6e600","#15f919"],"seg1":"","seg2":"","diff":false,"className":"","x":880,"y":1820,"wires":[]},{"id":"1a447fa539cb55bc","type":"ui_gauge","z":"9469147d85cf6677","name":"Voltage Gauge EG","group":"e25da20c3f5e7e14","order":21,"width":5,"height":5,"gtype":"gage","title":"{{msg.topic}}","label":"%","format":"{{msg.payload}}","min":0,"max":"100","colors":["#ff1605","#e6e600","#15f919"],"seg1":"","seg2":"","diff":false,"className":"","x":870,"y":1880,"wires":[]},{"id":"54d2cb8aa6440b80","type":"ui_gauge","z":"9469147d85cf6677","name":"Linkquality Gauge EG","group":"e25da20c3f5e7e14","order":22,"width":5,"height":5,"gtype":"gage","title":"{{msg.topic}}","label":"%","format":"{{msg.payload}}","min":0,"max":"100","colors":["#ff1605","#e6e600","#15f919"],"seg1":"","seg2":"","diff":false,"className":"","x":880,"y":1920,"wires":[]},{"id":"7e36b69a32424ce0","type":"function","z":"9469147d85cf6677","name":"function 5","func":"node.status({ fill: \"grey\", shape: \"dot\", text: (msg.payload + \" mVolt\") });\n//msg.payload = msg.payload/1000;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":600,"y":380,"wires":[["a2f944c7ae234459"]]},{"id":"a2f944c7ae234459","type":"function","z":"9469147d85cf6677","name":"function 2","func":"node.status({ fill: \"grey\", shape: \"dot\", text: (msg.payload/1000 + \" Volt\")});\n//msg.payload = msg.payload/1000;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":740,"y":380,"wires":[["623d4980c7070999"]]},{"id":"623d4980c7070999","type":"function","z":"9469147d85cf6677","name":"function 6","func":"let t = parseFloat((msg.payload*100/3000).toFixed(2));\nnode.status({ fill: \"grey\", shape: \"dot\", text: (t + \" %\")});\n\nif (context.get('last_value') === 0) {\n msg.topic = \"Batterie DG\";\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.topic = \"Batterie DG\" + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.topic = \"Batterie DG\" + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.topic = \"Batterie DG\" + ' ' + '';\n}\ncontext.set('last_value', msg.payload);\nmsg.payload = t;\n\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload:\"\", topic: \"\" });\ncontext.set('last_value', 0);","finalize":"","libs":[],"x":880,"y":380,"wires":[["3a7b29b82506eccc"]]},{"id":"896993ca0eb04572","type":"function","z":"9469147d85cf6677","name":"function 7","func":"let t = parseFloat((msg.payload).toFixed(2));\nnode.status({ fill: \"grey\", shape: \"dot\", text: (t + \" %\")});\n\nif (context.get('last_value') === 0) {\n msg.topic = \"Linkquality DG\";\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.topic = \"Linkquality DG\" + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.topic = \"Linkquality DG\" + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.topic = \"Linkquality DG\" + ' ' + '';\n}\ncontext.set('last_value', msg.payload);\nmsg.payload = t;\n\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload:\"\", topic: \"\" });\ncontext.set('last_value', 0);","finalize":"","libs":[],"x":880,"y":440,"wires":[["42d1b99abd60f5bb"]]},{"id":"53a578afa55e71e9","type":"function","z":"9469147d85cf6677","name":"function 8","func":"node.status({ fill: \"grey\", shape: \"dot\", text: (msg.payload/1000 + \" Volt\")});\n//msg.payload = msg.payload/1000;\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":740,"y":880,"wires":[["1a0b33fcb167bd34"]]},{"id":"1a0b33fcb167bd34","type":"function","z":"9469147d85cf6677","name":"function 9","func":"let t = parseFloat((msg.payload*100/3000).toFixed(2));\nnode.status({ fill: \"grey\", shape: \"dot\", text: (t + \" %\")});\n\nif (context.get('last_value') === 0) {\n msg.topic = \"Batterie DG\";\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.topic = \"Batterie DG\" + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.topic = \"Batterie DG\" + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.topic = \"Batterie DG\" + ' ' + '';\n}\ncontext.set('last_value', msg.payload);\nmsg.payload = t;\n\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload:\"\", topic: \"\" });\ncontext.set('last_value', 0);","finalize":"","libs":[],"x":880,"y":880,"wires":[["6e72c15ffce19a94"]]},{"id":"9243b3dda61b885d","type":"function","z":"9469147d85cf6677","name":"function 10","func":"let t = parseFloat((msg.payload).toFixed(2));\nnode.status({ fill: \"grey\", shape: \"dot\", text: (t + \" %\")});\n\nif (context.get('last_value') === 0) {\n msg.topic = \"Linkquality DG\";\n}\nelse if (msg.payload < context.get('last_value')) {\n msg.topic = \"Linkquality DG\" + ' ' + '';\n}\nelse if (msg.payload === context.get('last_value')) {\n msg.topic = \"Linkquality DG\" + ' ' + '';\n}\nelse if (msg.payload > context.get('last_value')) {\n msg.topic = \"Linkquality DG\" + ' ' + '';\n}\ncontext.set('last_value', msg.payload);\nmsg.payload = t;\n\nreturn msg;\n","outputs":1,"noerr":0,"initialize":"// Der Code hier wird ausgeführt,\n// wenn der Node gestartet wird\n\nnode.send({ payload:\"\", topic: \"\" });\ncontext.set('last_value', 0);","finalize":"","libs":[],"x":870,"y":940,"wires":[["06b7f56076268bbf"]]},{"id":"3a7b29b82506eccc","type":"link out","z":"9469147d85cf6677","name":"link out 7","mode":"link","links":["8b6e15fc2acde8dc"],"x":975,"y":380,"wires":[]},{"id":"42d1b99abd60f5bb","type":"link out","z":"9469147d85cf6677","name":"link out 8","mode":"link","links":["79b9e9835220e4f7"],"x":975,"y":440,"wires":[]},{"id":"8b6e15fc2acde8dc","type":"link in","z":"9469147d85cf6677","name":"voltage DG in","links":["3a7b29b82506eccc"],"x":525,"y":1780,"wires":[["bbf73e0d92f09b71"]]},{"id":"a633564afc87def2","type":"link in","z":"9469147d85cf6677","name":"Voltage EG in","links":["6e72c15ffce19a94"],"x":525,"y":1880,"wires":[["1a447fa539cb55bc"]]},{"id":"79b9e9835220e4f7","type":"link in","z":"9469147d85cf6677","name":"Linkquality in DG","links":["42d1b99abd60f5bb"],"x":525,"y":1820,"wires":[["d2774f2293a0db2e"]]},{"id":"9b26ed64ebf0d2f7","type":"link in","z":"9469147d85cf6677","name":"Linkquality in EG","links":["06b7f56076268bbf"],"x":525,"y":1920,"wires":[["54d2cb8aa6440b80"]]},{"id":"6e72c15ffce19a94","type":"link out","z":"9469147d85cf6677","name":"link out 9","mode":"link","links":["a633564afc87def2"],"x":975,"y":880,"wires":[]},{"id":"06b7f56076268bbf","type":"link out","z":"9469147d85cf6677","name":"link out 10","mode":"link","links":["9b26ed64ebf0d2f7"],"x":975,"y":940,"wires":[]}]