Yes, I did mention that NTP could be a hurdle. According to the docs, the polling interval is 60+ seconds (enough of a window to carry out a test). If on Ubuntu, you can simply pause time-syncing, advance the clock to perform the test, then resume time-syncing.
be sure you have the right entity_id and also when you post code see the instructions at the top of the page. We need to see your spacing and indenting - critical for YAML!
It did not like my unique ID
" Error loading /config/configuration.yaml: while parsing a block collection in “/config/automations.yaml”, line 1, column 1 expected <block end>, but found ‘?’ in “/config/automations.yaml”, line 3, column 1"
My switch shows up in 2 places. One under zwave and then under switches- where you have manual control from the UI. I am using the one that gives me manual control . Is that wrong?
Well I want the lights to come on when sun is below 25 as long as it’s after 4pm. So either will trigger the automation but then it needs to check the sun is below 25 and it’s after 4pm. You can’t do ‘or’ on triggers - any trigger will trigger it so the only way to do it is by repeating the triggers as conditions and making sure both are true.
Otherwise in winter my lights come on at 3pm - not what I want when no one is in that room, and in summer, I don’t need them coming on at 4 - 5:30 is a better time…
I moved trigger and action over to the right one space. Still doesn;t like the id:
Error loading /config/configuration.yaml: while parsing a block collection in “/config/automations.yaml”, line 1, column 1 expected <block end>, but found ‘<block mapping start>’ in “/config/automations.yaml”, line 3, column 2
Thank you for telling me that as I never saw anything about that being a requirement. Ok just made one up and config ok again. Let me see what happens…
Which is effectively doing an ‘or’ and ‘and’ together. The first trigger (sun elevation) wont work if its not after 4pm, likewise the 4pm (time trigger) wont work if the sun is too high. Both triggers must be in the true state when either is fired. (as you said
, but this IS essentially creating an ‘or’ in your triggers)
Personally I use motion and interior light level as I don’t want to waste power having lights on for no reason. My lights only come on with motion, but only if the room is dark enough to need it, later at night they will come on irrelevant of light level so to ensure they re-trigger on motion even if the light is on which would otherwise make the automation think its too bright to require the light being switched on.
Actually, it will trigger if either trigger is ‘triggered’ but the conditions both have to be met for the action to be executed.
EITHER trigger must be triggered for the conditions to be checked and then as long as the conditions are met the action is executed.
I don’t have any motion sensors. I just worked out 4pm and 25 degrees worked best for me.
Ok it is still not working but I am getting somewhere as now the editor is working for the first time.
I might see the problem
under action type >Call service
under service > light.turn_on
under service data > {}
Where is entity_id:??? I don;t see it in the automations config, but it’s there in the main editor?
that IS creating a setup where the triggers are ‘or’ AND ‘and’ together. I can’t think of the correct logic term for it right now, but its essentially just AND with 2 triggers… (that’s the OR part)