0% found this document useful (0 votes)
1 views

Report

Uploaded by

pjbagga
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

Report

Uploaded by

pjbagga
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Detect the motion of an obect and glow

the LED if motion is taking


place.
Report by 22BME048, 22BME049, 22BME050 , and 22BME051

Overview: The goal of this project was to create an electrical circuit


that could detect motion and automatically turn on a light. This type
of motion-activated lighting system can be useful for providing
illumination in areas like closets, hallways, outdoor spaces, etc. when
motion is detected, while saving energy by turning the light off when
the area is vacant.
Additional task: buzzer was added in circuit to use it anti-theft
module to avoid robbery by alarm system.

Components required:
• Arduino uno R3
• HC-SR501 PIR motion detection sensor module
• Led 5mm (green)
• Jump wire
• Resistor
• Buzzer

Specifications of HC-SR501 PIR senosr


• Infrared sensor: dual-element, low noise, high sensitivity
• Blockade time: 2.5s (Default)
• Infrared Sensor with Control Circuit Board
• The Sensitivity and Holding Time Can be Adjusted
• Sensitive Setting: Turn to Right, Distance Increases (About 7M); Turn to
Left, Distance Reduce (About 3M)
• Time Setting: Turn to Right, Time Increases (About 200S); Turn to Left,
Time Reduce (About 5S)

Connection of circuit :

• 5V is given to positive side of breadboard and ground (GND) is


given to negative side of breadboard
• Now 5V is given to positive side of PIR sensor and GND is
connected to GND of PIR sensor
• Signal pin of PIR sensor is connected to digital pin D2
• Now Digital pin D4 is connected to anode of LED not directly
but by resistor and also to anode of buzzer
• Cathoder of buzzer and LED is connected to negative part of
breadboard

Working principle:
• When motion is detected, the input pin is taken by digital
pin D2 and stores it in variable defined in the code.
• If the stored value is 1 then it would give positive output to
the LED and buzzer means it will set to HIGH and it will get
turn ON.
• And if not then it will remain LOW as value is 0

Code:

Here is the code written in arduino IDE and the pin D2 is set as input and D4 as output

The input is stored in variable r as defined in the code and by getting the value of r the pin of led and
buzzer is set HIGH or LOW according to value.

Ouput:
Before (No motion):

After (motion is given ):

As we can see the when any motion is provided in the range of PIR sensor the led is glown
and buzzer makes beeping sound.

You might also like