A smart automation system that automatically controls a fan based on real-time temperature readings using the LM35 temperature sensor and a microcontroller (Arduino/NodeMCU).
The Temperature Controlled Fan is designed to turn a fan ON/OFF (or adjust its speed) automatically depending on the surrounding temperature. The system uses the LM35 temperature sensor to monitor heat levels and triggers the fan when the temperature crosses a predefined threshold.
Depending on the version, the fan is controlled either using:
- PWM (Arduino Version) for speed control
- Relay Switching (NodeMCU Version) for ON/OFF automation
This project improves energy efficiency and eliminates the need for manual fan control in varying temperature conditions.
- Automatically control a fan based on room temperature
- Reduce energy consumption
- Provide a hands-free temperature-based cooling solution
- Demonstrate sensor-based automation using embedded systems
- LM35 outputs 10 mV per °C.
- The microcontroller reads analog voltage using ADC.
- Temperature is calculated using:
The system compares the measured temperature with preset levels:
| Temperature | Fan Action |
|---|---|
| Below 25°C | Fan OFF |
| 25°C–35°C | Fan ON (Medium/Normal) |
| Above 35°C | Fan ON (High Speed) |
- PWM signal controls fan speed
- TIP30 transistor drives the fan
- 1N4007 diode protects against back EMF
- Relay module switches fan ON/OFF
- NodeMCU reads temperature and controls relay
Below is the system connection map (Arduino version + NodeMCU version shown):
- LM35 Temperature Sensor
- Arduino UNO / NodeMCU ESP8266
- TIP30 Transistor (for fan driving)
- Relay Module (for ON/OFF control)
- 1kΩ Resistor
- 1N4007 Diode (flyback protection)
- DC Fan (5V/12V)
- External 5V Power Supply
- Jumper Wires, Breadboard
- Arduino IDE
- Embedded C/C++ Programming
- Read temperature from LM35
- Convert analog reading to Celsius
- Compare with threshold values
- Generate PWM (Arduino) or activate relay (NodeMCU)
- Turn fan ON/OFF accordingly
- Fan turns ON automatically when temperature crosses the threshold
- Stable and accurate LM35 temperature readings
- Relay switches without flickering
- Reduced power consumption when not required
- Demonstrates successful sensor-based automation
- Smart room cooling
- Server room temperature control
- Greenhouse temperature automation
- Industrial heat management
- Laboratory cooling systems
- Add IoT dashboard for real-time monitoring
- Mobile control using MQTT/Blynk
- OLED/LCD temperature display
- Multi-speed AC fan control
- Auto logging of temperature data
All documentation files for this project are included in the repository:
- Detailed Project Report
- Project Presentation (PPT)
- Circuit Diagram
- Source Code
Harshvardhan Shinde
Electronics & Telecommunication Engineering (ENTC)
VIT Pune
