SmartThings Community

How would I turn bathroom fan off (GE on/off switch) 45 min after X light was turned off


(elite) #1

I searched and here is what I am trying to do. Seems easy but nothing ever is. I want to tell Alexa to “shower” which works fine. Turns on my vanity lights, overheard cans, shower can, and Fan. All are on dinner BUT the fam switch. So, I get up, get in I’m good. I want to get finish my business and turn off the lights but leave the fan on for say 30min after I shut light(s) off. I didn’t see a way to do this…any advice?


#2

There Are (at least) two ways to do this. :sunglasses: The first is to set up a virtual timer using a virtual switch and include that virtual timer in your routine rather than the actual fan. The how to instructions for doing this are in the community – created wiki. It says “light” but it will work with any switch.

http://thingsthataresmart.wiki/index.php?title=How_to_create_a_virtual_timer_for_a_light

Alternatively, you can certainly do this with core, which won’t require a virtual switch and would give you a lot more alternatives, but is more complex to set up:


(Robin) #3

You can certainly get very creative with CoRE.

This is how my bathroom fan is controlled via CoRE. My delay for on is 30 seconds but this can easily be tweaked to whatever you want.

If I turn my bathroom light on at a dimmed level (pull and hold the cord switch) the fan won’t come on. This is handy when I’m ‘just visiting’.

I use a custom variable to set the run on time based on humidity and / or manual input via a button device (variable is set by different pistons separate from the following example.


(Joel W) #4

The easiest is use Smart Lighting comes with SmartThings. I have lights that go off 40 minutes after they are turned on. In the app pick the lights and fan then down on the list is turn off with power allowance. It works everytime.


#5

Power allowance works every time, but it works every time. Meaning there will be no way to ever leave the fan on for longer than the power allowance amount.

That’s the whole point of using a virtual timer. :sunglasses: You put the power allowance restriction on the virtual timer and then you can continue to have other kinds of rules controlling the physical device when you want. Core is similar in that you can apply the timer effect only under certain circumstances.


(Joel W) #6

Point made, but looking at his post it looked like he just wanted simple turn off after a certain amount of time.


(elite) #7

Ill check out the power allowance. I may have missed that thinking it wasn’t going to have what I needed but ill review it. CORE seems cool, but I don’t know if I want to invest time into learning 1 more time draining app (because I will get totally consumed lol). I definitely for the most part just want something simple and if it not perfect it’ll work the majority of the time AND it’ll turn off regardless. Most of the time me or my wife leave it on ALL day because we simply forget. Ill play in a sec and report back. Eventually ill get a sensor and just do it based on humidity but that also does cover all situations because if you are on the can dropping a bomb and want to leave the fan on and forget it’ll still turn itself off so the simpler solution may work for my needs.


(Robin) #8

If you ever decide to give it a go, this is how to install CoRE… You’ll be on a fast learning track but it’s worth it.

  • log into the online IDE
  • Go to ‘my SmartApps’
  • Click ‘+ new smartapp’
  • Click ‘from code’
  • Paste raw code from the link below
  • Click ‘create’
  • Click ‘save’
  • Click publish > for me
  • Go to marketplace in the ST mobile app
  • Scroll down to ‘my apps’
  • You will see CoRE ready for use

Note - you only have to do the above once, after that you can go straight to CoRE via the automation tab of the ST mobile app.

My fan comes on regardless of humidity and defaults to 5min run on time. If I ‘drop a log’ (lol) I can tap a button by the door to make the fan stay on longer.

Whatever happens, the fan will never stay on longer than 60minutes after lights off… So wifey can’t blow all the heat out of the house!!


(Joel W) #9

JDRoberts is more knowledgeable with CoRE than I am. But I think the simple solution is Smart Lighting. I have used it many times for simple solutions.


(Robin) #10

Wonder if there are any zwave log sensors on the market???

Maybe a moisture sensor under the seat to pick up the splash back!!

:innocent:


(elite) #11

I wonder :slight_smile:


(Chris) #12

Super simple with CoRE


(elite) #13

gonna install core but for what I needed the other suggestion works.

Today I walked in the bathroom. “ALEXA turn on shower”. I use “shower” to turn on all lights and as well as the fan. When I leave I want to keep the fan on so I say “ALEXA turn off master”. Master is all BUT fan and and I set up a power allowance. It turns off as expected after 35min. I didn’t time it but I left the house and came back and it was off…which is exactly what I wanted, to never forget, even if I forget :). Will play with Core too when I have time. Thanks group!