0% found this document useful (0 votes)
45 views34 pages

Print

The document presents a mini project report on a temperature-based fan speed control and monitoring system using Arduino, aimed at automating cooling based on room temperature. It details the project's objectives, system requirements, and implementation using various components like temperature sensors and an LCD display. The report acknowledges contributions from college faculty and outlines the significance of microcontrollers in modern technology.

Uploaded by

Harini Praveen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
45 views34 pages

Print

The document presents a mini project report on a temperature-based fan speed control and monitoring system using Arduino, aimed at automating cooling based on room temperature. It details the project's objectives, system requirements, and implementation using various components like temperature sensors and an LCD display. The report acknowledges contributions from college faculty and outlines the significance of microcontrollers in modern technology.

Uploaded by

Harini Praveen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 34

TEMPERATURE BASED FAN SPEED CONTROL AND

MONITORING USING ARDUINO

MINI PROJECT REPORT

Submitted by

HARINI C A [22CS082]
MADHUMITHRA S [22CS101]
KAVISRI S [22CS096]
MOULIESWAR S [22CS113]

In partial fulfillment for the award of the degree


of
BACHELOR OF ENGINEERING
IN
COMPUTER SCIENCE AND ENGINEERING

MUTHAYAMMAL ENGINEERING COLLEGE (AUTONOMOUS)

RASIPURAM-637 408

ANNA UNIVERSITY::CHENNAI - 600 025

APRIL 2024
MUTHAYAMMAL ENGINEERING COLLEGE
(AUTONOMOUS)
RASIPURAM

BONAFIDE CERTIFICATE

Certified that this Report “TEMPERATURE BASED FAN SPEED CONTROL


AND MONITORING USING ARDUINO” is the confide work of “HARINI CA
(22CS082) MADHUMITHRA S(22CS101) KAVISRI S (22CS096),
MOULIESWAR S (22CS113)” who carried out the work under my supervision.

______________ ______________
SIGNATURE SIGNATURE
Dr.G.KAVITHA, M.S Mrs.K.GANDHIMATHI, M.E.,
(By Research), Ph.D., ASSISTANT PROFESSOR
PROFESSOR
Department of Computer
HEAD OF THE DEPARTMENT
Department of Computer Science and Science and Engineering,
Engineering, Muthayammal Engineering
Muthayammal Engineering College(Autonomous),
College(Autonomous), Rasipuram-637408.
Rasipuram-637408.

INTERNAL EXAMINER EXTERNAL EXAMINER

2
ACKNOWLEDGEMENT

We would like to thank our College Chairman Shri. R. KANDASAMY and


our Secretary Dr. K. GUNASEKARAN, M.E., Ph.D., who encourages us in all
activities.

We here like to record our deep sense of gratitude to our beloved Principal
Dr. M. MADHESWARAN, M.E., Ph.D., for providing us the required facility to
complete our project successfully.

We extend our sincere thanks and gratitude to our Head of the Department
Dr. G. KAVITHA, M.S(By Research), Ph.D., Department of Computer Science
and Engineering for her valuable suggestions throughout the project.

It is pleasure to acknowledge the contribution made by our Project


Coordinator
Dr. S. VIJAYARAGAVAN, M.E., Ph.D., Assistant Professor, Department of
Artificial Intelligence and Data Science for his efforts to complete our project
successfully.

It is grateful to acknowledge the support provided by our Project Guide


Mrs. .K. GANDHIMATHI., M.E., Assistant Professor, Department of Computer
Science and Engineering for her guidance to complete our project successfully.

The satisfaction and euphoria that accompanies the successful completion of


any task that would be incomplete without acknowledging the people who are

3
responsible for completion of the project.

CHAPTER TITLE PAGE


No. No.
ABSTRACT 5
LIST OF FIGURES 6
LIST OF ABBREVIATIONS 6
1 INTRODUCTION 7
2 SYSTEM ANALYSIS 08
2.1. Proposed System 08
3 SYSTEM REQUIREMENTS 10
3.1. Hardware Requirements 10
3.2. Software Requirements 10
4 PROJECT DESCRIPTION 13
4.1. SYSTEM IMPLEMENTATION 24
4.3 MORPHOLOGICAL OPERATION 29
5 CONCLUSION 33

4
ABSTRACT

 Day by day, there are different types of intelligent systems are


introduced with the improvement in technology. Everything is
getting more intelligible and stylish. There is a growth in the
demand for cutting-edge technology and also smart electronic
systems.

 Microcontrollers have become an essential part of the present


technologies that are being presented daily.

 Temperature-based fan speed control and monitoring systems


using an Arduino system. This system is used to control the
cooling system automatically based on the room temperature.

 The system uses an Arduino board to implement a control system.


Since this system is proposed to control the cooling system it is
very important to know the Arduino controlled system well.

 An Electric fan is one of the most popular electrical devices due to


its cost-effectiveness and low power consumption advantages. It is
a common circuit and widely used in many Applications. It is also
one of the most sensible solutions to offer a comfortable and
energy efficient. The fan has been long used and is still available
in the market.

 The study was conducted with the design and manufacture of an


Automatic Fan Control System. Further functional testing tools, as
well as temperature sensors, is used.

5
LIST OF FIGURES

 Pulse Width Modulation

 LM 35 temperature sensor

 16x2 LCD

 Arduino UNO

 Circuit diagram of Temperature based fan speed controller

 Block diagram of Temperature based fan speed controller

LIST OF ABBREVIATIONS
ACRONYMS ABBREVIATIONS

LCD Liquid Crystal Display


DI Digital Input
AI Analog Input
DC Direct Current
DCM DC Motor
MC Micro controller
DL Deep Learning
R Resistor
TR Transformer
PWM Pulse width modulation

6
INTRODUCTION

 With the advancement in technology, intelligent systems are

introduced every day. Everything is getting more sophisticated and

intelligible. There is an increase in the demand of cutting edge

technology and smart electronic systems.

 Microcontrollers play a very important role in the development of

the smart systems as brain is given to the system. Microcontrollers

have become the heart of the new technologies that are being

introduced daily.

 A microcontroller is mainly a single chip microprocessor suited for

control and automation of machines and processes.

 Today, microcontrollers are used in many disciplines of life for

carrying out automated tasks in a more accurate manner. Almost

every modern day device including air conditioners, power tools,

toys, office machines employ microcontrollers for their operation.

 Microcontroller essentially consists of Central Processing Unit

(CPU), timers and counters, interrupts, memory, input/output ports,

analog to digital converters (ADC) on a single chip.

7
PROPOSED SYSTEM

 In the proposed systems, microcontroller plays a vital role in the

smart systems development. Microcontrollers have become an

essential part in the present technologies that are being presented

daily. This article discusses temperature based fan speed control

and monitoring system using an Arduino system.

 This system is used to control the cooling system automatically

based on the room temperature. The system uses an Arduino

board to implement a control system. Since this system is

proposed to control the cooling system and it is very important to

know Arduino controlled system well.

 chip integrated circuit design of the microcontroller the size of

control board is reduced and power consumption is low.

 This project presents the design and simulation of the fan speed

control system using PWM technique based on the room

temperature.

 A temperature sensor has been used to measure the temperature

of the room and the speed of the fan is varied according to the

room temperature using PWM technique.

8
DESCRIPTION

 The temperature-based fan speed control system can be done by

using an electronic circuit using an Arduino board.

 Now Arduino board is very progressive among all electronic

circuits, thus we employed the Arduino board for fan speed control.

 The proposed system is designed to detect the temperature of the

room and send that information to the Arduino board. Then the

Arduino board executes the contrast of current temperature and

set temperature based on the inbuilt program of the Arduino.

 The outcome obtained from the operation is given through the o/p

port of an Arduino board to the LCD display of related data. The

generated pulses from the board which is further fed to the driver

circuit to get the preferred output to the fan.

 The duty cycle is varied from 0 to 100 to control the fan speed

depending upon the room temperature, which is displayed on

Liquid Crystal Display.

9
SYSTEM REQUIREMENTS

1. HARDWARE REQUIREMENTS:

 Board-Arduino Uno

 LCD-16x2 Display

 IC-LM35 temperature sensor

 Transistor-BD139

 Diode-1N4007

 LED

 R1-R2-1-kilo-ohm

 Variable resistor-10 kilo-ohm

 Capacitor-10uF,16velectrolicty

 Fan-9 V DC

 Battery - 9V for fan

2. SOFTWARE REQUIREMENTS:

 Arduino 2.3.2

10
PROJECT DESCRIPTION

Arduino UNO Basic Information:

 Arduino is an open-source electronics platform based on easy-to-


use hardware and software. Arduino boards are able to read inputs
- light on a sensor, a finger on a button, or a Twitter message - and
turn it into an output - activating a motor, turning on an LED,
publishing something online. You can tell your board what to do by
sending a set of instructions to the microcontroller on the board. To
do so you use the Arduino programming language (based on
Wiring), and the Arduino Software (IDE), based on Processing.
 Over the years Arduino has been the brain of thousands of
projects, from everyday objects to complex scientific instruments.
A worldwide community of makers - students, hobbyists, artists,
programmers, and professionals - has gathered around this open-
source platform, their contributions have added up to an incredible
amount of accessible knowledge that can be of great help to
novices and experts alike.
 Arduino was born at the Ivrea Interaction Design Institute as an
easy tool for fast prototyping, aimed at students without a
background in electronics and programming. As soon as it reached
a wider community, the Arduino board started changing to adapt to
new needs and challenges, differentiating its offer from simple 8-bit
boards to products for IoT applications, wearable, 3D printing, and

11
embedded environments. All Arduino boards are completely open-
source, empowering users to build them independently and
eventually adapt them to their particular needs. The software, too,
is open-source, and it is growing through the contributions of users
worldwide
 It’s simple and accessible user experience, Arduino has been used
in thousands of different projects and applications. The Arduino
software is easy-to-use for beginners, yet flexible enough for
advanced users. It runs on Mac, Windows, and Linux. Teachers
and students use it to build low cost scientific instruments, to prove
chemistry and physics principles, or to get started with
programming and robotics. Designers and architects build
interactive prototypes, musicians and artists use it for installations
and to experiment with new musical instruments. Makers, of
course, use it to build many of the projects exhibited at the Maker
Faire, for example. Arduino is a key tool to learn new things.
Anyone - children, hobbyists, artists, programmers - can start
tinkering just following the step by step instructions of a kit, or
sharing ideas online with other members of the Arduino
community.
 There are many other microcontrollers and microcontroller
platforms available for physical computing. Parallax Basic Stamp,
Netmedia's BX-24, Phidgets, MIT's Handyboard, and many others
offer similar functionality. All of these tools take the messy details
of microcontroller programming and wrap it up in an easy-to-use
package. Arduino also simplifies the process of working with
microcontrollers, but it offers some advantages for teachers,
students, and interested amateurs over other systems:

12
Inexpensive:

 Arduino boards are relatively inexpensive compared to other


microcontroller platforms. The least expensive version of the
 Arduino module can be assembled by hand, and even the pre-
assembled Arduino modules cost less than

Cross-platform:

 The Arduino Software (IDE) runs on Windows, Macintosh OSX,


and Linux operating systems. Most microcontroller systems are
limited to Windows.

Simple, clear programming environment:

 The Arduino Software (IDE) is easy-to-use for beginners, yet


flexible enough for advanced users to take advantage of as well.
For teachers, it's conveniently based on the Processing
programming environment, so students learning to program in that
environment will be familiar with how the Arduino IDE works.

Open source and extensible software:

 The Arduino software is published as open source tools, available

for extension by experienced programmers. The language can be


expanded through C++ libraries, and people wanting to understand
the technical details can make the leap from Arduino to the AVR C
programming language on which it's based. Similarly, you can add
AVR-C code directly into your Arduino programs if you want to.

Open source and extensible hardware:

 The plans of the Arduino boards are published under a Creative


Commons license, so experienced circuit designers can make their
own version of the module, extending it and improving it. Even

13
relatively inexperienced users can build the breadboard version of
the module in order to understand how it works and save money.

SPECIFICATIONS

 Microcontroller: ATmega328
 Operating Voltage: 5V
 Input Voltage (recommended): 7-12V
 Input Voltage (limits): 6-20V
 Digital I/O Pins: 14 (of which 6 provide PWM output)
 Analog Input Pins:6
 DC Current per I/O Pin:40 mA
 DC Current for 3.3V Pin:50 mA
 Flash Memory:32 KB of which 0.5 KB is used by
 Bootloader
 SRAM:2 KB
 EEPROM :1 KB
 Clock Speed:16 MHz

14
General Pin functions:

 LED: There is a built-in LED driven by digital pin 13. When the pin
is HIGH value, the LED is on, when the pin is LOW, it's off.
 VIN: The input voltage to the Arduino/Genuino board when it's
using an external power source (as opposed to 5 volts from the
USB connection or other regulated power source). You can supply
voltage through this pin, or, if supplying voltage via the power jack,
access it through this pin.
 5V: This pin outputs a regulated 5V from the regulator on the
board. The board can be supplied with power either from the DC
power jack (7 - 20V), the USB connector (5V), or the VIN pin of the
board (7-20V). Supplying voltage via the 5V or 3.3V pins bypasses
the regulator, and can damage the board.
 3V3: A 3.3 volt supply generated by the on-board regulator.
Maximum current draw is 50 mA.
 GND: Ground pins.
 IOREF: This pin on the Arduino/Genuino board provides the
voltage reference with which the microcontroller operates. A
properly configured shield can read the IOREF pin voltage and
select the appropriate power source or enable voltage translators
on the outputs to work with the 5V or 3.3V.
 Reset: Typically used to add a reset button to shields which block
the one on the board.

15
Special Pin Functions:

 Each of the 14 digital pins and 6 Analog pins on the Uno can be
used as an input or output, using pin Mode (), digital Write(), and
digital Read() functions. They operate at 5 volts. Each pin can
provide or receive 20 mA as recommended operating condition
and has an internal pull-up resistor (disconnected by default) of 20-
50k ohm. A maximum of 40mA is the value that must not be
exceeded on any I/O pin to avoid permanent damage to the
microcontroller. The Uno has 6 analog inputs, labelled A0 through
A5, each of which provide 10 bits of resolution (i.e. 1024 different
values). By default they measure from ground to 5 volts, though is
it possible to change the upper end of their range using the AREF
pin and the analog Reference () function.

In addition, some pins have specialized functions:

 Serial: pins 0 (RX) and 1 (TX). Used to receive (RX) and transmit
(TX) TTL serial data. These pins are connected to the
corresponding pins of the ATmega8U2 USB-to-TTL Serial chip.
 External Interrupts: pins 2 and 3. These pins can be configured
to trigger an interrupt on a low value, a rising or falling edge, or a
change in value.
 PWM (Pulse Width Modulation) 3, 5, 6, 9, 10, and 11 Can provide
8-bit PWM output with the analog Write() function.
 SPI (Serial Peripheral Interface): 10 (SS), 11 (MOSI), 12 (MISO),
13 (SCK). These pins support SPI communication using the SPI
library.

16
 TWI (Two Wire Interface): A4 or SDA pin and A5 or SCL pin.
Support TWI communication using the Wire library.
 AREF (Analog Reference: Reference voltage for the analog inputs.

Communication:

 The Arduino Uno has a number of facilities for communicating with


a computer, another Arduino/Genuino board, or other
microcontrollers.
 The ATmega328 provides UART TTL (5V) serial communication,
which is available on digital pins 0 (RX) and 1 (TX). An
ATmega16U2 on the board channels this serial communication
over USB and appears as a virtual com port to software on the
computer.
 The 16U2 firmware uses the standard USB COM drivers, and no
external driver is needed. However, on Windows, a .inf file is
required. The Arduino Software (IDE) includes a serial monitor
which allows simple textual data to be sent to and from the board.
 The RX and TX LEDs on the board will flash when data is being
transmitted via the USB-to-serial chip and USB connection to the
computer (but not for serial communication on pins 0 and 1). A
Software Serial library allows serial communication on any of the
Uno's digital pins.

Automatic (Software) Reset:

 Rather than requiring a physical press of the reset button before


an upload, the Arduino/Genuino Uno board is designed in a way
that allows it to be reset by software running on a connected
computer. One of the hardware flow control lines (DTR) of the

17
ATmega8U2/16U2 is connected to the reset line of the
ATmega328 via a 100 nanofarad capacitor. When this line is
asserted (taken low), the reset line drops long enough to reset the
chip.
 This setup has other implications. When the Uno is connected to

either a computer running Mac OS X or Linux, it resets each time a

connection is made to it from software (via USB). For the following

half-second or so, the bootloader is running on the Uno. While it is

programmed to ignore malformed data (i.e. anything besides an

upload of new code), it will intercept the first few bytes of data sent

to the board after a connection is opened.

Pulse Width Modulation (PWM):

 Pulse Width Modulation, or PWM, is a technique for getting analog

results with digital means. Digital control is used to create a square

wave, a signal switched between on and off. This on-off pattern

can simulate voltages in between full on (5 Volts) and off (0 Volts)

by changing the portion of the time the signal spends on versus

the time that the signal spends off. The duration of "on time" is

called the pulse width. To get varying analog values, we change,

or modulate, that pulse width. If we repeat this on-off pattern fast

enough with an LED for example, the result is as if the signal is a

steady voltage between 0 and 5v controlling the brightness of the

18
LED. In the graphic below, the green lines represent a regular time

period. This duration or period is the inverse of the PWM

Frequency

Temperature Sensor:

 We are using LM 35 as a temperature sensor. LM 35 is a precision

temperature sensor whose output is linearly proportional to Celsius

Temperature. The LM35 is rated to operate from -55° Centigrade

to 150° Centigrade with a linear scale factor of +10mv/° C

19
Features:

 Calibrated directly in degree Celsius (centigrade)

 Linear +10.0 mV/ degree Celsius

 0.5 degree Celsius accuracy (at +25degree Celsius)

 Rated for full -55 to +150 degree Celsius range

 Suitable for remote applications

 Low cost due to wafer-level trimming

 Operates from 4 to 30 volts

 Less than 60 Micro ampere current drains

 Low self-heating, 0.08 degree Celsius in still air

 Nonlinearity only +/- 1/4 degree Celsius typical

 Low impedance output, 0.1 Ohm for 1mA load

20
Liquid Crystal Display:

 The LCD is a dot matrix liquid crystal display that displays

alphanumeric characters and symbols. 16X2 LCD digital display

has been used in the system to show the room temperature. Liquid

Crystal Display screen is an electronic display module and find a

wide range of applications. A 16x2 LCD display is very basic

module and is very commonly used in various devices and circuits.

 These modules are preferred over seven segments and other multi

segment LEDs. The reasons being: LCDs are economical; easily

programmable; have no limitation of displaying special & even

custom characters (unlike in seven segments), animations and so

on. A 16x2 LCD means it can display 16 characters per line and

there are 2 such lines. In this LCD each character is displayed in

5x7 pixel matrix.

 This LCD has two registers, namely, Command and Data. The

command register stores the command instructions given to the

LCD.

21
 A command is an instruction given to LCD to do a predefined task

like initializing it, clearing its screen, setting the cursor position,

controlling display etc. The data register stores the data to be

displayed on the LCD. The data is the ASCII value of the character

to be displayed on the LCD.

22
Pin Function Name
No
1 Ground (0V) Ground
2 Supply voltage; 5V (4.7V – 5.3V) Vcc
3 Contrast adjustment; through a variable VEE
resistor
4 Selects command register when low; and Register Select
data register when high
5 Low to write to the register; High to read Read/write
from the register
6 Sends data to data pins when a high to low Enable
pulse is given
7 DB0
8 DB1
9 DB2
10 8-bit data pins DB3
11 DB4
12 DB5
13 DB6
14 DB7
15 Backlight VCC (5V) Led+

16 Backlight VCC (5V) Led-

SYSTEM IMPLEMENTATION

23
CIRCUIT DIAGRAM OF THE TEMPERATURE-BASED FAN SPEED

CONTROL & MONITORING USING ARDUINO:

24
BLOCK DIAGARAM

LCD DISPLAY

LM35
ARDUINO
BOARD
FAN

 Arduino board is very progressive among all electronic circuits,


thus we employed the Arduino board for fan speed control. The
proposed system is designed to detect the temperature of the
room and send that information to the Arduino board.

 Then the Arduino board executes the contrast of current


temperature and set temperature based on the inbuilt program of
the Arduino. The outcome obtained from the operation is given
through the o/p port of an Arduino board to the LCD display of
related data. The generated pulses from the board which is further
fed to the driver circuit to get the preferred output to the fan.

ARDUINO PROGRAMME:

25
26
27
28
MORPHOLOGICAL OPERATION

 I used an LCD shield to display the current temperature and speed


of the fan, but you can use the circuit without the LCD display. You
also need to select the transistor by the type of fan that you use. In
my case I used the well-known BD139 transistor and a 9V battery
to provide power to the fan and transistor.
 The LM35 temperature sensor and red led are powered with 5V
from the Arduino board.
 As you can see in the sketch on the first line I included the Liquid
Crystal library (header) that includes useful functions to use when
an LCD is connected to the Arduino board. Then I set the pins for
the sensor, led and fan.
 The most important part is to set the variables temp Min and temp
Max with your desired values. Temp Min is the temperature at
which the fan starts to spin and temp Max is the temperature when
the red led lights warning you that the maximum temp was
reached. For example if you set temp Min at 30 and temp Max at
35 then the fan will start spinning at 30°C and reach its maximum
speed at 35°C.
 We store the temperature value in the temp variable and then use
some if() functions to check if temp is lower than temp Min and if
so let the fan OFF (LOW). The next if() is to check if temperature is
higher than the min Temp and lower than the temp Max and if so
then use the map() function to re-map the temp value from one
value to another.

29
 In our case fanSpeed will have a value of 32 at temp Min and 255
at temp Max. These values are used to control the speed of the
fan using PWM and the analog Write ().

 The fan LCD re-maps the temp to allow the display of fan Speed in
a 0 to 100% range so you can say that the speed of the fan is
directly dependent of the LM35’s temperature. When the
temperature reaches the value set in temperature Max the fan will
be at its maximum spinning velocity and the LCD will display
FANS: 100% even though the temperature might increase above
temp Max.
 The rest of the explanation can be read in the comments area of
the Arduino sketch.
 In the next project I will make a temperature protection circuit that
will turn off the power of equipment when its temperature has
reached a certain value.

30
RESULT

 The electric fan operates automatically according to temperature


rises in order to compensate for the rise in the temperature fun
running at full speed when the temperature returns back to the
normal temperature fun running normal speed

31
APPLICATION:

 Personal computers

 Exhaust fans in large hotels

 Washing machines

 The circuit can be used for Car Engine to reduce the heat.

 This project can be used in Home.

 This project can be used in Industry.

 This will help in saving the energy/electricity

ADVANTAGES OF TEMPERATURE CONTROLLED FAN:

 It is very economical and easy to handle by the user.

 Speed varies automatically so that it controls the speed without

using it manually.

 It is help full to disabled People.

 It is very easy to install in offices, houses etc.

 Save energy by slowing down its speed in low temperatures.

32
CONCLUSION

This paper elaborates on the design and construction of a fan speed


control system to control the room temperature. The temperature sensor
was carefully chosen to gauge the room temperature. Moreover, the fan
speed will increase automatically if the temperature room is increased. In
conclusion, the system which designed in this work was perform very
well, for any temperature change and can be classified as automatic
control.

33
REFERENCES:

https://www.arduino.cc/en/Main/Software

www.ti.com/product/LM35

www.learningaboutelectronics.com

https://components101.com/lm35-temperature-sensor

https://circuitdigest.com/.../16x2-lcd-display-module

https://www.engineersgarage.com/.../16x2-lcd-module

https://www.build-electronic-circuits.com/how-transistor

34

You might also like