Custom automations not triggering based upon Period of Time

Devices:

  • Hub
  • Multipurpose Sensor
  • Outlet

All of these devices are brand new off Amazon, most recent version / gen.

My requirement is rather simple:
During the day, keep the temp at 75 degrees F
During the night, keep the temp at 70 degrees F

I have 4 automations:

First automation:
IF
time period Between 9:00am and 6:00pm, every day
multipurpose sensor actual temp >= 75
THEN
turn outlet off

Second automation:
IF
time period Between 9:00am and 6:00pm, every day
multipurpose sensor actual temp <= 74
THEN
turn outlet on

Third automation:
IF
time period between 6:01pm and 8:59am, every day
multipurpose sensor actual temp >= 70
THEN
turn outlet off

Fourth automation:
IF
time period between 6:01pm and 8:59am, every day
multipurpose sensor actual temp <= 69
THEN
turn outlet on

Simple, right?

Automations sometimes run, and sometimes they donā€™t.
I cannot find any rhyme or reason as to when they decide to run and when they decide to not run.
Iā€™ve deleted the automations several times and recreated them.
Iā€™ve powered off the hub and let it sit for a couple minutes and powered it back on.
To no avail, can I get this thing to function correct.

Support has rendered itself useless.
I contact them, and they ask for specific examples of what failed to trigger and when.
So I immediately provide them with examples.
Then, they wait 3 or more days to respond, asking for new examples because too much time has lapsed since I sent the last example.

Now, I canā€™t even seem to get a response from support.

I rated the app 1 star on Google Play wtih an explanation. They responded and apologized for my difficulties and told me I should reach out to support. WELL DUH- Iā€™ve DONE that!

Anyone have any ideas as to what I can do to meet my requirements with the room temps during day and night?

Did you set up your geolocation in the app? Click the three dots in the upper right of your screen and choose Manage Home.

Wow, best question ever after so many times of contacting support!!
Yes- it is set!
And location mode is set to ā€œHomeā€.

Wait just a darn minuteā€¦ does this mean my automations will only run if Iā€™m home??

No, they will run

Dang. Any other ideas? :slight_smile: :slight_smile:

I also had consistency problems with using period of time when I started with smartthings.

I ended up using specific time, like every 2 hours Iā€™ll check the temperature. If it exceeds a specific threshold, I turn the device on and set it in the automation to auto turn off after 1 hour.

I didnā€™t bother to check on period of time again since I only need to cool the house when Iā€™m away and the solution above is adequate enough to meet my needs.

Yikesā€¦ this is unfortunate. Iā€™m trying to keep my temps pretty consistent. Not sure I can handle a temp swing every two hours. And I donā€™t think Iā€™d want to set up automations to run every 15 minutes, that would be a lot of automations to create. LOL!

Use webcore.

2 Likes

If you remove the time period restriction and just trigger off the temperature change, do the automations work?

If you create an automation with the time restriction and an alternative trigger such as turning a light on, does that work reliably?

Yes, if the time period condition is removed it seems to work just fine.

Alternative trigger?
I donā€™t have any other devices, just the multi-purpose sensor and outlet. I bought them for this specific control.

Yes, I was just wondering if it was the combination that was causing the problem or if the time period screwed up other things. Has to said that I was messing around with time periods this morning and didnā€™t have any issues, so it isnā€™t fundamentally broken.

Nah you gotta give it a full cycle to test, 30 to 36 hours. Initially it works.

Itā€™s almost like the change of time doesnā€™t fire the event. So of the temp doesnā€™t change and it moved into the next automations time, it doesnā€™t trigger because there was no change of state on the multipurpose device.

It seems like Iā€™m having the same issue in webcore, the piston is only firing on change of status of the device(s). Itā€™s not firing with the change of hour.

Thanks, I checked it out. Very easy for me to follow!! So awesome!! However there it is also only firing upon status change of the devices and is not firing when the time changes. I may have something wrong but Iā€™m pretty sure thereā€™s another forum I found that Iā€™ll post this issue in for help.

Iā€™ll accept as the solution.
But ā€¦ I just really wish smart things would work! Kinda stubborn.

Iā€™m pretty sure that it is just a restriction in Custom Automations, just as it is in Smart Lighting. So you donā€™t get it firing at the start and end times.

In webCoRE it depends ā€¦

If you write the piston with a trigger for the temperature such as ā€˜rises aboveā€™ and a condition such as ā€˜time is betweenā€™ then, by default, the piston only fires on temperature changes. As ā€˜rises aboveā€™ can only be true when the piston is processing a temperature event it doesnā€™t help to fire at the start and end times. You can do it (my first edit of this post said how) but it doesnā€™t help.

On the other hand if you write the piston without a trigger, e.g. ā€˜greater thanā€™, then it will subscribe to the times as well as the temperature changes and if required there is a setting you can add (the Task Execution Policy) so that it only does stuff when the condition changes. It is actually a classic example of why those who canā€™t see a piston without screaming ā€˜you need a triggerā€™ are horribly wrong.

1 Like

Got it!!! I was using $hour24 variable at the start of my script to test if it was between 9a&5p. This did not have a lightning bolt.

I switched to using the Virtual Device ā€˜Timeā€™ and this now has lightning bolts, so with the change of time, it seems to be firing my piston now!

WOOO HOO! This is amazing!!

SmartThings just needs to buy webCoRe!!!

Thank you!!