Turn the switch back ON after x minutes OFF


Just curious if there is an app for this.
the trigger is the same switch state where it need to be ON all the time, but sometimes it need to be turned OFF. I need the app to turn it back ON automatically after x minutes when the switch mode change to OFF.

Is there such an apps for this ?
I have try to search, but people tend use the OFF action, rather than ON action.

my usage is simply as turn back on my fish tank filter power after turn the switch off e.g 15 minutes due to feeding time.

Personally I would use Smart Lighting.
Set it to turn off at, say 15:00 and turn back on at 15:15.
Very straightforward.

1 Like

i sometimes do this not on scheduled time, could be 3pm or 7pm depend on when i need to trigger this.
the best approach is to switch off (manually or through apps) and let the automation turn it back on after sometime.

In that case you could use CoRE.
If switch/light is off, wait 15 minutes, turn on.

Thanks Bobbles,
is this core the one renamed as particle ?
seems too hardcore to me for such simple task need to automate.

Core is very powerful, but also very complicated and currently in beta development.

There is also a simpler way which doesn’t require any beta code. You do need a virtual switch. Then it’s very easy.

One) have your trigger turn on the virtual switch.

Two) have the virtual switch set up to turn itself off after X minutes (power allowance)

  1. have the real switch set up to turn on when the virtual switch turns off. (Smart lighting)

If you don’t know how to create a virtual switch:

All of that said, I personally wouldn’t use SmartThings to control anything involving an aquarium which might harm the fish if it didn’t work correctly. I just don’t find the system reliable enough. I do use it for convenience cases, but not for health and safety, even for pets.


CoRE hasn’t been renamed.
You can set up a very simple rule using it to do what you require and then not worry about setting up a virtual Switch and then set up a rule for the virtual Switch.
But we all have different approaches and there probably isn’t a right or a wrong way just personal preference.

1 Like

“CORE” in this context is a community-developed smartapp. All software, not hardware. :wink:

Thanks JDRoberts … I think this will work, let me try out later and post the results.

I thought the Core mentioned is the Spark Core which require some hardware knowledge.

1 Like

Thanks bobbles … will see if the virtual switch approach from JDRoberts is stable enough for doing this.

Spark Core is third-party cloud with a hardware piece. So is particle.Io

But the “CoRE” that people will recommend on this forum for rules management is a smartapp (software only) written for the SmartThings platform by community members here. CoRE = Community’s own Rules Engine.

Thanks JDRoberts … the Virtual Switch Approach work out perfectly. it took 3 smartapps to do this.
Let’s see how well this work out and closely monitor the switch state for sometime.

1 Like

Glad to hear it! Core is definitely a much more elegant approach, and you may want to switch over to it once it’s in full release. :sunglasses:

I have a minimote that I use to control my fishtank filter (2) and lights (2). I have button 1 programmed to turn off filter for X minutes then turn it back on. I used Rule Machine for that but it’s probably time to migrate to CoRE.

The other buttons I have programmed to turn OFF/ON the filters on button hold.

I would create a simulated (virtual) switch in the IDE, then create an IFTTT recipe that then flips that switch based of whatever trigger you wanted (an email received, facebook post, alexa phrase, whatever…)

Then use Smart lighting to turn off (or on) when your simulated switch is toggled for a time.

Hi Folks - I have no coding ability - wondering if anyone can fix the code here (Turn off Appliance Module for 30 minutes, then turn back on automatically) to make this request work. That smartapp won’t turn on the device after X minutes off. Looked everywhere and can find a tonne of off smartapps that do similar for things to go to the off state- just no back ON apps? There are a few folks like me been looking for such an app. Any help would be greatly appreciated


PS - Happy New Year!

Use Smart Lighting.
Here is a screenshot of what you need. I think.
Just alter times accordingly.

Thanks bobbles - I did look at Smart Lighting but it would require the unit to be turned off and then back on at a specific time. What I am seeking is if the switch somehow gets turned off at any time, after X minutes it will get turned back on. It is a failsafe for folks like me using Smartthings for aquarium functions (yes I know it is always risky to use Smartthings for critical functions) - that is way folks like me looking for a bit of protection in the form of this failsafe.


No problem.
In that case I suggest you use CoRE.
You can set up a piston something like this.

SWITCH changes to OFF

Wait 30 minutes.
Turn On.

This way every time the switch is turned off, a timer starts and when it matures it will turn the switch back on.

Thanks - using Core and works like a charm!