There are many use-cases for quickly blinking a light (or a set of lights):
- Doorbell notification (there is someone at your front door).
- Kitchen timer (it’s time to get the food out of the oven or turn down the heat of the stove).
- Laundry finished (the washing machine or the drier has finished working).
- Light selection (we could have one remote control controlling many lights individually: one button would “select” the next light (which should blink briefly to indicate the selection), and the up/down buttons would control the selected light).
- Et cetera… Essentially, anything that deserves a notification could use a blinking light.
Over 1½ years ago, I started researching how to make a light blink. It’s not easy, and I took note of several links:
I was also thinking… If blinking a light can be implemented, maybe something I call “light animations” could be implemented as well. In my mind, “light animations” are a superset of the “blinking”. It would work like this…
The user would be able to define an “animation”, which is a sequence of light states. Something like “set light brightness/color to a certain state, followed by waiting for ‘x’ seconds”, and that repeated as many times as wanted.
Then, the user would be able to request HA to “play” a light animation either once or a few times. After playing, the light should return to the previous state.
With this basic framework, one would be able to easily define:
- Basic blink: “turn on, wait 1 second, turn off, wait 1 second”
- Blink 3 times: play “basic blink” 3 times.
- Bright blink: “turn on 100% brightness, wait 1s, turn off, wait 1s”
- Police-style blink: “turn on red, wait 0.5s, turn on blue, wait 0.5s”
- Morse-encoded message: "turn… " okay, you get the idea, just adjust the wait times and then you can morse-encode any message
Like I said, this “light animation” framework would be able to create any blinking style. Still, there is value in providing a simplified user-friendly API (i.e. service call) to just blink without having to worry about too many customization options; but those options would still be available as part of the “light animation” feature.
In conclusion, while I believe this can be very powerful and very useful, I understand this can be “feature creep”. So, just having a basic “blink” would already create the most amount of value for users (and that’s what this thread is requesting anyway).
EDIT: Maybe, just maybe, this blinking feature should be extended beyond the
light domain. Imagine having a smart plug that shows up as a switch. Then you can connect something dumb like xmas lights to the smart plug. Then… blinking the switch would blink the light. (I think recent HA versions added support for switches to behave like lights, no? I don’t remember, as I never had this use-case.)