I am trying to make automations work by events so that if a boolean trigger state is off and it is set to off again it will trigger the automation. This happens using my Harmony remote to set lighting events.
I am really a NOOB at this. Using regular automation events will work as long as the state changes, but not if the same state is sent again.
The issue is that I am using Hue emulation to catch light scene change commands from Harmony hub remote buttons.
I can only program commands as On or Off on a Harmony button. If I use the On scene then I can never use the On scene again if I have switched to a scene on another button. I would have to issue the Off scene first for that button, which would change the scene to something I didn’t want before going back to the On scene.
Is there no way to accomplish this? It really makes the Harmony remote lighting buttons pretty useless. I did have this working nicely in HomeSeer but was hoping to move to HA, except for this pretty significant issue.
it sounds like what you want is a momentary button. which is useful for cases where you want to catch the press event regardless of state.
home assistant does have momentary buttons, but i don’t believe hue emulation does. so what i would do is i would create a boolean helper that you expose to hue emulation… create a simple automation the turns the boolean off as soon as it turns on. then have the harmony remote turn the boolean on every time the button is pressed.
Thanks for your help. Unfortunately I don’t think that will work. I am exposing a boolean toggle to Hue. The issue is that the Harmony can send either an on or an off and you never know which. Therefore if we keep the toggle off and it receives an off nothing happens. Same for the on. Hence the reason I was trying to catch the event and not deal with the state of the helper.
EDIT: To clarify, the Harmony has only 4 lighting buttons. In order to use 8 scenes, which I need, I have to use the on and off state of each button. That is the essence of the issue of a scene being triggered from either an on or a different scene from the off, and the scenes can be chosen in different orders, i.e. Button 1 on then Button 2 on, then Button 1 on. The last one won’t work.
Slightly different remotes but the same lighting buttons.
Example button setup scenes:
Button 1 Short - All Lights On
Button 1 Long - All Lights Off
Button 2 Short - Eating Lights On Low
Button 2 Long - Eating Lights on High
Events as they occur:
Step 1: Button 1 Short - All lights on, come into room to watch a movie
Step 2: Button 2 Short - Dim lights to eating mode
Step 3: Button 1 Short - Stop watching and turn, all lights on
Step 3 won’t work as Button 1 is already on.
There are many different combinations that won’t work unless the state can be triggered even if that boolean helper is already in that state.
here’s a setup for you… for now i’m going to turn everything into a short press. this will nuke your long press capabitlies, but i think you’ll end up functionally working… i hate the long press anyways:
button 1: helper button1 entity-off
button 2: helper button2 entity-off
events:
states:
lights off
helper button1: off
helper button2: off
step 1: button 1 short - intent: lights off- turn on to full
helper button1 turns on- automation detects, sees lights != 100% and turns lights on to 100%- automation turns helper button1 off
lights:100%
helper button1: off
helper button2: off
step 2: button 2 short - intent: dim lights
helper button2 turns on- automation detects, sees lights != 50% turns lights on to 50%- automation turns helper button2 off
lights:50%
helper button1: off
helper button2: off
step 3: button 1 short - intent: turn the lights all the way up
helper button1 turns on- automation detects, sees lights != 100% and turns lights on to 100%- automation turns helper button1 off
lights:100%
helper button1: off
helper button2: off
step 4: button 1 short - intent: lights are on full, turn them off
helper button1 turns on- automation detects, sees lights == 100% and turns lights on to 0%- automation turns helper button1 off
lights:0%
helper button1: off
helper button2: off
If I only needed 4 scenes then this would work. The problem is that I need 8 scenes and there are only 4 physical buttons, so I use 4 helpers. But I need to use the on AND off state to trigger 8 different scenes.