๐ Automatic Room Lighting System
Date: October 30, 2021
Purpose: Energy conservation through automation using IR sensors and a microcontroller.
๐ฐ Introduction
Electricity is an indispensable part of modern life. However, with rising energy demands and depleting non-renewable resources, energy conservation has become a necessity. One major area where energy is often wasted is lighting—many people forget to switch off lights when leaving a room.
To address this, we’ve designed an Automatic Room Lighting System, which uses IR sensors and a microcontroller (ATmega32) to automatically switch lights ON or OFF based on room occupancy. This system not only helps reduce electricity bills but also promotes responsible energy usage.
๐ง Working Principle
Entry: Sensor 1 → Sensor 2 → Light ON + Counter++
Exit: Sensor 2 → Sensor 1 → Counter-- → Light OFF if Count = 0
This project is based on a bi-directional human detection mechanism using two IR sensors positioned at the entrance of a room. Here's how it works:
➕ When a person ENTERS the room:
- Sensor 1 (outside) is triggered first, followed by Sensor 2 (inside).
- This sequence tells the microcontroller to turn ON the lights/fans and increment the visitor count.
➖ When a person LEAVES the room:
- Sensor 2 (inside) is triggered first, followed by Sensor 1 (outside).
- The microcontroller decrements the visitor count. If count = 0, it turns OFF the lights/fans.
๐งพ Components Required
# | Component | Quantity |
---|---|---|
1 | ATmega32 Microcontroller | 1 |
2 | 16 MHz Crystal Oscillator | 1 |
3 | IR Sensor Modules | 2 |
4 | 0.1ยตF Ceramic Capacitors | 10 |
5 | 18pF Ceramic Capacitors | 4 |
6 | 10kฮฉ Resistors | 10 |
7 | 330ฮฉ Resistors | 10 |
8 | Red LEDs | 6 |
9 | Green LEDs | 10 |
10 | Seven-Segment Displays | 2 |
11 | Breadboard | 1 |
12 | Connecting Wires (5m) | As needed |
Key Points:
- IR sensors are placed on either side of the door.
- The microcontroller processes IR input and controls relays for AC appliances.
- 7-segment display shows the live visitor count.
(Insert or link to your circuit diagram image here)
⚙️ Procedure
- Place Sensor 1 outside and Sensor 2 inside the room entrance.
- Program ATmega32 to monitor IR sensor inputs and update person count.
- Use a relay driver to switch lights/fan based on count.
- Display the visitor count on a 7-segment display.
✅ Output
- System automatically manages room lighting based on human presence.
- Visitor counter works accurately with multiple entries/exits.
- Lights stay ON as long as there's at least one person inside.
- Reduces power wastage and enables smart automation.
๐ Conclusion
This project combines IR sensing and microcontroller logic to automate room lighting. It’s useful for homes, classrooms, offices, and more, helping reduce electricity consumption and human error.
- Prevents energy wastage
- Accurate room occupancy detection
- Scalable and simple to implement
- Ideal for smart buildings and IoT automation
๐ก Future Scope
- Integrate with IoT platforms for remote monitoring
- Use PIR sensors for better accuracy
- Support temperature/humidity-based fan control
- Add mobile app control via WiFi modules
Do you want the code, circuit file, or Proteus simulation? Let me know in the comments and I’ll share the files!
Comments
Post a Comment