Introduction: Motion Activated Alarm

I choose this project because I am interested in motion activated lights and how they work. In public spaces, there are sometimes lights that turn on when motion is detected and I wanted to make a smaller version of those types of lights. However, when researching those lights, I thought it would be better suited to create an alarm instead of just a light as that would combine two different outputs with the piezo buzzer and an LED light. I also wanted to explore circuits with arduino more so I chose this project as I had to make a slightly more complex circuit with multiple outputs and an input from a PIR motion sensor.


Supplies

  1. Arduino UNO
  2. Arduino software
  3. Wires
  4. Battery case
  5. Batteries
  6. PIR motion sensor
  7. Piezo Sensor
  8. generic FDM 3D printer
  9. LED
  10. Soldering kit
  11. Perfboard

Step 1: Designing the Circuit

To start I designed a circuit on Arduino UNO that had the motion sensor as the INPUT pin 2, the LED as the OUTPUT pin 7, and the piezo buzzer as the OUTPUT pin 8. The positive sides of the LED, buzzer, and PIR sensor are wired to the INPUT/OUTPUT pins and the negatives sides are wired to ground.

Step 2: Write Code

I wrote the code so that when the value of the INPUT pin is HIGH, light the LED and sound the buzzer.

Step 3: Soldering

I transferred the circuit onto an Arduino micro-controller and soldered it onto a perfboard with the same pins attached as the original circuit.

Step 4: 3-d Printing Prototype Box

I made the prototype box that will hold the alarm. I 3-D printed a 10cm x 10cm and 7cm thick wall with a circular cutout in the center of diameter 14.7cm to hold the PIR sensor. I then printed out a 10cm x 10cm wall of the box with a 6 mm diameter hole in the center for the LED, but then realized that the wires on the LED were too short to put the LED in the middle, and that the hole was too small so I printed out another 10cm x 10cm box wall with the hole more towards the side of the wall with the hole for the motion sensor and with a bigger hole.

Step 5: Prototype

For my prototype, I taped together the two sides with holes and 4 other sides cut from the board and tested the motion sensor, LED and buzzer system.

Step 6: 3-D Print New Box

I then 3-D printed a 5-sided box (8cm x 8cm) with the same sized cutouts for the LED and motion sensor and 2 bars on the 6th side to prevent the battery from falling out of the box.

Step 7: Assembly

I then secured the LED, motion sensor, and buzzer system into the new box.