Hacker News new | ask | show | jobs
by georgemcbay 4486 days ago
Pretty cool, but why reed switches on the door instead of a passive IR detector with a timeout? Neither is perfect, but the PIR doesn't rely on people to remember not to close the door when leaving (which I assume is how they determine actual occupancy?).

You could wire the same PIR to also control the light on/off state, so if someone is having an epic poop but not moving too much you can be pretty sure they'll move to make the light go on if they hit the timeout.

2 comments

I did exactly this for my home light, I connected the Arduino as a USB peripheral to my home server and use a PIR sensor and a photoresistor to turn lights on/off when it's bright/dark/I'm home/I'm away. It works very well.

Partial writeup: http://www.stavros.io/posts/control-rf-devices-with-arduino/

I considered this but we already have fancy light switches with motion detectors in our bathrooms and our company is strict about leaving the doors open when you leave so that hasn't been a problem. An added bonus of this is that if the last person is leaving and about to lock up they can see if a bathroom door is closed and check to make sure no one is still in there, where as the light could still be on.