Motion detector with Arduino


I want to get an email when mouvement is detected in my backyard. To have my whole backward covered with only one motion detector, I need to use one that comes with 120v outdoor lights.

To use this 120v output with my Arduino, I'll replace the 120vlightbulbs with a 5v cellphone charger. This 5 volts circuit will have a Led, resistor and a NC relay. When the motion detector will be triggered, the 5v relay will be energized, the contacts will close and the Arduino will receive a HIGH, then sending an email.

I checked the button tutorial since it is pretty the same thing, but I have one question left. In the tutorial, the button is pressed only a few seconds. The motion detector might output power for minutes. Do I need a load in the circuit that go from the 5v pin on Arduino to the relay contact to the input pin or is the digital input pin a "load" in itself (I'm worried about shortcut)?



How about just powering the Arduino from the 5V supply, and use a sketch that sends one email each time it is powered up? That would seem much simpler - as long as your can rely on your motion detector keeping the 'lights' on for long enough for the Arduino to complete sending the email.

Have you considered using a security camera instead of a (presumably PIR) motion sensor? This is quite a common requirement and you don't need to spend a lot of money to get a steerable camera with day/night vision, live remote video streaming, motion detection, and the capability to send alerts by various methods including email with attached images showing what triggered the alert. They can turn lights on too if you want.