Announcement

Collapse
No announcement yet.

Would this work to control a Philips Wiz lightbulb?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Would this work to control a Philips Wiz lightbulb?

    I recently purchased one of these to play with... works pretty well, and a decent price. Of course, no HS integration or PI yet.
    https://www.wizconnected.com/en-US/c.../046677603519/

    I wonder if Node Red could work to control an RGB wifi bulb. Totally new to me, so thought i'd run it by here first before i went down the rabbit hole.

    Thoughts?

    #2
    This is a non-starter for me: "No fuss. Everything is on the cloud via Wi-Fi." Just re-flashed some Tuya bulbs to get away from that.

    That being said, there's a python library that implies they can be controlled locally. https://github.com/sbidy/pywizlight

    Control and Status appear to be JSON. If that's the case, then, yes, it should be possible.
    "if I have seen further [than others], it is by standing on the shoulders of giants." --Sir Isaac Newton (1675)

    Comment


      #3
      Apparently these are not very secure. The Home Assistant user worked out a flow or two to use MQTT and upd to control them. I believe this is their most up to date flow. They did end up interesting it direct. Note that I do not have one of these to test with.
      Karl S
      HS4Pro on Windows 10
      1070 Devices
      56 Z-Wave Nodes
      104 Events
      HSTouch Clients: 3 Android, 1 iOS
      Google Home: 3 Mini units, 1 Pair Audios, 2 Displays

      Comment


        #4
        Just ordered one to play around with but likely won't get it until the weekend.

        EDIT: Found this blog post. Philips apparently knows there's no security on these bulbs but doesn't care.

        https://blog.dammitly.net/2019/10/ch...bs-or-iot.html

        Use caution when putting these on your home network unless you have a separate VLAN like the author does.
        "if I have seen further [than others], it is by standing on the shoulders of giants." --Sir Isaac Newton (1675)

        Comment


          #5
          ugh. thanks.

          Comment


            #6
            Originally posted by Tomgru View Post
            ugh. thanks.
            Not as bad as it sounds. Like any other IoT device that you can't verify the firmware in, these should always be put on an isolated network. Once configured using the app, the bulb can be blocked from internet access with a firewall rule for even more security.

            There is an option in the Wiz Connect app that allows you to turn off local communications which turns off the device's udp control. If you want to put them on your home network, disable local control and use them as cloud only devices. Of course, the bulb has to have internet access and there's a significant delay when sending commands.

            I've got a flow that can turn a bulb on or off and set the color. I'll post something by the weekend once I get things hammered out a bit more.

            Ken
            "if I have seen further [than others], it is by standing on the shoulders of giants." --Sir Isaac Newton (1675)

            Comment


              #7
              Tomgru Sorry for the delay. Last week was just a whirlwind.

              Here's the basic test bench I've been using to experiment with and test the Wiz bulb:

              Click image for larger version

Name:	Screen Shot 2020-12-06 at 10.25.30 AM.png
Views:	2382
Size:	48.0 KB
ID:	1438785
              Code:
              [{"id":"69d5a519.d4edfc","type":"tab","label":"Wiz Bulb Test","disabled":false,"info":""},{"id":"e4f13e0a.5203a","type":"udp out","z":"69d5a519.d4edfc","name":"Send","addr":"","iface":"","port":"38899","ipv":"udp4","outport":"38900","base64":false,"multicast":"false","x":890,"y":320,"wires":[]},{"id":"a53bb215.0754","type":"inject","z":"69d5a519.d4edfc","name":"On","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"setPilot\",\"params\":{\"state\":true}}","payloadType":"json","x":230,"y":300,"wires":[["ea3cb1c1.13611"]]},{"id":"d07b002d.ca76d","type":"inject","z":"69d5a519.d4edfc","name":"Off","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"setPilot\",\"params\":{\"state\":false}}","payloadType":"json","x":230,"y":340,"wires":[["ea3cb1c1.13611"]]},{"id":"6743a8aa.a28358","type":"udp in","z":"69d5a519.d4edfc","name":"Response","iface":"","port":"38900","ipv":"udp4","multicast":"false","group":"","datatype":"utf8","x":220,"y":140,"wires":[["c1c51783.d1a968"]]},{"id":"c1c51783.d1a968","type":"debug","z":"69d5a519.d4edfc","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":440,"y":140,"wires":[]},{"id":"c276a379.dfa3b","type":"json","z":"69d5a519.d4edfc","name":"","property":"payload","action":"","pretty":false,"x":710,"y":320,"wires":[["e4f13e0a.5203a"]]},{"id":"ea3cb1c1.13611","type":"change","z":"69d5a519.d4edfc","name":"","rules":[{"t":"set","p":"ip","pt":"msg","to":"192.168.1.23","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":510,"y":320,"wires":[["c276a379.dfa3b"]]},{"id":"246898cb.dcf3c8","type":"inject","z":"69d5a519.d4edfc","name":"Poll","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"getPilot\", \"params\":{}}","payloadType":"json","x":230,"y":260,"wires":[["ea3cb1c1.13611"]]},{"id":"a6703559.a753f8","type":"inject","z":"69d5a519.d4edfc","name":"Temp 4500","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"setPilot\",\"params\":{\"temp\":4500}}","payloadType":"json","x":220,"y":380,"wires":[["ea3cb1c1.13611"]]},{"id":"5ab4295d.5cda88","type":"inject","z":"69d5a519.d4edfc","name":"SceneID 12","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"setPilot\",\"params\":{\"sceneId\":12}}","payloadType":"json","x":210,"y":420,"wires":[["ea3cb1c1.13611"]]},{"id":"f41cfd7c.8f169","type":"inject","z":"69d5a519.d4edfc","name":"RGB","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"setPilot\",\"params\":{\"r\":255, \"g\":0, \"b\":0}}","payloadType":"json","x":230,"y":460,"wires":[["ea3cb1c1.13611"]]},{"id":"b499cb9e.11c368","type":"inject","z":"69d5a519.d4edfc","name":"Dim 50%","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"{\"method\":\"setPilot\",\"params\":{\"dimming\":50}}","payloadType":"json","x":220,"y":500,"wires":[["ea3cb1c1.13611"]]}]

              The only thing that needs to be set to use this flow is the bulb's IP address in the "set msg.ip" node.

              I have both the bulb and the tablet running the Wiz app on my IoT isolated subnet and I've played around with enabling and blocking internet access. If you block internet access for either for more than 12 hours, the app can't talk to the bulb anymore, but local control via NR still works.

              The only real non-starter for me is "Power Outage Recovery". This feature is supposed to control whether or not the bulb turns on after a power outage but doesn't seem to work whether it's enabled or disabled. Note that enable/disable requires both the bulb and app be connected to the internet so it must be an MQTT message or similar, not a local control command.

              Let me know what questions you have.
              Ken
              "if I have seen further [than others], it is by standing on the shoulders of giants." --Sir Isaac Newton (1675)

              Comment

              Working...
              X