Currently, hue bridge users can use light.turn_on with flash:long|short and color while this same service call with deCONZ results in the light flashing white regardless of color specified.
I had initially thought it may be a problem with deCONZ itself, but after raising a github feature request there, I was pointed to the actual deCONZ integration.
Looks like it’s sending an {"alert": "select"} or {"alert": "lselect"} , which the Hue bridge translates to the same Trigger Effect command as deCONZ generates for {"alert": "breathe"} . You would need to update the HA deCONZ integration to use the same logic as Hue (incl. the check for innr lights), except send breathe instead of lselect .
Your welcome. We are discussing the status of the API documentation of deconz and lights is the next to be updated so its interesting there where a few more commands I’ve never seen before
I was just hoping for a sanity check before running the command. Assuming my hue bulb is named light.hue_lamp I would call the following { "entity": "light.hue_lamp", "field: "/state", "data": {"alert": breathe} }
Thanks for sharing this solution I have been wanting this for a long time. Works great for a single Hue Bulb but have you had any luck in getting more than a single bulb to flash in one service call. I have tried this with both the entity as a home assistant light group and deconz light group but throws an error.
This is what I am using as the service call
Service: deconz.configure
light.alarm_lights is a deconz light group
And the error in the logs is:
Logger: homeassistant.components.websocket_api.http.connection.139839948294848
Source: components/deconz/services.py:133
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 19 November 2020, 23:48:18 (3 occurrences)
Last logged: 00:02:00
/groups/8/state method, PUT, not available for resource, /groups/8/state
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 135, in handle_call_service
await hass.services.async_call(
File "/usr/src/homeassistant/homeassistant/core.py", line 1448, in async_call
task.result()
File "/usr/src/homeassistant/homeassistant/core.py", line 1483, in _execute_service
await handler.job.target(service_call)
File "/usr/src/homeassistant/homeassistant/components/deconz/services.py", line 60, in async_call_deconz_service
await async_configure_service(hass, service_data)
File "/usr/src/homeassistant/homeassistant/components/deconz/services.py", line 133, in async_configure_service
await gateway.api.request("put", field, json=data)
File "/usr/local/lib/python3.8/site-packages/pydeconz/gateway.py", line 106, in request
_raise_on_error(response)
File "/usr/local/lib/python3.8/site-packages/pydeconz/gateway.py", line 220, in _raise_on_error
raise_error(data["error"])
File "/usr/local/lib/python3.8/site-packages/pydeconz/errors.py", line 58, in raise_error
raise cls("{} {}".format(error["address"], error["description"]))
pydeconz.errors.RequestError: /groups/8/state method, PUT, not available for resource, /groups/8/state
A couple of caveats with this method. It doesn’t appear you can set the color unless the bulb is on, or you include on: true in the parameters with alert: breathe. If you do include on: true, the bulb stays on after flashing. You can get around this by following up the breathe action with a 15 second delay, and then an on: false action. Another thing is that it won’t return to the original color after flashing.
Added new values for state.alert (and action.alert ) to issue the corresponding Trigger Effect command “blink”, “breathe”, “okay”, “channelchange”, “finish”, and “stop”. This is available in 2.04.76. Github
I wonder what the difference is between blink and breathe