-
-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hue Group/Hue Light node status is not updating #353
Comments
Did you check the logs in NodeRed? 30 Mar 05:33:11 - [info] [hue-bridge:Philips hue] Initializing the bridge (192.168.0.60)… |
Same here. Groups are on, but status says they are off. I'm unable to turn them off as it does not accept the "false" for switching the group off |
I have been getting the same issue for some time now with v4. |
Same problem here. After restart modeled the status is right. I have this problem since 4.2.2. Before it was working correct |
Same issue here, effectively rendering HueMagic unusable in my setting. Any idea / fix? |
Same issue here. |
I made the change as per pr #349 i linked above and so far much more stable. I would hope author puts into production :( |
This is related to wrong Id/rid used in HueMagic. In the Case of a light HueMagic is using the "rid" for a light instead of the ID. The ID is directly the Name of a lamp, the rid is a "service" grouping lamps or used in scenes to recall them. So that is actually where all the bugs come from. |
Would you then have a functional https request for switching scenes? I got individual lamps and rooms sorted... but for scenes there seem to be a a differing syntax / behavior. |
@moeb98 yep import the flow and you have everything :) [{"id":"e043f290.31992","type":"subflow","name":"HUE T/B/F","info":"","category":"","in":[{"x":140,"y":280,"wires":[{"id":"d2ab207e.d1223"}]}],"out":[{"x":840,"y":200,"wires":[{"id":"4f477421.76448c","port":0}]},{"x":840,"y":280,"wires":[{"id":"4f477421.76448c","port":0},{"id":"7f331a5b.489834","port":0}]},{"x":840,"y":360,"wires":[{"id":"7f331a5b.489834","port":0}]}],"env":[],"color":"#DDAA99"},{"id":"48b0e695.cce208","type":"rbe","z":"e043f290.31992","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","x":550,"y":200,"wires":[["4f477421.76448c"]]},{"id":"4f477421.76448c","type":"switch","z":"e043f290.31992","name":"","property":"payload","propertyType":"msg","rules":[{"t":"true"}],"checkall":"true","repair":false,"outputs":1,"x":670,"y":200,"wires":[[]]},{"id":"ed5627d5.5616e8","type":"change","z":"e043f290.31992","name":"False","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":160,"wires":[["3251c721.4f39f8"]]},{"id":"3251c721.4f39f8","type":"delay","z":"e043f290.31992","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":670,"y":160,"wires":[["48b0e695.cce208"]]},{"id":"f54e9a54.9cdbb8","type":"change","z":"e043f290.31992","name":"True","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":240,"wires":[["48b0e695.cce208"]]},{"id":"edd9893a.8225f8","type":"delay","z":"e043f290.31992","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":670,"y":400,"wires":[["da5c4468.9b2ae8"]]},{"id":"da5c4468.9b2ae8","type":"rbe","z":"e043f290.31992","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","x":550,"y":360,"wires":[["7f331a5b.489834"]]},{"id":"c3320be9.ac8888","type":"change","z":"e043f290.31992","name":"false","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":320,"wires":[["da5c4468.9b2ae8"]]},{"id":"9162dd10.87d94","type":"change","z":"e043f290.31992","name":"true","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":400,"wires":[["edd9893a.8225f8"]]},{"id":"7f331a5b.489834","type":"switch","z":"e043f290.31992","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"}],"checkall":"true","repair":false,"outputs":1,"x":670,"y":360,"wires":[[]]},{"id":"d2ab207e.d1223","type":"switch","z":"e043f290.31992","name":"true / false","property":"payload.data.0.on.on","propertyType":"msg","rules":[{"t":"true"},{"t":"false"}],"checkall":"true","repair":false,"outputs":2,"x":270,"y":280,"wires":[["f54e9a54.9cdbb8","ed5627d5.5616e8"],["c3320be9.ac8888","9162dd10.87d94"]]},{"id":"5b5e8992.a1e968","type":"tab","label":"Flow 1","disabled":true,"info":""},{"id":"6c1b6660.683bb8","type":"inject","z":"5b5e8992.a1e968","name":"Get all lights","props":[{"p":"endpoint","v":"/light","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":570,"y":400,"wires":[["f606c01f.79e19"]]},{"id":"a7ca4d21.77a85","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1210,"y":300,"wires":[]},{"id":"d68dfa3a.e2db08","type":"inject","z":"5b5e8992.a1e968","name":"Get all scenes","props":[{"p":"endpoint","v":"scene","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":520,"wires":[["f606c01f.79e19"]]},{"id":"4e270fba.bc1dc","type":"inject","z":"5b5e8992.a1e968","name":"Get all rooms","props":[{"p":"endpoint","v":"room","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":480,"wires":[["f606c01f.79e19"]]},{"id":"b7964778.8610a8","type":"inject","z":"5b5e8992.a1e968","name":"Get all zones","props":[{"p":"endpoint","v":"zone","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":440,"wires":[["f606c01f.79e19"]]},{"id":"f606c01f.79e19","type":"function","z":"5b5e8992.a1e968","name":"HUE API V2 ","func":"\n// you can copy the user from the hue config node\nvar user = "FS9pMDGj6x2D3xxxxxxxxxxxxIpaRWtOYh6TTIR";\n\n\nif(msg.endpoint === undefined)\n msg.url = "https://192.168.0.40/clip/v2/resource";\nelse if(msg.topic === undefined)\n msg.url = "https://192.168.0.40/clip/v2/resource/" + msg.endpoint;\nelse\n msg.url = "https://192.168.0.40/clip/v2/resource/" + msg.endpoint + "/" + msg.topic;\n\n\nmsg.headers = {};\n\nmsg.headers['hue-application-key'] = user;\nmsg.headers['Content-Type'] = 'application/json';\nmsg.headers['Accept'] = 'application/json';\n\nif(msg.payload != undefined)\n msg.headers['ContentLength'] = JSON.stringify(msg.payload).length;\n\nif(msg.verb === undefined)\n msg.method = "get";\nelse\n msg.method = msg.verb;\n\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":970,"y":520,"wires":[["eed9e69b.007388"]]},{"id":"73217c65.f09664","type":"inject","z":"5b5e8992.a1e968","name":"Get All","props":[],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":590,"y":200,"wires":[["f606c01f.79e19"]]},{"id":"716103e9.1c992c","type":"debug","z":"5b5e8992.a1e968","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":950,"y":580,"wires":[]},{"id":"200c1445.78c9cc","type":"philipshue-events","z":"5b5e8992.a1e968","bridge":"e655611b.33c428","x":560,"y":560,"wires":[["716103e9.1c992c","184f75da.cdd52a","bf5e720b.40a8","60e1725f.f8ed3c"]]},{"id":"eed9e69b.007388","type":"http request","z":"5b5e8992.a1e968","name":"https request HUE API V2","method":"use","ret":"obj","paytoqs":"ignore","url":"","tls":"4bc31af9bd03bbdc","persist":false,"proxy":"","authType":"","x":1010,"y":320,"wires":[["a7ca4d21.77a85"]]},{"id":"c5665762.670398","type":"inject","z":"5b5e8992.a1e968","name":"bridge_home","props":[{"p":"endpoint","v":"bridge_home","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":570,"y":360,"wires":[["f606c01f.79e19"]]},{"id":"bfd43929.176638","type":"inject","z":"5b5e8992.a1e968","name":"Motion","props":[{"p":"endpoint","v":"motion","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":590,"y":280,"wires":[["f606c01f.79e19"]]},{"id":"139b32d3.3f289d","type":"inject","z":"5b5e8992.a1e968","name":"Temperature","props":[{"p":"endpoint","v":"temperature","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":320,"wires":[["f606c01f.79e19"]]},{"id":"88b5c34f.4f78f","type":"inject","z":"5b5e8992.a1e968","name":"Button","props":[{"p":"endpoint","v":"button ","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":590,"y":240,"wires":[["f606c01f.79e19"]]},{"id":"6f060c88.c3f284","type":"change","z":"5b5e8992.a1e968","name":"Scene an","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"scene","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"8b11399c-90c8-4cb9-b4c0-84b91d0e9e0c","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"recall": {"action": "active"}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":800,"y":800,"wires":[["f606c01f.79e19"]],"icon":"font-awesome/fa-star"},{"id":"3f1bc5e8.2ef64a","type":"change","z":"5b5e8992.a1e968","name":"Lampe an","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"51f787b8-793b-46ce-8eb9-f8ca38601716","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":true},"dimming":{"brightness":100},"dynamics":{"duration":1000},"color_temperature":{"mirek":330}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":800,"y":1060,"wires":[["f606c01f.79e19"]]},{"id":"d5aa770b.998248","type":"change","z":"5b5e8992.a1e968","name":"Lampe aus","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"51f787b8-793b-46ce-8eb9-f8ca38601716","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":false}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":810,"y":1100,"wires":[["f606c01f.79e19"]]},{"id":"df6df66b.d8f5d8","type":"change","z":"5b5e8992.a1e968","name":"Wohnen Gruppe Off","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"grouped_light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"58b37623-32c1-4b7e-89b9-2bb0679de9a3","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":false}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":700,"y":3160,"wires":[[]]},{"id":"2844d045.de641","type":"change","z":"5b5e8992.a1e968","name":"Raum / Gruppe aus aus","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"grouped_light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"f231d79f-a79c-4c0c-913a-38067a404960","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":false}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":750,"y":900,"wires":[["f606c01f.79e19"]]},{"id":"184f75da.cdd52a","type":"switch","z":"5b5e8992.a1e968","name":"BM Rückmeldung Bewegung","property":"payload.data.0.id","propertyType":"msg","rules":[{"t":"cont","v":"3b668baa-aa25-4e41-9d2d-ba7f0a335716","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1540,"y":920,"wires":[["5325d2a9.1e104c"]]},{"id":"5325d2a9.1e104c","type":"switch","z":"5b5e8992.a1e968","name":"","property":"payload.data.0.motion.motion","propertyType":"msg","rules":[{"t":"true"},{"t":"false"}],"checkall":"true","repair":false,"outputs":2,"x":1715,"y":920,"wires":[["a91d05c5.45f118"],["828e4be0.f65fc8"]],"l":false},{"id":"a91d05c5.45f118","type":"change","z":"5b5e8992.a1e968","name":"T","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":1835,"y":900,"wires":[["1f7d9d60.78f3a3","aff8a932.e3fd08"]],"l":false},{"id":"828e4be0.f65fc8","type":"change","z":"5b5e8992.a1e968","name":"F","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":1835,"y":940,"wires":[["1f7d9d60.78f3a3","aff8a932.e3fd08"]],"l":false},{"id":"1f7d9d60.78f3a3","type":"link out","z":"5b5e8992.a1e968","name":"","links":[],"x":1965,"y":940,"wires":[]},{"id":"e627e64b.d84938","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":640,"y":800,"wires":[["6f060c88.c3f284"]]},{"id":"67808335.6ac79c","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":560,"y":900,"wires":[["2844d045.de641"]]},{"id":"8a7c8418.2cc6b8","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":660,"y":1100,"wires":[["d5aa770b.998248"]]},{"id":"73cbdb3c.fb89a4","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":640,"y":1060,"wires":[["3f1bc5e8.2ef64a"]]},{"id":"aff8a932.e3fd08","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1970,"y":1020,"wires":[]},{"id":"beb1273a.8bd508","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":800,"wires":[["6f060c88.c3f284"]]},{"id":"fa1d1534.8ebb38","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":840,"wires":[["2844d045.de641"]]},{"id":"75674464.2140bc","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":900,"wires":[["3f1bc5e8.2ef64a"]]},{"id":"d901bef2.176b2","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":980,"wires":[["d5aa770b.998248"]]},{"id":"60e1725f.f8ed3c","type":"switch","z":"5b5e8992.a1e968","name":"Button Rückmeldung","property":"payload.data.0.id","propertyType":"msg","rules":[{"t":"cont","v":"5c81acc1-5a1d-4002-a823-c71701daa261","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1500,"y":700,"wires":[["59dcb14c.7763a"]]},{"id":"70327268.022b9c","type":"change","z":"5b5e8992.a1e968","name":"True","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":1775,"y":700,"wires":[["ca53d55d.4a9ac8"]],"l":false},{"id":"59dcb14c.7763a","type":"switch","z":"5b5e8992.a1e968","name":"","property":"payload.data.0.button.last_event","propertyType":"msg","rules":[{"t":"cont","v":"initial_press","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1675,"y":700,"wires":[["70327268.022b9c"]],"l":false},{"id":"bf5e720b.40a8","type":"switch","z":"5b5e8992.a1e968","name":"Lampe feedback","property":"payload.data.0.id","propertyType":"msg","rules":[{"t":"cont","v":"c8a23b2f-b205-4f19-98ed-e694193c9458","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1470,"y":780,"wires":[["d965b08f.7500a"]]},{"id":"d965b08f.7500a","type":"subflow:e043f290.31992","z":"5b5e8992.a1e968","name":"","x":1710,"y":780,"wires":[["ed362fba.04804"],["43217f5b.9be35"],["72ef9320.c9275c"]]},{"id":"43217f5b.9be35","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2080,"y":740,"wires":[]},{"id":"72ef9320.c9275c","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2070,"y":800,"wires":[]},{"id":"ed362fba.04804","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2070,"y":680,"wires":[]},{"id":"ca53d55d.4a9ac8","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1960,"y":600,"wires":[]},{"id":"e655611b.33c428","type":"philipshue-events-config","address":"192.168.0.31","applicationkey":"ZWGBRgQip5R79dbjM-9H9t5-V0xIlBjoGO4vd4Wc"},{"id":"4bc31af9bd03bbdc","type":"tls-config","name":"","cert":"","key":"","ca":"","certname":"","keyname":"","caname":"","servername":"","verifyservercert":false}] |
woohooo, thanks mate… will try asap.
Am Montag, Juni 6, 2022, 1:55 PM schrieb andesse ***@***.***>:
@moeb98 yep import the flow and you have everything :)
[{"id":"e043f290.31992","type":"subflow","name":"HUE T/B/F","info":"","category":"","in":[{"x":140,"y":280,"wires":[{"id":"d2ab207e.d1223"}]}],"out":[{"x":840,"y":200,"wires":[{"id":"4f477421.76448c","port":0}]},{"x":840,"y":280,"wires":[{"id":"4f477421.76448c","port":0},{"id":"7f331a5b.489834","port":0}]},{"x":840,"y":360,"wires":[{"id":"7f331a5b.489834","port":0}]}],"env":[],"color":"#DDAA99"},{"id":"48b0e695.cce208","type":"rbe","z":"e043f290.31992","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","x":550,"y":200,"wires":[["4f477421.76448c"]]},{"id":"4f477421.76448c","type":"switch","z":"e043f290.31992","name":"","property":"payload","propertyType":"msg","rules":[{"t":"true"}],"checkall":"true","repair":false,"outputs":1,"x":670,"y":200,"wires":[[]]},{"id":"ed5627d5.5616e8","type":"change","z":"e043f290.31992","name":"False","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":160,"wires":[["3251c721.4f39f8"]]},{"id":"3251c721.4f39f8","type":"delay","z":"e043f290.31992","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":670,"y":160,"wires":[["48b0e695.cce208"]]},{"id":"f54e9a54.9cdbb8","type":"change","z":"e043f290.31992","name":"True","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":240,"wires":[["48b0e695.cce208"]]},{"id":"edd9893a.8225f8","type":"delay","z":"e043f290.31992","name":"1s","pauseType":"delay","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":670,"y":400,"wires":[["da5c4468.9b2ae8"]]},{"id":"da5c4468.9b2ae8","type":"rbe","z":"e043f290.31992","name":"","func":"rbe","gap":"","start":"","inout":"out","septopics":true,"property":"payload","x":550,"y":360,"wires":[["7f331a5b.489834"]]},{"id":"c3320be9.ac8888","type":"change","z":"e043f290.31992","name":"false","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":320,"wires":[["da5c4468.9b2ae8"]]},{"id":"9162dd10.87d94","type":"change","z":"e043f290.31992","name":"true","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":400,"wires":[["edd9893a.8225f8"]]},{"id":"7f331a5b.489834","type":"switch","z":"e043f290.31992","name":"","property":"payload","propertyType":"msg","rules":[{"t":"false"}],"checkall":"true","repair":false,"outputs":1,"x":670,"y":360,"wires":[[]]},{"id":"d2ab207e.d1223","type":"switch","z":"e043f290.31992","name":"true / false","property":"payload.data.0.on.on","propertyType":"msg","rules":[{"t":"true"},{"t":"false"}],"checkall":"true","repair":false,"outputs":2,"x":270,"y":280,"wires":[["f54e9a54.9cdbb8","ed5627d5.5616e8"],["c3320be9.ac8888","9162dd10.87d94"]]},{"id":"5b5e8992.a1e968","type":"tab","label":"Flow 1","disabled":true,"info":""},{"id":"6c1b6660.683bb8","type":"inject","z":"5b5e8992.a1e968","name":"Get all lights","props":[{"p":"endpoint","v":"/light","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":570,"y":400,"wires":[["f606c01f.79e19"]]},{"id":"a7ca4d21.77a85","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":1210,"y":300,"wires":[]},{"id":"d68dfa3a.e2db08","type":"inject","z":"5b5e8992.a1e968","name":"Get all scenes","props":[{"p":"endpoint","v":"scene","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":520,"wires":[["f606c01f.79e19"]]},{"id":"4e270fba.bc1dc","type":"inject","z":"5b5e8992.a1e968","name":"Get all rooms","props":[{"p":"endpoint","v":"room","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":480,"wires":[["f606c01f.79e19"]]},{"id":"b7964778.8610a8","type":"inject","z":"5b5e8992.a1e968","name":"Get all zones","props":[{"p":"endpoint","v":"zone","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":440,"wires":[["f606c01f.79e19"]]},{"id":"f606c01f.79e19","type":"function","z":"5b5e8992.a1e968","name":"HUE API V2 ","func":"\n// you can copy the user from the hue config node\nvar user = "FS9pMDGj6x2D3xxxxxxxxxxxxIpaRWtOYh6TTIR";\n\n\nif(msg.endpoint === undefined)\n msg.url = "https://192.168.0.40/clip/v2/resource";\nelse if(msg.topic === undefined)\n msg.url = "https://192.168.0.40/clip/v2/resource/" + msg.endpoint;\nelse\n msg.url = "https://192.168.0.40/clip/v2/resource/" + msg.endpoint + "/" + msg.topic;\n\n\nmsg.headers = {};\n\nmsg.headers['hue-application-key'] = user;\nmsg.headers['Content-Type'] = 'application/json';\nmsg.headers['Accept'] = 'application/json';\n\nif(msg.payload != undefined)\n msg.headers['ContentLength'] = JSON.stringify(msg.payload).length;\n\nif(msg.verb === undefined)\n msg.method = "get";\nelse\n msg.method = msg.verb;\n\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":970,"y":520,"wires":[["eed9e69b.007388"]]},{"id":"73217c65.f09664","type":"inject","z":"5b5e8992.a1e968","name":"Get All","props":[],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":590,"y":200,"wires":[["f606c01f.79e19"]]},{"id":"716103e9.1c992c","type":"debug","z":"5b5e8992.a1e968","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":950,"y":580,"wires":[]},{"id":"200c1445.78c9cc","type":"philipshue-events","z":"5b5e8992.a1e968","bridge":"e655611b.33c428","x":560,"y":560,"wires":[["716103e9.1c992c","184f75da.cdd52a","bf5e720b.40a8","60e1725f.f8ed3c"]]},{"id":"eed9e69b.007388","type":"http request","z":"5b5e8992.a1e968","name":"https request HUE API V2","method":"use","ret":"obj","paytoqs":"ignore","url":"","tls":"4bc31af9bd03bbdc","persist":false,"proxy":"","authType":"","x":1010,"y":320,"wires":[["a7ca4d21.77a85"]]},{"id":"c5665762.670398","type":"inject","z":"5b5e8992.a1e968","name":"bridge_home","props":[{"p":"endpoint","v":"bridge_home","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":570,"y":360,"wires":[["f606c01f.79e19"]]},{"id":"bfd43929.176638","type":"inject","z":"5b5e8992.a1e968","name":"Motion","props":[{"p":"endpoint","v":"motion","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":590,"y":280,"wires":[["f606c01f.79e19"]]},{"id":"139b32d3.3f289d","type":"inject","z":"5b5e8992.a1e968","name":"Temperature","props":[{"p":"endpoint","v":"temperature","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":570,"y":320,"wires":[["f606c01f.79e19"]]},{"id":"88b5c34f.4f78f","type":"inject","z":"5b5e8992.a1e968","name":"Button","props":[{"p":"endpoint","v":"button ","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payloadType":"str","x":590,"y":240,"wires":[["f606c01f.79e19"]]},{"id":"6f060c88.c3f284","type":"change","z":"5b5e8992.a1e968","name":"Scene an","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"scene","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"8b11399c-90c8-4cb9-b4c0-84b91d0e9e0c","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"recall": {"action": "active"}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":800,"y":800,"wires":[["f606c01f.79e19"]],"icon":"font-awesome/fa-star"},{"id":"3f1bc5e8.2ef64a","type":"change","z":"5b5e8992.a1e968","name":"Lampe an","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"51f787b8-793b-46ce-8eb9-f8ca38601716","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":true},"dimming":{"brightness":100},"dynamics":{"duration":1000},"color_temperature":{"mirek":330}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":800,"y":1060,"wires":[["f606c01f.79e19"]]},{"id":"d5aa770b.998248","type":"change","z":"5b5e8992.a1e968","name":"Lampe aus","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"51f787b8-793b-46ce-8eb9-f8ca38601716","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":false}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":810,"y":1100,"wires":[["f606c01f.79e19"]]},{"id":"df6df66b.d8f5d8","type":"change","z":"5b5e8992.a1e968","name":"Wohnen Gruppe Off","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"grouped_light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"58b37623-32c1-4b7e-89b9-2bb0679de9a3","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":false}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":700,"y":3160,"wires":[[]]},{"id":"2844d045.de641","type":"change","z":"5b5e8992.a1e968","name":"Raum / Gruppe aus aus","rules":[{"t":"set","p":"endpoint","pt":"msg","to":"grouped_light","tot":"str"},{"t":"set","p":"topic","pt":"msg","to":"f231d79f-a79c-4c0c-913a-38067a404960","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"{"on":{"on":false}}","tot":"json"},{"t":"set","p":"verb","pt":"msg","to":"put","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":750,"y":900,"wires":[["f606c01f.79e19"]]},{"id":"184f75da.cdd52a","type":"switch","z":"5b5e8992.a1e968","name":"BM Rückmeldung Bewegung","property":"payload.data.0.id","propertyType":"msg","rules":[{"t":"cont","v":"3b668baa-aa25-4e41-9d2d-ba7f0a335716","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1540,"y":920,"wires":[["5325d2a9.1e104c"]]},{"id":"5325d2a9.1e104c","type":"switch","z":"5b5e8992.a1e968","name":"","property":"payload.data.0.motion.motion","propertyType":"msg","rules":[{"t":"true"},{"t":"false"}],"checkall":"true","repair":false,"outputs":2,"x":1715,"y":920,"wires":[["a91d05c5.45f118"],["828e4be0.f65fc8"]],"l":false},{"id":"a91d05c5.45f118","type":"change","z":"5b5e8992.a1e968","name":"T","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":1835,"y":900,"wires":[["1f7d9d60.78f3a3","aff8a932.e3fd08"]],"l":false},{"id":"828e4be0.f65fc8","type":"change","z":"5b5e8992.a1e968","name":"F","rules":[{"t":"set","p":"payload","pt":"msg","to":"false","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":1835,"y":940,"wires":[["1f7d9d60.78f3a3","aff8a932.e3fd08"]],"l":false},{"id":"1f7d9d60.78f3a3","type":"link out","z":"5b5e8992.a1e968","name":"","links":[],"x":1965,"y":940,"wires":[]},{"id":"e627e64b.d84938","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":640,"y":800,"wires":[["6f060c88.c3f284"]]},{"id":"67808335.6ac79c","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":560,"y":900,"wires":[["2844d045.de641"]]},{"id":"8a7c8418.2cc6b8","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":660,"y":1100,"wires":[["d5aa770b.998248"]]},{"id":"73cbdb3c.fb89a4","type":"inject","z":"5b5e8992.a1e968","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":640,"y":1060,"wires":[["3f1bc5e8.2ef64a"]]},{"id":"aff8a932.e3fd08","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1970,"y":1020,"wires":[]},{"id":"beb1273a.8bd508","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":800,"wires":[["6f060c88.c3f284"]]},{"id":"fa1d1534.8ebb38","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":840,"wires":[["2844d045.de641"]]},{"id":"75674464.2140bc","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":900,"wires":[["3f1bc5e8.2ef64a"]]},{"id":"d901bef2.176b2","type":"link in","z":"5b5e8992.a1e968","name":"","links":[],"x":115,"y":980,"wires":[["d5aa770b.998248"]]},{"id":"60e1725f.f8ed3c","type":"switch","z":"5b5e8992.a1e968","name":"Button Rückmeldung","property":"payload.data.0.id","propertyType":"msg","rules":[{"t":"cont","v":"5c81acc1-5a1d-4002-a823-c71701daa261","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1500,"y":700,"wires":[["59dcb14c.7763a"]]},{"id":"70327268.022b9c","type":"change","z":"5b5e8992.a1e968","name":"True","rules":[{"t":"set","p":"payload","pt":"msg","to":"true","tot":"bool"}],"action":"","property":"","from":"","to":"","reg":false,"x":1775,"y":700,"wires":[["ca53d55d.4a9ac8"]],"l":false},{"id":"59dcb14c.7763a","type":"switch","z":"5b5e8992.a1e968","name":"","property":"payload.data.0.button.last_event","propertyType":"msg","rules":[{"t":"cont","v":"initial_press","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1675,"y":700,"wires":[["70327268.022b9c"]],"l":false},{"id":"bf5e720b.40a8","type":"switch","z":"5b5e8992.a1e968","name":"Lampe feedback","property":"payload.data.0.id","propertyType":"msg","rules":[{"t":"cont","v":"c8a23b2f-b205-4f19-98ed-e694193c9458","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":1470,"y":780,"wires":[["d965b08f.7500a"]]},{"id":"d965b08f.7500a","type":"subflow:e043f290.31992","z":"5b5e8992.a1e968","name":"","x":1710,"y":780,"wires":[["ed362fba.04804"],["43217f5b.9be35"],["72ef9320.c9275c"]]},{"id":"43217f5b.9be35","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2080,"y":740,"wires":[]},{"id":"72ef9320.c9275c","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2070,"y":800,"wires":[]},{"id":"ed362fba.04804","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":2070,"y":680,"wires":[]},{"id":"ca53d55d.4a9ac8","type":"debug","z":"5b5e8992.a1e968","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":1960,"y":600,"wires":[]},{"id":"e655611b.33c428","type":"philipshue-events-config","address":"192.168.0.31","applicationkey":"ZWGBRgQip5R79dbjM-9H9t5-V0xIlBjoGO4vd4Wc"},{"id":"4bc31af9bd03bbdc","type":"tls-config","name":"","cert":"","key":"","ca":"","certname":"","keyname":"","caname":"","servername":"","verifyservercert":false}]
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
@moeb98 did you got it running this way? I know it's a lot of effort to get everything set up, but you're free of contrib then. Probably you recognize also faster response. |
@andesse thx for the hint, will try! Did not know that the Hue API v2 is just basic HTTP. |
@maconic for all information just make a hue developer account ;) |
@Stieger81 import in a new Flow. I exported a whole flow site if it's my version. |
@Stieger81 it seems to be a problem with copy paste here... try to download from my Dropbox Wrong... will update it |
yes dropbox is working thank you |
jetzt muss ich mal probieren ob ich damit was machen kann. ... know i have to try this. |
ok, danke dir. wie muss ich genau anfangen ? |
@Stieger81 lad die Events contrib wie sie dort steht |
habe ich gemacht |
@andesse: thanks again, mate... scene recalling works like a charm now! The recall payload was the key for me... would assume there is a proper API documentation available once registered as a developer with Hue, right? |
@moeb98 yes! You get the whole API V2 documentation after registration on HUEs Developer site with all informations. |
@moeb98 i am about to make an own repository with all informations / subflows / explanation needed, so that everyone can use it "out of the box"... too much struggle here :) |
Here my repository for https HUE API V2. It's just a flow with everything you need. https://github.com/andesse/node-red-hue-api.v2-flows |
Got it running with groups/rooms and with individual lamps already. As currently traveling, will try the scenes asap. Thanks for the support already as of now… highly appreciated!
Am Montag, Juni 6, 2022, 8:47 PM schrieb andesse ***@***.***>:
@moeb98 did you got it running this way? I know it's a lot of effort to get everything set up, but you're free of contrib then. Probably you recognize also faster response.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Hue Group,
I have 6 lights grouped as room but when i query with node its not displaying right boolean even thoughs lights are on it says
on:false
Lateste node-red
Latest hue-magic
The text was updated successfully, but these errors were encountered: