Every time we lose power at night, we are woken by our Philips Hue lights turning on when power is restored.
The Philips Hue API implements a powerup feature for selecting from 4 behaviors: safety = warm white full brightness (default), powerfail = last used color & brightness, last_on_state = stays off or turns back on, and custom = choose color & brightness.
I’d love to see this feature implemented in the core integration for Hue, so that we can set each light’s power recovery behavior via the Hue bridge. An example use case is setting our 25 Hue lights each morning to behave intuitively like normal bulbs when turned on with a physical switch, and then flipping them at night to last_on_state to keep them off in the event of a power cut. Swapping out our Hue bridge for ZHA/Z2M is not a workable option.
Searching other threads: A similar feature request 2 years ago focused narrowly on ZHA and had a confusing title, hence why I’m creating a new request for the Hue bridge use case.
Please can we prioritise this feature request in the core Hue integration? Edit: I may take a stab at coding the feature myself if there are enough votes, although I’m new to Python and HASS development.
If you can code it, you don’t need to post it as a Feature Request. Submit it as a PR in the Core repository.
If the new functionality requires a modification of Home Assistant’s architecture (I don’t believe that’s the case here), you would first need to pitch your idea in the Architecture repo and get it approved.
The power on behavior of lights is set in the firmware of the light (the controller could never be in time to set this).
The Zigbee controller can change the option in the light, provided it has proper support for the light. If you use the HUE bridge, the HUE bridge should be the one to set the right parameter.
If you use ZHA or Z2M, those can set the parameters, and for all the smart lights I have I did just that.
I’m not sure that HA is able to instruct the HUE bridge the set the right parameter, ut that should not be needed. If you use the HUE app, then the lights should behave as expected.
Thanks for letting me know. Appreciated. I’m new to HA coding and the documentation seemed to suggest that feature requests need to be posted here first.
I’ll refactor my ask above to see how much interest there is in this feature. If there’s a lot of interest I might have a go at coding it. Otherwise I can probably hack something for my own use case faster outside HA.
The powerup object is documented in the Philips Hue v2 API (see excerpt below). Why would HA not be able to instruct the Hue bridge to control this object?
**powerup: (object)**
Feature containing properties to configure powerup behaviour of a lightsource.
**preset: required(one of safety, powerfail, last_on_state, custom)**
When setting the custom preset the additional properties can be set. For all other presets, no other properties can be included.
An action would presumably need pairing with a sensor entity, to provide both write and read funxtionality. I’ve seen some integrations combine these into a single ‘select’ (pulldown menu) entity.
What are the pros and cons in HA of the action+sensor vs select patterns?