Automatic Doorbell System Using Arduino
Automatic Doorbell System Using Arduino
Arduino
Table of Contents
1. Introduction
2. Objectives
3. Components Required
4. Circuit Diagram
5. Working Principle
6. Arduino Code
7. Applications
8. Conclusion
9. References
1. Introduction
The Automatic Doorbell System is a simple and cost-effective solution to detect the
presence of visitors and trigger a doorbell automatically. By using an Arduino
microcontroller, a PIR (Passive Infrared) sensor, and a buzzer, the system can detect motion
and activate the bell. This project can be implemented at home, offices, or any location
where automatic doorbell functionality is needed.
2. Objectives
- To develop an automatic doorbell system using Arduino.
- To detect the motion of a visitor using a PIR sensor.
- To trigger the doorbell when a visitor is detected.
3. Components Required
- Arduino UNO
- PIR Sensor (HC-SR501)
- Buzzer
- 10k Ohm Resistor
- Breadboard
- Jumper Wires
- USB Cable
- Power Supply
4. Circuit Diagram
The following connections should be made between the components and the Arduino:
- Connect the VCC pin of the PIR sensor to the 5V pin of the Arduino.
- Connect the GND pin of the PIR sensor to the GND pin of the Arduino.
- Connect the Output pin of the PIR sensor to Pin 2 of the Arduino.
- Connect the positive leg of the buzzer to Pin 9 of the Arduino and the negative leg to the
GND.
5. Working Principle
The PIR sensor detects infrared radiation from a moving object (such as a human body).
When motion is detected, the sensor sends a signal to the Arduino. The Arduino processes
this signal and sends an output to activate the buzzer. The buzzer rings, simulating a
doorbell, alerting the homeowner or office occupant about the visitor's presence.
6. Arduino Code
The following code is used to program the Arduino for the automatic doorbell system:
void setup() {
pinMode(pirPin, INPUT);
pinMode(buzzer, OUTPUT);
Serial.begin(9600);
}
void loop(){
val = digitalRead(pirPin);
if (val == HIGH) {
digitalWrite(buzzer, HIGH);
delay(1000);
digitalWrite(buzzer, LOW);
}
}
This code uses the PIR sensor to detect motion and activates the buzzer for 1 second when
motion is detected.
7. Applications
- Home automation for automatic doorbells.
- Security systems that alert when someone approaches the door.
- Offices or stores where doorbell functionality is required.
8. Conclusion
The Automatic Doorbell System using Arduino provides an efficient way to automate
doorbell functionality. This system is easy to implement, cost-effective, and reliable for daily
use in homes and offices. It showcases how simple electronic components can work
together to create useful applications in everyday life.