Page 1 of 1
PIR Sensor Arduino Alarm
Build a motion-sensing alarm with a PIR sensor and an Arduino.
- Author: John Edgar Park
- Difficulty: Easy
Here's how you can build a motion-sensing alarm using a PIR (passive infrared) sensor and an Arduino.
Sections
- Wire the Arduino to the breadboard.
- Plug in the LED.
- Connect the piezo buzzer to the Arduino.
- Launch the Arduino IDE (software).
- Test the alarm.
Files
Tools
- Arduino IDE software
- Computer, with USB cable
Relevant parts
- Arduino microcontroller, Duemilanove

- Breadboard, Mini for ProtoShield

- PIR sensor
- Jumper wires, Assorted
- Piezo buzzer

- LED any size or type

- View:
- Paginated
- Full width
This guide has been completed 15 times.
Page 1 of 1
Comments 
Comments are onturn off
It's a PDF under Files at the top of the project. Have fun!
I've uploaded the code you provided and wired everything up correctly. AS soon as it's uploaded to the Arduino Uno, the sensor goes off and doesn't acclimate the it's surrounding. It just sets it of immediately. What could I be doing wrong? Maybe bad sensor? It's brand new. :(
Brandon, sorry for the huge delay, I didn't see your comment until now. You can change the delay time upon startup to be longer if you need. Try adding a new line as the first one in the void setup that reads: delay(5000);
That'll give you five seconds before it begins.
hello thanks for the code
but I want to know if possible
speaker sound delay
and as I explained
nothing else connected arduino
speaker sound is triggered and
I want to take a few seconds to get out of house if
or only trigger when
active sensor
if not explain myself well
I'm a newbie
thanks

All set up, but where do I find the code?