Whats up with this automation?

This is on the same lines as my last forum post - what have i done wrong! I think the logic of what i'm trying to achieve comes across in the screenshot, but it doesn't seem to be working. I think it runs the first step (Sunset -60, 100% brightness) but doesn't progress from there.

All advice appreciated as always.

I suggest you consider doing the following; 1. change your trigger to hourly. 2. In actions use conditional statements - ex. if time = 22:00, then run your Dim command if true. You can write it as one big If / Then if you separate it up with Else_if statements (ex: Else_if 20:00 then xxx, Else_if 21:00 then xxx, etc.). At the top of the hour the trigger will run down the list and true up the Dim you want to fire. This will work like a champ.

If i was to change it to trigger hourly, would it not only work if it ran at the specific time - ie it would need to be triggered at say 10pm in order for it to pick up the 10pm dimming process?

I thought the overall logic of what i'd done is ok but i've obviously misunderstood the operators, as it definitly only runs the first step.

My understanding is that once a wait condition/event is satisfied all other waits are cancelled. Which is why only your first wait for runs. I would just use if statements or just break it up into a number of simple automation rules.

Must admit I'm not a big fan of wait for events etc.
My preference would be 5 triggers of the times mentioned and the a series of IF-THEN and ELSE-IFS.
Just my preference though.
Lots if choices. :slight_smile:

1 Like

No - if you have your trigger set to hourly then at the top of every hour the trigger will fire 24x7. Your If, Then, Elseif conditions need to align with the hours you want action to occur. If no actions align with the trigger for a given hour nothing happens, just the actions that become true - i.e., If Time = 21:00 then xxx. j

You're right, my bad - I did a quick test to confirm my misunderstanding!

1 Like

Hi all,

Thanks for the input. I read it all and thought through the options. Doing it as seperate rules was one I considered (and did use for a few days while i figured it out), but i hoped to get it all in one rule to keep things neat and tidy! Also i want to add some more complications to it, which will no doubt be the subject of my next 'why doesn't this work' thread!

Anyways, i changed my 'condition' for 'event' and added a delay as you can see, and it all works like a champ. Much obliged to you all.

1 Like

I have another suggestion. I do something similar with a lot of my lights, especially ones that are motion triggered. To allow myself to use simpler automations instead of rule machine, I create modes for sunrise+15, sunset-30, 10pm, etc.

Then I use scenes (or sometimes just individual settings) in the motion and mode app to make things happen.

The advantage is I end up creating lots of reusable components and I don't have to edit a bunch of rules every time I make a change.