Skip to main content

Motion-based Alarm System

A Rust-powered alarm system based on motion detection, with audio-visual feedback and a time log feature.

info

Author: Vlad Alexandru Vulturescu
GitHub Project Link: https://github.com/UPB-FILS-MA/project-VladVulturescu

Description

An alarm system based on motion detection, featuring audio and visual feedback and a time log displayed on an LCD screen. This system uses a Raspberry Pi Pico W to process input from a PIR motion sensor to detect presence and activate alerts.

Motivation

This project was chosen to explore practical applications of embedded systems in security, utilizing motion detection to develop a reliable, low-cost alarm system suitable for residential properties. It aims to provide an intuitive system for enhancing home security.

Architecture

The system architecture comprises a Raspberry Pi Pico W, which serves as the central processing unit. It is connected to an HC-SR501 PIR motion sensor for detecting movement. Upon detection, the microcontroller triggers an audio alarm (buzzer), a light alarm (LED's) and displays the activation time on the LCD. The button inputs allow for system reset.

Architecture

Log

Week 6 - 12 May

Week 7 - 19 May

Week 20 - 26 May

Hardware

The Motion-based Alarm System leverages essential electronic components designed to interact seamlessly for effective monitoring and alerting functions:

  • Raspberry Pi Pico W: Acts as the central processing unit of the system, handling the computation and control logic. It processes signals from sensors and manages outputs to other devices.
  • HC-SR501 PIR motion sensor: This sensor detects infrared signals from moving objectsor people, triggering the alarm system when motion is detected within its field of view.
  • LCD: Displays the time of the "break-in".
  • Buzzer: This will produce the actual alram sound, prividign the audio feedback
  • LED's: The LED's will light up at the same time when the buzzer activates, prividing visual feed-back.
  • Buttons: Used for user input and allow for manual resetting of the alarm.
  • Breadboard and Jumper Wires: Provide platform for prototyping the circuit, facilitating easy setup and adjustments.
  • Resistors: Ensure proper functioning of the circuit, as well as protect sensitive components from excessive current and manage voltage levels.

Device Image 1

Schematics

KiCad Schematic

Bill of Materials

DeviceUsagePrice
Rapspberry Pi Pico WThe microcontroller[35 RON](https://www.optimusdigital.ro/en/raspberry-pi-boards/12394-ras$
BreadboardThe basis for the project[10 RON](https://www.optimusdigital.ro/ro/prototipare$
HC-SR501 PIR motion sensorFor detecting movement[7 RON](https://www.robofun.ro/hc-sr501-pir-motion-sensor-module-green.html?gad_source=1&gclid=Cj0KCQj$
BuzzerEmmits the actual alarm sound4 RON
LCDThe screen[9 RON](https://ardushop.ro/ro/electronica/36-lcd-1602.html?gad_source=1&gclid=Cj0KCQjwltKxBhDMARIsAG8KnqW9xcNF8xYGWvhIZg0jziN0vcJ_Rx6d8ObsTI$
LED'sLight up when the alarm is triggered[0,45 RON](https://ardushop.ro/ro/electronica/299-led-5mm.html?search_query$
ButtonsFor resetting the alarm[0,4 RON](https://www.optimusdigital.ro/en/buttons-and-switches/1119-6x6x6-push-button.html?se$
ResistorsSo components don't get destroyed and for voltage d$
Jumper WiresFor making connections[4 RON](https://www.optimusdigital.ro/ro/fi$

Software

LibraryDescriptionUsage
pir-motion-sensorRust library for PIR motion sensorsFor working with PIR sensors, the HC-SR501 speciffically
  1. HC-SR501 data sheet
  2. crates.io
  3. Raspberry Pi Documentation
  4. [Sparkfun]](https://learn.sparkfun.com)