Change Motion Sensor Inactivity Time Out

I’ve seen lots of references to people wanted to reduce the inactivity time out of motion sensors, I was wondering if there is a way to INCREASE the inactivity time out of a SmartThings Motion Sensor? I’d like it in the 2 minutes or more range. I’m trying to have a re circulation pump turn on when entering a bathroom and want to maybe increase the threshold for lack of movement so the pump isn’t constantly running if you are in and out of the bathroom (bathroom is attached to a closet). Thoughts?

EDIT: Or is there another sensor in the similar price range that will let me do this?

What are you using for the Automation? I am pretty sure Smart Lighting will allow you to specify how long the motion has be ‘inactive’ before turning off the switch.

It’s somewhat convoluted I think… but here it goes.

The module for the tankless water heater requires a switch or a wired sensor to activate the recirc pump when the occupant wants hot water. My idea was to have the motion sensor turn on a 5v sonoff relay switch that is connected to the tankless heater module - but only when I enter the room the first time. So the idea is when motion is first detected it will flip to active and thus switching on the recirc pump, but I don’t want it to fire again if I decide to leave the bathroom to do something in the closet or another room for 30 seconds or whatever the inactivity timeout is. So I would like to increase the time the sensor goes from active to inactive to a longer period of time. Does that make sense?

Perhaps there is an easier way to do it? I tend to overthink things a bunch. There are other things in place that will not allow the pump to run if the temp is at a certain set point. I am just at the point of buying the sensors and switches and want to ensure I get ones that will do what I want them to so all my bases are covered.

It sounds like a simple/traditional Motion Activated Light Switch, to me. This is one of the most common ‘automations’ that users implement.

  1. motion detector sees someone enter the room (i.e. it changes state to ‘active’)
  2. a light switch is automatically turned on
  3. motion detector goes ‘inactive’ after some period of time (this is in the hardware design of the sensor, and is usually 30-60 seconds)
  4. automation waits to see if motion stays ‘inactive’ for a user selectable timeout period.
    a) If timeout occurs, light turns off
    b) If motion goes ‘active’ before timeout, cancel the timeout and go back to #3 above

This sounds like what you want to do. This functionality is built into SmartApps like ‘Smart Lighting’, so no custom code is required. Hopefully this helps.

Thanks for the reply, I was looking to change the period of time it goes inactive in (say change from 30s to 120s for example). The reason for this is because the switch would be momentary like a garage door opener and only on for .5s then auto off. So what you say in #4 may work, but without trying I am really not sure (I am a neophyte with all this beyond the basics and a very small amount of webcore type stuff). It sounds as though this not changeable for most, in doing more research I see Rboy has a couple of handlers for Monoprice sensors but they are out of my price range being in canada they are 2x+ the price of the samsung one.

Is the ‘Off’ command to the pump also a simple momentary press of a button? If so, how are you planning on keeping ST updated with the current state of the recirc pump? The system could get out of sync very easily.

The pump would be set up to run a certain amount of time, say 3 minutes - this function has nothign to do with smartthings and is entirely controlled within the heater itself. After that it just shuts off - again, nothing to do with smartthings. Smartthings is only being used to automated a button being pushed. So the idea would be that the motion sensor would just turn on the momentary switch (.5s - similar to pressing a button) and the switch would return to off on it’s on. Does that help at all?

Ah… that does help…I think…

It is not about “not turning it off” but rather “not turning it back on again” within a certain window of time. Is that what you mean?

Or, another way of saying it is that you only want the motion active signal to ‘push the momentary button’ once every so many minutes.

What happens if the ‘momentary button is pushed’ multiple times? Does is toggle the pump on and off? The root of this question is whether or not there is any harm by a user ‘pushing the button’ multiple times.

I am envisioning what you’re trying to accomplish as simply automating the current manual pushing of a button that starts the recirc pump. Is this correct? What happens if someone presses the button a second time while the recirc pump is running? It seems like this is the problem you want to avoid. Is that correct?

Yeah, I think we got there. There isn’t nothing that will happen other than the pump running for longer than it needs to, other than more energy being used and more wear and tear on the pump/pipes. I would just like to run the pump as little as possible.

Each push only toggles the pump on, it will toggle itself off (based on time or temperature of recirced water)

Gotcha. OK then, I believe the standard Motion Lighting with timeout would still work. This assumes that the device you’re controlling can be configured just for a momentary on output.

SmartThings should only send an ON command one time when motion is first ‘activated’. It will send an ‘off’ command only after the timeout is reached.

If the device receiving the ‘on’ command simply turns on a digital output for a period of time, and then does nothing when the off command is sent, it should just work.

If this was something being built using my ST_Anything Arduino/ESP8266 type of solution, it would be fairly trivial to create. I was hesitant to suggest this as I am not aware of your desire for an off-the-shelf solution versus a DIY solution.

There may definitely be some other options out there as well. Hopefully some other will chime in.

My intention was to use a Sonoff WiFi Wireless Smart Switch Relay Module 5V as the heater itself has a 5v output to run the above switch. That said it appears as I’ll have to jump through some IFTTT and fake switches in smart things to get it to work without flashing it.