homebridge-mqttthing: Adaptive lighting turns LED strip on intermittently

I have an LED stript that keeps receiving MQTT messages with payload {"color_temp":xxx} even in the OFF state which results in the stript turning on “by itself” every few minutes. This only happens if adaptive lighting is selected. The messages are published by homebridge so I believe the problem lies in this plugin.

What strange is that this is the only light which does this even though I have multiple bulbs with adaptive lighting enabled. Screenshot_3

There is also a “secondary” problem with color_temp values being sent after {"state":"OFF"} payload which prevents light from turning off completely.

About this issue

  • Original URL
  • State: open
  • Created 3 years ago
  • Comments: 17 (1 by maintainers)

Most upvoted comments

When enabling SetOption20 1 any change to webUI sliders or using commands CT, Dimmer, HSBColor3, Color or Channel will not automatically power on the light if it is off

Thanks for mentioning that, fixed my Tasmota strip!

@makleso6 , I did a little code cleanup before creating that gist and inadvertently injected a bug which I didn’t discover until I got home from the office and noticed my bulbs weren’t working anymore. Be sure use the 3rd revision of this gist and make sure your bulbs are setup in zigbee2MQTT to retain.

This is what I am using currently and it’s working well: https://gist.github.com/noelhibbard/0241c82b9dd2749edc553e49b661fa9e

I just ran into the same issue with an IKEA color changing bulb connected via Zigbee2MQTT. If you send an HSV packet to the light without also including "state": "OFF", the bulb will turn on. My fix (needs testing but should be the fix) was to write a codec for mqttthing which keeps track of the state of the bulb at all times. In Zigbee2MQTT I also set this device to retain the MQTT topic so that when homebridge restarts it will receive the last known state right away. After some testing I will share my codec for anyone else running into this issue. Even if you don’t have an IKEA bulb, my codec would at least give someone a starting point for a solution to other bulbs.

After watching the mqtt commands and the Tasmota responses, I could see that the Tasmota powers on in response to HSBcolor commands - regardless of power state (but potentially only if dimmer is >0) I found that there is an option in Tasmota to change this behaviour: https://tasmota.github.io/docs/Lights/#disable-auto-power-on “When enabling SetOption20 1 any change to webUI sliders or using commands CT, Dimmer, HSBColor3, Color or Channel will not automatically power on the light if it is off.” Will run with this and report back.