I have a simple automation to trigger on motion detection, and then flash a Hue light.
Works just fine but only flashes the once - I would like them to flash constantly until turned off
I can find a few old topics to keep the lights flashing using various scripts, but I was just wondering if there was a newer simple method to do this?
Just checking before I go down the complicated route of scripting etc.
If I execute this with a Philips Hue bulb, it flashes 15 times and then turns itself off.
Beyond that, you’ll probably need to use
repeat - while but it will produce a lot more Zigbee traffic (because explicit turn_on and turn_off commands will be transmitted … plus acknowledgements from the bulb).
Thanks for the quick reply. Yes I agree, ‘long’ gives 15 flashes
I just wanted it to carry on until I decide to turn off
Maybe we could find where the “15” is coded and make it a very large number?
Any ideas on that?
Possibly a parameter hard-coded in the Philips Hue integration … which is not accessible to the light.turn_on service call.
An alternative might be to make a direct REST call to the Philips Hue bridge (assuming the number of repetitions is adjustable and you’re using the bridge). There’s a new version of Hue’s API that I haven’t examined yet so maybe it offers the ability to control the number of “blinks”.
It seems like you could combine the long flash service call above with a repeat…until in the automation.
you just need to figure out how long the 15 flashes take to complete and then put in a delay for that amount of time before doing the repeat. Unless, of course, there is feedback from the light that it’s no longer flashing. If so then use that instead.
You would have the same effect with less zigbee traffic.
Did you ever arrive at a solution for this? Would love to know as I’ve been looking to do this for a while.
Bedside lamp flash red continuously at night when motion detected at back door.
Kitchen side light flash continuously when the vibration sensor has been triggered by the mailman opening the mailbox.
Then something like a remote or verbal command through Nabu Casa A…a to stop the flashing.
Would be really handy.
I know there is a genius on here that has an elegant and repeatable process for this.
Sorry, no. I never sorted out an easy way to do this
I did get this working in the end!
Works like this:
- Trigger on motion detection. eg; occupancy
- Call script to TOGGLE lights while occupancy = TRUE
Toggle lights is like a flash
On 2 seconds Off 2 seconds - repeat
alias: Flash Lights on Motion
- condition: state
- service: light.toggle
The script is called from an automation like this:
alias: Alarm lights
- type: motion
- service: script.flash_lights_on_motion
I will give it a go! Thanks for posting back my friend!
Have a great day.