SmartThings Community

Multiple Motion Sensors to control one light switch?


#1

I have a long hallway which needs several (3) motion sensors to cover, but the lights are controlled by just one switch.

I would like for the lights to turn on when motion is sensed by any of the sensors, and turn off when there is no motion on all of the sensors.

The smart lights app will allow me to turn the light on using all three sensors, but does execute the turn off function as I would like. The turn off function is only determined by the switch that turned on the light. For example, if I enter the hallway and trigger ‘motion sensor 1’ to turn on the light, then walk down the hall (and remain by ‘motion sensor 2’), the light will turn off when no motion is sensed by ‘motion sensor 1’ (even though ‘motion sensor 2’ still detects me).

Any help or recommendations would be greatly appreciated.

Thanks


(Andy - United Kingdom) #2

Try this…

Works really well

Andy


#3

If you haven’t used custom code before, it’s pretty straightforward. Basically you will copy the author’s code and paste it into your own account. Here’s the FAQ for that process:


#4

It’s all about WebCoRE! That’s what you need and once you do you will never go back to using Routines or Smart Lighting

Your requirements were similar to mine , so here’s a Piston I previously created for two motion sensors and one light / smart plug. Once you install and get everything up and running, you can restore this Piston with the 4 digit code and replace it with your own motion sensors and light. Then of course qualifications can be changed as I only have mine work between Sunset and Sunrise.

Also a new video was just created to walk users through installing webCoRE


#5

Thank you so much for the help! The Zone motion manager is exactly what I was looking for!

Well almost exactly what I needed.

The lowest value for Motion Aggregation was one minute, so I changed line 308 to give a 1 second update interval.

This works perfectly, my light turns on when any sensor is triggered (through the native ST app) and turns off when all sensors are inactive (via Zone Motion Manager).

WB70, thanks for your advice on WebCoRE. I have heard about WebCoRE, but have no coding experience and am still trying to keep things simple. Once I have the basics down, I may expand my horizons and try out some pistons.

Thanks again!