Arduino Smart Door Project Report With Code
Arduino Smart Door Project Report With Code
1. Introduction
With the rise in security concerns, traditional lock-and-key systems are becoming outdated.
A smart door enhances security using Arduino and modern authentication techniques such as RFID,
fingerprint recognition,
and IoT-based controls. This project demonstrates an automated smart door system with secure access
control and
real-time monitoring.
2. Objectives
3. Components Required
Hardware:
- Arduino Uno / Mega
- RFID Module (RC522) / Fingerprint Sensor
- Servo Motor (for locking mechanism)
- Keypad (4x4) (optional)
- Bluetooth Module (HC-05) (optional)
- Wi-Fi Module (ESP8266) (optional)
- LCD Display (16x2)
- Buzzer
- Power Supply (9V Adapter or Battery)
- Jumper Wires
Software:
- Arduino IDE
- MIT App Inventor (if using a mobile app)
- Blynk or Firebase (for IoT integration)
4. Working Principle
1. User Authentication:
- The system verifies the user through an RFID card, fingerprint, or PIN.
2. Door Unlocking:
- If authentication is successful, the servo motor unlocks the door.
- If authentication fails, the buzzer sounds an alert.
3. Remote Access (Optional):
- Using Bluetooth or Wi-Fi, the door can be controlled via a mobile app.
4. Auto-Locking Feature:
- The door locks automatically after a specified time.
5. Intruder Alert (Optional):
- Unauthorized attempts trigger an alert notification.
5. Code Implementation
Below is the Arduino code for an RFID-based smart door system using a servo motor.
#include <Servo.h>
#include <SPI.h>
#include <MFRC522.h>
#define SS_PIN 10
#define RST_PIN 9
Servo doorLock;
MFRC522 mfrc522(SS_PIN, RST_PIN);
void setup() {
Serial.begin(9600);
SPI.begin();
mfrc522.PCD_Init();
doorLock.attach(6);
doorLock.write(0); // Door locked position
Serial.println("Place your RFID card...");
}
void loop() {
if (!mfrc522.PICC_IsNewCardPresent() || !mfrc522.PICC_ReadCardSerial())
return;
Serial.print("UID: ");
String tag = "";
for (byte i = 0; i < mfrc522.uid.size; i++) {
tag += String(mfrc522.uid.uidByte[i], HEX);
}
Serial.println(tag);
if (tag == "12ab34cd") { // Replace with your RFID tag UID
Serial.println("Access Granted");
doorLock.write(90); // Unlock door
delay(5000);
doorLock.write(0); // Lock again
} else {
Serial.println("Access Denied");
}
}
6. Applications
- Home Security Systems
- Office and Workplace Access Control
- Hotel Room Access
- Smart Lockers
7. Future Enhancements
8. Conclusion
The Arduino-based smart door system provides a cost-effective, secure, and automated access
control solution. With various authentication methods and remote access capabilities, it enhances security
for
residential and commercial spaces.