Humanity is currently advancing toward new technologies by replacing manual processes with automatically controlled gadgets. A cooling fan is one of the most fundamental needs of humans in hot weather. However, the fan's speed may be adjusted manually using a manual switch known as a fan regulator or dimmer. The fan speed may be adjusted by adjusting the dimmer. It may be observed in some regions, such as if the temperature is high in the morning but drops dramatically at night. The users do not grasp the temperature difference. So, to overcome the fan's speed here's a temperature-dependent approach.
This notion is especially useful in locations where the temperature varies dramatically between day and night. The manual fans will be converted into automated fans as part of this project. The automated fans will adjust their speed based on the temperature of the room. This article goes over a temperature-controlled fan block diagram, breaking it down by block and property.
The aim of the project is to control the speed of a Fan (DC Motor) according to the temperature of the environment. The more the temperature, the more will be the speed of the fan and maintains the coolness of the surroundings instead of manual control. The fan doesn't go on for temperatures below 0°C and slowly varies its speed from minimum to maximum over 0 to 150°C. The circuit is simulated in Proteus Simulation Software.
$ads={1}
Now that the world is faced with global warming, is high time engineers came on board to contribute in the area. This project will be used to automatically take over the manual operation of putting on the fan and increasing the level of the fan. This will be helped greatly for those with disabilities.
The objective of the Project:
To use a microcontroller in controlling the speed of a DC fan. The Microcontroller used here is the 8051 Microcontroller which will be used to control a DC fan
Reduce overheating problem
To provide an effective low-cost device
Microcontroller-Controlled Temperature-Controlled DC Fan
The suggested system temperature-controlled fan employs a microprocessor to regulate the fan's speed in response to temperature and to display the temperature. The microcontroller, temperature sensor, motor, seven-segment display, ADC, power supply, and operational amplifier are all essential components.
The accompanying graphic depicts the block diagram of the temperature-controlled fan utilizing a microcontroller. Power supply, RST circuit, 8051 microcontrollers, LM35 temperature sensor, 8-bit ADC, L293D motor driver, DC motor, 7-segment display, and i/p switches are all shown in the block diagram.
Block Diagram:

From the above diagram, the microcontroller will be powered by the stepped-down power supply for easy operations. The LM35 is a temperature sensor with precession whose output voltage varies depending on the temperature around it and sends it to the ADC0804. It can calculate one ADC value from 0V to 5V with a precision of 19.53mV when the voltage reference (Vref –pin 9) is +5V, these values are then compared to the threshold temperature set by the programmer. Based on that, the fan will decrease, stop or increase the velocity. The 8bit LED Binary counter displays the values of the temperature in hexadecimal.
The Circuit Diagram:

Circuit Principles:
The main principles used in the project are ADC (Analog to Digital Conversion),
DAC(Digital to Analog Conversion), and PWM (Pulse Width Modulation). The operation of the circuit starts from reading the temperature of the environment using the LM35 Temperature Sensor. It is connected to ADC0804 which converts the analog signal of the sensor into digital. The digital output of the ADC is sent to the 8051 MC, which calculates the temperature by scaling it, and then certain logic has been implemented to find the duty cycle of the PWM Pulse. Based on the duty cycle, we will know the time duration of the high and low pulses of the PWM pulse. We will be using timer 0 in mode 3 to on the motor and off the motor for the times calculated above. We used the motor driver L293D which is an H-Bridge Motor driver, which connects the DC Motor (to replicate a fan) and supplies the motor with sufficient current and power to run.
LM35
The LM35 is a temperature sensor with precession whose output voltage varies depending on the temperature around it. It's a small integrated circuit that can test temperatures from -55°C to 150°C. If the temperature is 0 degrees Celsius, the output voltage would also be 0 degrees Celsius. For every degree Celsius increase in temperature, the voltage will rise by 0.01V (10mV). The voltage can convert into temperature using the below formulae.
          Vout = 10mv/°C × T
ADC0804

The ADC0804 is a popular ADC module for projects that require an external ADC. It's a single-channel 8-bit ADC module with 20 pins. It can calculate one ADC value from 0V to 5V with a precision of 19.53mV when the voltage reference (Vref –pin 9) is +5V. (Step size). That is, for every 19.53mV increase on the input side, the output side would increase by one bit.
L293D

The L293D is a 16-pin motor driver IC that is widely used. It is primarily used to drive motors, as the name implies. A single L293D IC can drive two DC motors at the same time, and the two motors' directions can be operated independently
8051

The 8xC51 contains a 128 × 8 RAM, 32 I/O lines, three 16-bit counter/timers, a six-source, four-priority level nested interrupt structure, a serial I/O port for either multi-processor communications, I/O expansion or full-duplex UART, and an on-chip oscillator and clock circuit. Intel created the 8051 microcontroller in 1981. It's a microcontroller with an 8-bit resolution. It has a 40-pin DIP (dual inline package) with 4KB of ROM and 128 bytes of RAM and two 16-bit timers. It has four parallel 8-bit ports that can be programmable and addressed to meet the needs of the user. The microcontroller has an on-chip crystal oscillator with a crystal frequency of 12 MHz.
Let's have a look at the 8051 Microcontroller's architecture.
The system bus connects all of the support devices to the CPU in the diagram below. An 8-bit data bus, a 16-bit address bus, and bus control signals make up the system bus. The system bus connects all other devices, including program memory, ports, data memory, serial interface, interrupt control, timers, and the CPU.
$ads={2}
8 bit LED Binary Counter

We used the 8bit Binary Counter to display the degree of the Temperature. We should have used LCD, but we wanted to expand our knowledge to the use of binary counter
You can download the Proteus file and code Here