Automatic and Manual Temperature Control unit

Automatic and Manual Temperature Control unit: Automation have reached almost everywhere whether it is home automation or agriculture field. Automation system collect different parameter such as temperature, humidity etc. in real time basis and keep control of fan, moist control etc. But sometime we need manual control over various actuator or load like motor, fan etc. wither testing of load or when automatic system does not work. This project is the modified version of Arduino Based Temperature Controlled Fan.

Manual mode is also considered as backup mode with which we can control load manually according to our requirement. So, in this project we will learn about automation and as well as manual control system so that one can control load in both automatic and manual mode. For demo we are consider temperature control unit. In this project we will control fan in automatic mode and in manual mode.

Circuit Description of Arduino Based Automatic and Manual Temperature Control unit

The circuit is built around arduino nano, DHT11 (temperature and humidity sensor), a 20×4 I2C LCD, Z44N (MOSFET) and few other components like resistor, led, switch etc.

Arduino Based Automatic and Manual Temperature Control unit

Component Required

1x Arduino Nano

1x DHT11

1x 20×4 I2C LCD

1 x Z44N

1x SPDT Switch

3x 5mm LED (Any color)

1x 1N4007

3x 360-ohm Resistor

2x 10k-ohm Resistor

1x 10k-ohm POT.

1x 12V DC Fan

1x 12V Power Supply

DHT11 Sensor is used to sense the temperature and humidity. A DPST Switch SW1 is used to select the mode of operation i.e. Automatic mode and Manual Mode. A 20×4 I2C LCD is used to display data like temperature, humidity, mode of operation and fan speed. A potentiometer VR1 is sued to adjust the speed of fan in manual mode. A switching circuit is designed around a N-Channel MOSFET IRFZ44N. We are using PWM pin instead of normal digital pin, because MOSFET is voltage control device i.e. voltage at gate (G) determine the conduction level. PWM pin can supply different voltage from the range of 0V to 5V in 255 steps. This is required for variable fan speed. Check out another project based on DHT11, “Temperature, Humidity and Heat Index Meter using Arduino“.

A resistor of 10K is connected between ground and gate in order to avoid false triggering of MOSFET. Source pin (S) of MOSFET is grounded where drain pin of MOSFET is connected to negative terminal of fan. Positive terminal of fan is connected +12V power supply. A diode D1 is connected across fan in order to protect form reverse fly-back voltage. Glowing LED1, LED2, LED3 indicates Max. Temperature, Automatic Mode and Manual Mode respectively.

author prototype of Arduino Based Automatic and Manual Temperature Control unit

Figure 2: Author Prototype of Arduino Based Automatic and Manual Temperature Control unit

Software Code: Software code is written is arduino programming language and compiled in arduino programming. Let’s see the code Breakdown.

Automatic Mode:

Temperature sensor detect temperature and operate fan at speed of corresponding temperature. In this demo project minimum temperature is set to 200C and maximum temperature set to 300C. In this mode we will operate fan with three different condition.

  1. When Temperature is less then minimum temperature: Fan will be turned off with message of “Min Temp (Fan OFF)”.
  2. When temperature is between minimum temperature and maximum temperature: Fan Spin at the speed of corresponding temperature. Here, difference of maximum temperature and minimum temperature is map between 1% to 100% speed.
    Let’s say Minimum temperature = 230C

Maximum TEMPERATURE = 300C

Temperature difference = Max. temp – Min temp. = 30 – 23 = 70C

At 230C, Fan spin at 0% similarly at 300C fan spin at 100%.

Map = 100/7 = 14.28 = 14%. So, per degree increase in temperature increase the speed of fan by 14%.

When Temperature is more the maximum temperature: Far will spin at full speed (100%) with message “Max Temp(Max Speed)”. Maximum Temperature is also indicate by glowing LED3.

Automatic mode is indicated by message on display “Automatic Mode” and glowing LED1 indicate.

Manual Mode:

In this mode sped of fan is not affected by temperature any more. Speed of fan is manually adjusted by POT (VR1). In this mode speed of fan is corresponding to output voltage from VR1. Manual mode is indicated by message on display “Manual Mode” and glowing LED2 indicate.

At 0V, Fan spin at 0% similarly at 5V fan spin at 100%.

Map = 100/5 = 20%. So, per voltage speed of fan increase 20%.

Complete Source Code

Leave a Comment