0% found this document useful (0 votes)
72 views58 pages

1128-TJSEC Project Report (1) .Docx 71)

Uploaded by

4302-Balaji J
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
72 views58 pages

1128-TJSEC Project Report (1) .Docx 71)

Uploaded by

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

Smart Room Temperature Controller Systam

A PROJECT REPORT
Submitted by

Suriya.L 112820104310
Saranraj.S 112820104017
Rahul Sanjay.A 112820104307

In partial fulfilment for the award of the degree

BACHELOR OF ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

T.J.S. ENGINEERING COLLEGE, PERUVOYAL

ANNA UNIVERSITY: CHENNAI 600 025


MAY 2024
BONAFIDE CERTIFICATE

Certificate that this project report “Smart Room Temperature Controller


Systam” bonafide work of the following students.

Suriya.L 112820104310
Saranraj.S 112820104017
Rahul Sanjay.A 112820104307

Who carried out the project work under my supervision,

SIGNATURE SIGNATURE
Mrs.J.AGNES,M.E.,(CSE) Ms.V.PAVITHRA.,M.E.,(CSE)

HEAD OF THE DEPARTMENT SUPERVISOR


Department of Computer Science Department of Computer Science
and Engineering, and Engineering,

T.J.S. Engineering College, T.J.S. Engineering College,


Peruvoyal. Peruvoyal.

Submitted for viva voice held on at T.J.S. Engineering College, Peruvoyal.

INTERNAL EXAMINER EXTERNAL EXAMINER


ACKNOWLEDGEMENT

"Project is the product out of experience that goes a long way in shaping up a person's calibre.
The experience and success one attains is not by oneself but with a group of kind hearts
behind.”First and foremost, we express our sincere thanks to honourable Founder and
Chairman"KALVI NERI KAVALAR" Shri. T.J.GOVINDARAJAN B.A., Managing
Director &Secretary Shri. T.J.ARUMUGAM., Vice Chairman Shri. T.J.DESAMUTHU.
We extend our deepest gratitude to our dynamic principal Dr.J.PRAKASH,ME.,PhD., for
his kind support during the course of the project.

We express our gratitude to Mrs.J.AGNES,M.E(CSE)., Head of the


Department of Computer Science and Engineering whose guidance and
encouragement has helped us in completing this project work.

We extend our sincere thanks to our guide Ms.V.PAVITHRA.,M.E.,(CSE) and


all other TEACHING FACULTIES and NON-TEACHING STAFF of Department
of Computer Science and Engineering for giving the confidence to complete the
project successfully by providing the valuable suggestions and interest at every stage
of the project.

Further the acknowledgement would be incomplete if we would not mention a


word thanks to our most beloved PARENTS and FRIENDS whose continuous
support and encouragement all the way through the course has led us to pursue the
degree and confidently complete the project.
ABSTRACT
This project work presents the design of an automated room temperature controller
system. This system allows the user to set a desired temperature which is then
compared to the room temperature measured by DHT11 temperature sensor. With
the help of Atmega 328 based on Arduino microcontroller, the system responds by
turning ON and OFF the two (2) loads (fan or a heater) automatically depending
on the temperature difference in the room. The fan is triggered ON when the room
temperature is higher than the set temperature and the heater is triggered ON when
the room temperature is lower than the set temperature. The system was designed
and simulated using Proteus 8, circuit building software used for building
electronics system. Proteus software was used to design and simulate the main
circuit; Arduino IDE was used to write a program on how the system will operate
which was then loaded to the microprocessor. An LCD was used to display
temperature readings obtained by the DHT11 temperature sensor and the condition
of the heater and the fan whether ON or OFF. A digital multimeter was then used to
take the voltage readings across the heater and the fan. When the system was
simulated the heater and the fan were turned on automatically depending on the
room temperature. The heater turned on when the temperature was below 27
degree Celsius while the fan turned on when temperature fell below the threshold.
In both cases, either of them was on at a specified time but not both. When the
heater was on the fan was off and vice versa.

KEYWORDS: Arduino, Automation, threshold value, temperature


DEFINITION OF TERMS
Arduino
Arduino is an open-source electronics platform based on easy to use hardware and
software that allows programming and prototyping.
Automation
The act of implementing the control of equipment with advanced technology
involving electronic hardware.
Threshold value

This is the reference value or minimum value above or below which the control
unit is supposed to switch the fan or heater ON or OFF.
Temperature

This is the hotness or coldness of a body that can be detected by a


temperature sensor or a temperature measuring device.
List of figures
Figure 2.1 DHT11 Temperature and
Humidity sensor Figure 2.2 16 ×2 Liquid
Crystal Display.
Figure 2.3 Arduino uno rev 3 pins
Figure 2.4 Arduino Uno rev 3 and pins
description. Figure 2.5 A sketch of Arduino
IDE window.

Figure 3.1 A figure showing DHT11 sensor connection


to Arduino Figure 3.2 A figure showing LCD connection
to the control unit

Figure 3.3 Circuit diagram of the automated room temperature controller system.
List of tables
Table 2.1 Electrical characteristics of DHT
11 sensor Table 2.2 LCD pins ant their
connections

Table 3.1 A table showing all components connections to the


control unit Table 3.2 A table showing pins of the DHT 11
sensor and their connection Table 4.1 A table showing output
voltages

List of graphs
Graph 4.1 A graph of voltage (V) against Temperature (degree Celsius)
Table of Contents
DECLARATION i

DEDICATION ii
ACKNOWLEDGEMENT iii
ABSTRACT iv
DEFINITION OF TERMS v
List of figures v
Figure 2.1 DHT11 Temperature and Humidity sensor v
Figure 2.2 16 ×2 Liquid Crystal Display. v
Figure 2.3 Arduino uno rev 3 pins v
Figure 2.4 Arduino Uno rev 3 and pins description. v
Figure 2.5 A sketch of Arduino IDE window. v
Figure 3.1 A figure showing DHT11 sensor connection to Arduino v
Figure 3.2 A figure showing LCD connection to the control unit v
Figure 3.3 Circuit diagram of the automated room temperature controller system. v
List of tables vi
Table 2.1 Electrical characteristics of DHT 11 sensor vi
Table 2.2 LCD pins ant their connections vi
Table 3.1 A table showing all components connections to the control unit vi
Table 3.2 A table showing pins of the DHT 11 sensor and their connection vi
Table 4.1 A table showing output voltages vi
List of graphs vi
Graph 4.1 A graph of voltage (V) against Temperature (degree Celsius) vi
CHAPTER 1 1
2.0 BACKGROUND OF STUDY 1
2.1 PROBLEM STATEMENT 2
2.2 OBJECTIVES 2
2.2.1 MAIN OBJECTIVE 2
2.2.2 SPECIFIC OBJECTIVE 2
2.3 JUSTIFICATION AND SIGNIFICANCE 2
CHAPTER 2 3
2.0 LITERATURE REVIEW 3
2.1 Related work 3
2.2 Sensors 4
2.2.1 Contact Sensors 5
2.2.2 Non-contact sensors 5
2.3 DHT11 Temperature and Humidity sensor. 5
2.4 LCD (Liquid Crystal Display) 7
2.5 Microcontroller 8
2.5.1 Alf and Vegard’s RISC Processor (AVR) 8
2.5.2 8051 Microcontroller 8
2.5.3 Programmable Interface Controller (PIC) 8
2.5.1 Arduino 8
CHAPTER 3 13
3.0 Design and implementation 13
3.1 Hardware Design 13
3.1.1 Control unit 13
3.1.2 Sensing unit 14
3.1.3 Display unit 15
CHAPTER 4 17
4.0 Results and discussions 17
4.1 Results 17
GRAPH 18
4.2 DISCUSSION 18
CHAPTER 5 19
5.0 CONCLUSION 19
5.1RECCOMENDATIONS 19
APPENDICES 20
CODE 20
REFERENCES 23
INTRODUCTION
In modern days, many intelligent technologies are introduced in our environment.
In the smart electronic world microcontroller plays an important role in the
development of smart system. New technologies are developed day by day, in this
many technologies microcontrollers act as the heart of the system. These
microcontroller consist of single chip processor it is suitable for the automation and
control process and also it gives the accurate results. Now a days maintaining a
room temperature in home and offices has been an increasing problem. In order to
solve the problem the controlling of temperature becomes a solution for this arising
problem. Controlling of temperature is a process, in which the temperature of the
space or object is changed. This paper describes the maintaining of constant room
temperature and also enables the automatic cooling and heating system according to
the room temperature. The design and implementation of system was done by
arduino hardware and the program is written in arduino IDE and it displays the
temperature in LCD. According to the temperature change it enables the cooling and
heating system by AC and heater.
I. LITERATURE REVIEW

Joseph chuma and Bokamoso Basulti has proposed the system of design and
simulate the controlling of room temperature using pic microcontroller. This system
was mainly useful for the people who are disabled. In this system the temperature
was measured by the LM35 temperature sensor and the temperature displayed in a
LCD display. The temperature value senses the PIC16F877A controller.According
to the temperature changes the fan gets on or off. The temperature value is higher
than the reference value the fan gets on and the temperature value is lower than the
reference value the fan gets off. The reference value is entered by using keypad.
Relay is used for the switching purpose. Software proteus 8 is used for simulating
the result[1]. M.Kumaran,and

.Vikramhas proposed the system of automatic fan speed control using arduino
uno. The process of the system is controlled by the arduino uno controller. The
temperature is measured by the LM35 temperature sensor. Potentiometer is act as the
regulator is connected to the microcontroller. The fan speed is controlled by
thepotentiometer. Depending on the variation in the temperature the speed of the fan
is on or off. The fan speed is measured manually and the speed of the fan and
Minute(RPM).Temperature changes, and the RPM fan speed changes occurs[2]. Suraj
kausik and yuvraj singh chouhan has proposed a system on fan speed controlling system
using temperature and humidity sensor. The controller used in this system is arduino
microcontroller. According to the environmental temperature the fan speed is manually
controlled. The temperature and humidity is measured by DHT22 Sensor and displayed
in the LCD. The duty cycle of the temperature is already set as the reference
temperature. The values of the duty cycle changes the fan speed also varies on the
temperature change. The fan speed is controlled by the Pulse Width Modulation
(PWM). PWM controls the fan speed with respect to the sensed temperature [3]
E.Harshavardhan Goud and A.Harshika has proposed a temperature controlled system
using arduino. It is a real time implementation project. LM35 temperature sensor is used
to measure the temperature as the appropriate voltage. This voltage is given to the
arduino. The temperature value is displayed in the 16x2 LCD display in both Fahrenheit
and centigrade unit. The controller sends the data to the relay. Relay is act as the
switching device. The temperature become beyond the level of data set by the user the
relay gets triggered and activate. Than the relay switches the cooling device. In this way
it controls and monitors the temperature control [4]. Kunal singh and Moloy Dhar has
proposed
CHAPTER 1
BACKGROUND OF STUDY

The idea of an automated room temperature controller system goes back to the
eighteenth century. The idea was first secured in Norman School, Oklahoma by an
educator named Warren
S. Johnson. It was called Automatic temperature adjusting system for air
conditioner room.(Johnson et al., 2006).
Earlier Janitors were compelled to move in every classroom to check the
temperature of the classes, and after that, control the dampers in the S-basement in
like manner. Johnson introduced an approach that would end, or possibly limit the
classroom intrusions of the janitors. ( Johnson et al., 2006). The Automatic
Temperature Control System was to meet this very need which prompted Warren
S. Johnson stop teaching and began his electric administration organization that
specialized in programmed control systems. Warren S. Johnson initially built
temperature control framework which was used in temperature control in a room
by room in structures and homes.
By the mid twentieth century the Automatic Temperature Control System was
noticeable in enterprises and homes. A great number of automatic room heater
systems are now accessible in the market and this includes devices such as
AIRCONS ( Johnson et al., 2006).Weather changes at short intervals, and as a
result, the external conditions always have an influence on the indoor conditions.
The temperature control systems that are currently in use have limitations. One
of these limitations is that the user has to manually adjust the system every time
the external conditions change. This is cumbersome and not to be an effective
way of controlling the temperature of a room. Also, physically challenged people
face a lot of difficulties when operating temperature control system in their
houses because these systems require them to use physical contact or some hand
remote devices to operate them.
To reduce the need for human intervention, a system that works automatically is
handy. This research project presents an automated room temperature controller
system. This is an air conditioning system which monitors the room temperature
and controls the circulation of fresh air in the room without human intervention.
This design uses a microcontroller and a DHT11 temperature sensor to monitor
and control the temperature of a room. The user sets the system temperature to a
reference value (threshold value) that he or she wants to maintain in that room.
The temperature sensor detects the temperature and communicates with the
microcontroller. The microcontroller reads the temperature and compares it with
the set value. If the measured value is less than the set value, the heater is
automatically turned ON to warm up the temperature of the room until it returns
back to the set value and turns OFF. If the measured value is greater than the set
value, the fan is automatically turned ON to cool up the temperature of the room
until it returns back to the desired value and turns OFF. This work saw the design
of a simple, efficien
and cost-effective temperature control system. The system considered the
10 principles of sustainable and cost effective design( S. Ludwig and J.
Pritchard,2010).
2.0 PROBLEM STATEMENT
All living organisms want comfort and do away with all aspects that try to bring
discomfort to them. One of the common causes of discomfort is temperature
fluctuations. Human beings are the most peculiar species known for its problem-
solving skills and they have not been left behind in trying to solve these
temperature fluctuations. Most of the systems present however are manual hence
tedious to turn on and off. These expensive systems are also disadvantageous to
the physically challenged people who find it difficult to access switching
mechanisms. This makes it necessary to have an automated room temperature
controller system within the home that can be operated by both able-bodied and
physically challenged. The air conditioner minimizes discomforts due to varying
weather conditions. This system is efficient, cheaper, easier to use and cost
effective.
2.1 OBJECTIVES

2.1.1 MAIN OBJECTIVE

To design a room temperature controller system.

2.1.2 SPECIFIC OBJECTIVE


1. To record voltage outputs across the DHT 11 sensor, fan and heater
when they are in operation.
2. To test its applicability in different temperature ranges as measured by
the DHT11 temperature sensor.
2.2 JUSTIFICATION AND SIGNIFICANCE
Advancement of technology has made automation become part of our lives. A
home is usually the most occupied place. Areas in the home that are usually occupied
by people, such as the living room and bedrooms need to be maintained within an
acceptable temperature ranges. The problem becomes more acute in areas of the
home that are occupied by infants. Adults could possibly find their way around
thermal discomforts, but infants may not. Other rooms in home that are used as
storage for perishable food items also need to be thermally regulated in order to
prevent accelerated decay of such items. Hence this project is a need of the hour.
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 LED.In the graphic below, the green lines
represent a regular time period. This duration or period is the inverse of the
PWM frequency.
CHAPTER 2
LITERATURE REVIEW
Related work

In the past few years, the need for automation has increased and has been
widely applied to cooling and heating systems. There are plenty of commercial
temperature control systems which can be bought from manufacturers or inventors,
and also, quite a lot of work has been published in this area.

In a related invention (Hedges,1947),R.E. Hedges invented an automatic


temperature control systems intended at automatically controlling the temperature
of an object or a region so as to continuously maintain the said temperature at a
constant value. In his design, the temperature control system can only control a
single heat source. It is difficult therefore to attain temperature control of systems
emitting simultaneously and in combination of the desirable features of large
capacity, high response, and accuracy.

In 1992 (Ian,1992) , Ian Bell invented a self-programmable heating and cooling


system, which is based on temperature control system. This system is not easy to
operate and can only be operated by experts as it has to be interfaced with a
computer anytime the re-programming is needed.

M. R. Levine (Levine, 2013) invented an automatic temperature adjusting system


for an air conditioner room. The automatic temperature adjusting system for the
air conditioner room was made simple in operation and was capable of monitoring
the temperature of the human body at any time in the air conditioned room and
transmits the corresponding signals to the air conditioner in time. The air
conditioner conducts adjustment, so that the health of people is guaranteed.
However, this is also a one-time programming and it is needed to be interfaced
with the computer anytime reprogramming is needed, hence, the operation of the
system becomes complex.
Other automated temperature controller systems that have been designed and
published include;
o Automatic temperature control for transport airplanes(Hedges, 1947).
o Wireless thermostat and room environment control system.( Tate and
Ries,1990)
o Automatic temperature control system.(Minoru, 1996) ,
o Automatic heater controller.( Poll,2006) .
o Design of automatic temperature control system on laser diode of
erbium-doped fiber source, in: Proceedings of (Chengxiang, Zhenhua,
Xu and Feng,, 2011).
o Design of automatic temperature-control circuit module in tunnel
microwave heating system.( Fu, Wang and Yang, 2011).

These designs are not easy to use in terms of programming and temperature
adjustment. The systems work on the benefits of using temperature adjustable
and fan temperature control
systems. These systems are either one time programmable or need analog
adjustment which is not accurate and more difficult to use.

More recent, real time based temperature control using Arduino was
published(Amoo et al,2014). The system uses Arduino based on ATMEL 89C51,
which is just one of the applications of Arduino. The system is not simple in terms
of operation as it is tedious to change the reference temperature. The system is
similar to the ones presented by the authors in the following systems;
o A precision temperature controller using embedded system.( Pimpalgaonkar et
al, 2011).
o Design and experiment about temperature control system of sealing
machine based on Fuzzy PID. (Cao et al, 2011).
Other works based on temperature control do exist in different areas and different
applications. Such work such as electric cable interference temperature monitoring
in power transmissions( Li et al, 2011), server room temperature measurement
using Bluetooth embedded system(Loup et al, 2011), control system for
communication room using wireless temperature monitoring system (Bing and
Wenyao, 2011) and temperature sensor and Zigbee based temperature
measurement(Pengfei et al, 2011)do exist. These systems have the same problem
of cost as well as the need for experts in re-programming.

This leaves a gap for the design of a system that is not only simple, cost effective,
efficient, easy to program and one that minimizes components so as to reduce the
size of the design. The automated room temperature controller system thus comes
in handy to provide solutions to the gaps that can be noted in the previous
systems. It is simple, cost effective and can be used to provide real-time air
conditioning for both home and commercial institutions.
Sensors

A sensor can be defined as a device that measures a physical quantity such as


temperature, light, motion or any other physical phenomenon and converts it into
an electrical signal(Mengistie, 2018). Examples of sensors include temperature
sensors, humidity sensors, motion detection sensors, oxygen sensors and infrared
sensors. The output of sensors is usually current, charge and voltage. Temperature
sensors are devices that are temperature sensitive, and respond to changes in
temperature.

There are 2 kinds of temperature sensors:


1) Contact sensors

2) Non-Contact sensors.

However, the 3 main types are thermometers, resistance temperature detectors,


and thermocouples. All three of these sensors measure a physical property (i.e.
volume of a liquid, current through a wire), which changes as a function of
temperature. In addition to the 3 main types of temperature sensors, there are
numerous other temperature sensors available for use.

DHT11 Temperature and Humidity senso


Contact Sensors
Contact temperature sensors measure the temperature of the object to which the
sensor is in contact by assuming or knowing that the two (sensor and the object)
are in thermal equilibrium, in other words, there is no heat flow between them
(Augustin & Fröhlich, 2019).
Examples include;
o Thermocouples
o Resistance Temperature Detectors (RTDs)
o Full System Thermometers
o Bimetallic Thermometers
2.0.2 Non-contact sensors
These temperature sensors measure the thermal radiant power of the Infrared or
Optical radiation received from a known or calculated area on its surface or volume
within it.
An example is the pyrometer
2.1 DHT11 Temperature and Humidity sensor.
DHT11 Temperature & Humidity Sensor features a temperature & humidity sensor
with a calibrated digital signal output. It uses exclusive digital-signal-acquisition
technique and temperature & humidity sensing technology; it ensures high
reliability and excellent long-term stability. This sensor includes a resistive-type
humidity measurement component and an NTC temperature measurement
component, and connects to a high performance 8-bit microcontroller, offering
excellent quality, fast response, anti-interference ability and cost-effectiveness.

Figure 2.1DHT11 Temperature and Humidity sensor


Electrical characteristics
Maximum 5V DC
power supply
Minimum 3VDC
power supply
Minimum 0.5mA
current supply

Maximum 2.5mA
current supply

The DHT11 has 4 pins as shown


below; Pin 1: VCC 3-5.5V DC

Pin 2: DATA PIN


Pin 3: NOT
CONNECTED Pin 4:
GROUND
2.2 LCD (Liquid Crystal Display)
The most basic and commonly used LCDS are the 16×2 because they are cheap,
easy to program and can display wide range of characters. This is a 16-pin device
which displays 16 × 2 characters. In this project the 16×2 LCD is used to display
the state of heater or fan and the DHT11 readings.

Figure 2.2.16 ×2 Liquid Crystal Display.


When using 8-bit configuration all 8 data pins (DB0-DB7) are used while only 4
data pins (DB4DB7) are used in a 4-bit configuration.

Table 2.2. LCD pins ant their connections

Pin Function symbol


number
1 Ground (0V) VSS
2 Supply voltage (5V) VDD
3 Contrast adjustment; through a variable V0
resistor(potentiometer)
4 Selects command register when low; and data RS
register when high

5 Low to write to the register; High to read from the RW


register
6 Sends data to data pins when a high to low pulse is E
given
7 8-bit data pins D0
8 8-bit data pins D1

8-bit data pins D2

9
10 8-bit data pins D3
11 8-bit data pins D4
12 8-bit data pins D5
13 8-bit data pins D6
14 8-bit data pins D7
15 Backlight VCC (5V) A

16 Backlight Ground (0V) K

2.3 Microcontroller
It can be defined as a self-contained system that incorporates a microprocessor for
sensing input from the real world and controlling devices based on the input. They
consist of a processor, memory and some peripherals. Microcontrollers are used in
digital applications for automation and as control units. They work according to a
program that is written in their processors. This programs are often written using
assembly languages but also high level languages such as C,C++ PASCAL and
Java(Mengistie, 2018).
Categories of microcontrollers
2.3.1 Alf and Vegard’s RISC Processor (AVR)
A Reduced Instruction Set Computer (RISC) is one whose Instruction Set
Architecture (ISA) allows it to have fewer cycles per instruction was developed in
1996 by Atmel corporation. They are loaded with an Integrated Development
Environment (IDE) and a C compiler. They contain output and input parts, timers,
interrupts, USART.12C interface channels and on chip analog comparators. They
are fabricated with Modified Harvard Architecture which allows what is contained
in the instruction memory to be assessed as if it were data. However, they are
difficult for beginners to work with (Barrett and Pack, 2006).
2.3.2 8051 Microcontroller
It was developed by Intel Corporation in 1980. It processes 8-bit data at a time and
their name results from the fact that they can all be programmed using 8051
assembly language(Mazidi, n.d.). Their main drawback is their language of
programming. The assembly language used is complex and difficult to use.
2.3.3 Programmable Interface Controller (PIC)
It was originally developed by General Instruments Microelectronics Division.
They are affordable and perform better than 8051 microcontrollers. They are better
off than 8051 microcontrollers because they have small low pic count devices,
however like 8051 microcontrollers they are difficult and cumbersome to program
hence cannot be recommended for a beginner.
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


2.5.1 Arduino
Arduino is a company in Italy that sells Printed Circuit Boards (PCBs) called
Arduino boards. Arduino is an open source electronics design platform which is
designed for prototyping and programming with Atmel microcontrollers(Arduino,
2018). They interact with physical environment through sensors. They can be made
to respond to physical phenomenon and hence are widely used for automation
purposes. Some of Arduino older boards include;
o Duemilanove
o Duecimila
o NG Rev C
o Arduino NG 240
o Arduino V2
o Arduino Extreme
o Arduino USB V2
2.5.1.1 Arduino UNO Rev 3
The word UNO means one in Italian and was chosen to mark the release of
Arduino software Integrated Development Environment(IDE)(Evans, 2011).This
is one type of Arduino boards that is widely used due to the following feature
o They have 8-bit bidirectional input/output pins with internal pull up resistors
o 1 KB Electronic Erasable Programmable ROM
o 32 KB flash memory
o 2 KB of RAM
Figure 2.3.Arduino uno rev 3 pins
Arduino UNO is a microcontroller board based on the ATmega328 datasheet. It has
14 digital input/output pins (6 can be used as PWM outputs), 6 analog inputs, a
16MHz crystal oscillator, a USB connection, a power jack, an ICSP header and
a reset button.
Examples of inputs: -temp sensor, motion sensor, distance sensor,
switch etc. Examples of outputs: -light, screen, motor etc.

Technical specifications
o Microcontroller- ATmega328
o Operating Voltage- 5V
o Supply Voltage (recommended)- 7-12V
o Maximum supply voltage (not recommended)- 20V
o Digital I/O Pins 14- (of which 6 provide PWM output)
o Analog Input Pins- 6
o DC Current per I/O Pin- 40 mA
o DC Current for 3.3V Pin- 50 mA
o Flash Memory- 32 KB (ATmega328) of which 0.5 KB used by bootloader
o SRAM 2 KB- (ATmega328)
o EEPROM- 1 KB (ATmega328)
o Clock Speed- 16 MHz
o LED_builtin- 13
o Length-68.6mm
o Width-53.4mm
o Weight-25g
Arduino pin functions
Figure 2.4.Diagrammatic view of Arduino Uno rev 3 and pins description

o USB TO PC: It is used to communicate Arduino via Universal Serial


Bus to PC for programming/sending data to Arduino serially.
o 7V to 12V DC input: - For external supply voltage. The recommended
voltage range is 7-12V. A 9V battery can also be used to power the Arduino
UNO.
o Reset Button: - It resets the Arduino board if pressed.
o ICSP: -An abbreviation for In Circuit Serial Programming which consists of
MOSI, MISO, SCK, RESET, VCC and GND. It is either used to Programme
USB or Microcontroller. It allows the user to Programme the microcontroller
when it is in circuits
i.e. it allows to Programme ATmega328p-pu directly with AVR instructions
without using Arduino IDE.
o SDA: - SERIAL Data; it is the bidirectional data line that is used by 12c.
o SCL: - Serial Clock; it is used to indicate that data is ready on bidirectional
data line that is used by 12C.
o AREF: - Analog Read Reference; it is mainly used for analog reference ()
function calls, as default it is not required but to use it you have to add some
voltage source between 0V to 5V in AREF pin which will be considered as
accurate reference voltage.
o GND: - Ground
o SCK: - Serial Clock, which is used by SPI (Serial Peripheral Interface).
It is clock generated by a master which is used to clock the data to the slave.
o MOSI: - Master out Slave In; the data transmitted from master to slave
o MISO: - Master in Slave Out; the data transmitted to master from slave
o SS: -Slave Select; it is used to select the ‘slave’. Make high to SS pin to
deactivate and make low to activate it.
o INT1&INT0: - These are hardware interrupts. It calls the ISR (Interrupt
Service Routine) when the pin change occurs
o TX: - Transmit; it is used to transmit TTL serial data. Also referred to as
‘outwards’ since it transfers data from Arduino to the connected peripheral.
o RX: -Receive; it is used to receive TTL serial data. It is also referred to as
inwards since it receives data from external hardware to Arduino.
o Vin: - Voltage In; if Arduino board is powered from USB then nothing is
obtained from the Vin pin. But if the board is powered directly with an
external supply, then that supply is obtained directly from Vin pin. However,
the supply voltage obtained at the Vin pin is usually lesser by 1V than the
voltage supplied due to reverse polarity protection diode.
o 5V Pin: - it is used to power external components connected to Arduino which
needs 5V.
o 3.3V Pin: - it is used to power external components connected to Arduino that
need 3.3V.
o IORef: - Input Output Voltage Reference; it allows shields connected to
Arduino board to check whether the board is running at 3.3V or 5V
Figure 2.5.A sketch of Arduino IDE window
Every sketch needs two void types. The syntax of the Arduino IDE includes the
setup () and loop (). Void is essentially a type of function that doesn’t return any
value. Setup () is where you want to do any initialization steps while loop () is
when you want to run the code over and over again.
In Arduino there are two types of special functions. These are pinMode and
digitalWrite. pinMode takes two variables; the pin number and whether it’s an
input or output pin. digitalWrite also takes two values; the pin number and the
level whether high or low. High also means on-state and low means off-state.
An example of a Programme for Arduino is as shown below:
CHAPTER 3
Design and implementation
The system has three major parts; temperature sensing part, control section and the
output section. The room temperature was measured using DHT11 temperature
sensor. The control unit was achieved using ATMega328 microcontroller based on
Arduino platform. The output was then displayed on the LCD which was the state
of the Fan, Heater and the temperature value as read by the DHT11. Two stages of
design were undertaken; hardware and software.
3.0 Hardware Design
3.0.1 Control unit
This was achieved using Atmega 328 based or Arduino Uno platform. The
Arduino Uno was selected because it’s cheaper. It has 20 pins in total. 14 of the
20 pins are digital whereas 6 of them are analog. In the design of the automated
temperature controller system, the analog pins were used as inputs whereas the
digital pins were used as the outputs.
The selected pins were as shown below;

Table 3.1.A table showing all components connections to the control unit

Pin Connections
Digital pin 2 LCD D7 pin
Digital pin 3 LCD D6 pin
Digital pin 4 LCD D5 pin
Digital pin 5 LCD D4 pin
Digital pin 11 LCD Enable
Digital pin 12 LCD RS pin
Digital pin 1 Fan
Digital pin 6 Heater
Analog Pin A0 Connection to Temperature Sensor
VCC 5VDC
GND Ground
Sensing unit
This was achieved by DHT 11 which was mounted on the board. The pins of the
DHT11 were connected as follows.
Table 3.2.A table showing pins of the DHT 11 sensor and their connection

PIN CONNECTION
VCC 5V

DATA PIN A0

GROUND GROUND

The figure below shows the schematic diagram of DHT11 sensor connection to
control unit.

Figure 3.1.A figure showing DHT11 sensor connection to Arduino


Display unit
This was implemented using a 16*2 Liquid Crystal display. The LCD was used to
display the value of temperature as read by the DHT11 and the state of the Fan
and Heater. The connections of the LCD to the control unit were done as shown in
the schematic diagram below.

Figure 3.2. A figure showing LCD connection to the control unit


Figure 3.3.Circuit diagram of the automated room temperature controller system.
CHAPTER 4
Results and discussions
4.0 Results
The results were obtained by connecting the digital multimeter across the following
equipment.
o DHT 11
o Fan
o Heater

The output value was in Volts (V)

TEMPERATURE DHT 11 OUTPUT FAN OUTPUT HEATER OUTPUT


VOLTAGE(V) VOLTAGE(V) VOLTAGE(V)
26 4.78 0.01 4.39
27 4.79 0.02 4.39

28 4.79 4.49 0.03


29 4.79 4.49 0.03
30 4.79 4.49 0.02
31 4.79 4.49 0.02

Table 4.1A table showing output voltages


Graph
Graph 4.1.A graph of voltage (V) against Temperature (degrees Celsius)
4.1 Discussion
As shown from the graph 4.1.The DHT11 voltage is not affected by the
temperature. The output for the fan and the heater varies with temperature then
suddenly becomes constant. This makes the DHT 11 sensor most applicable in this
research project.
For temperature measuring this sensor uses a thermistor. A thermistor is a
variable resistor that changes its resistance with change of the temperature. It is
hence a contact temperature sensor. Thermistors use a semiconductor sensor that
provides a power function relationship between temperature and resistance. Their
operation is based upon an exponential relationship between electrical resistance
and temperature
CHAPTER 5
Conclusion
An automated room temperature controller system was designed successfully.
The system used Atmega 328 on Arduino microcontroller for the control unit and
DHT11 as the temperature sensor. The Fan was turned ON and heater turned OFF
when the room temperature was higher than the reference temperature and the
heater was turned ON and Fan turned OFF when the DHT11 reading was below
the threshold or reference value. The system is helpful for people who are
disabled and can be used in the industry or any environment whose temperature
is supposed to be maintained.

5.0 Recommendations
For future improvement the following recommendations are made;
o A GSM module can be integrated with the system so that one can be able to
operate their temperature control system using a digital signal such as an
SMS.
o A dial pad can also be integrated and used to key in the reference
temperature for easy changes in the threshold value without necessarily
interfacing with a computer.
o A relay circuit can be incorporated for switching purposes when an
external power supply needs to be used.
.
APPENDICES

CODE
/*
#############################################################
########### SCHOOL OF SCIENCE AND INFORMATION SCIENCES

DEPARTMENT OF MATHEMATICS AND PHYSICAL


SCIENCES BSC PHYSICS

NAME : MARTHA WANJIKU


MWANGI REG.NO:BS01/109/2015

PROJECT TITTLE: AUTOMATED ROOM TEMPERATURE CONTROLLER


OPERATION: WHEN TEMPERATURE IS LESS THAN THRESHOLD
HEATER IS TURNED ON
OTHERWISE FAN IS TURNED ON.
#############################################################
###########

*/
#include
<LiquidCrystal.h> int
DHT11=A0;
int
Heater=6;
int Fan=1;

int Threshold=27;
const int rs = 12, en = 11, d4 = 5, d5 = 4, d6 =
3, d7 = 2; LiquidCrystal lcd(rs, en, d4, d5, d6,
d7);

void setup() {
pinMode(Heater,OUTP
UT);
pinMode(DHT11,INPU
T);

pinMode(Fan,OUTP
UT); lcd.begin(16, 2);
Serial.begin(9600);

void loop() {
sensorReading=analogRead(DH
T11); if
(sensorReading<Threshold){
pinMode(Heater,HIGH);
pinMode(Fan,LOW);

Serial.println("COLD");
Serial.println(analogRead(
A0)); lcd.clear();

lcd.setCursor(0,0);
lcd.print(sensorReadin
g); lcd.setCursor(5,0);
lcd.print("HEATER
ON");
lcd.setCursor(0,2);
lcd.print("FAN OFF");

}
else
{
pinMode(Heater,LO
W);
pinMode(Fan,HIGH
);
Serial.println("HOT
");
Serial.println(analogRead(
A0)); lcd.clear();

lcd.setCursor(0,0);
lcd.print(sensorReading
); lcd.setCursor(0,1);
lcd.print("HEATER
OFF");
lcd.setCursor(0,2);
lcd.print("FAN ON");
delay(A0);

}
}
Sample screenshots
REFERENCES
 Amoo, A.L., Guda, A.H., Sambo, H.A. & Soh, T.L.G, (2014). Design and
implementation Of a room temperature control system: microcontroller-
based, in: 2014 IEEE
 Student Conference on Research and Development, Batu Ferringhi,
ccccccccccpp. 1-6.

 Arduino. (2018). Arduino - Software. https://doi.org/28/12/2008s


 Augustin, S., & Fröhlich, T. (2019).Temperature Dependence of the Dynamic
Parameters of Contact Thermometers. Sensors, 19(10), 2299. doi:
10.3390/s19102299
 Bing, H. & Wenyao, F. (2010). Design of wireless temperature monitoring
and control System based on Zigbee technology in communication room, in:
2010 International
 Conference on Internet Technology and Applications, pp. 1-3.

 Board in the World, 1(october), 4. https://doi.org/10.1007/978-1-4302-3241-4


 Cao, Y., Zhong, C. & Qiu, K. (2016). Design and experiment about
temperature control System of sealing machine based on Fuzzy PID, in:
8th IEEE International
 Conference on Intelligent Human-machine Systems and Cybernetics,
pp. 308-311.

 Chengxiang, L., Zhenhua, Y., Xu, W. & Feng, L. (2011). Design of


automatic temperature Control system on laser diode of erbium-doped fiber
source, in: Proceedings of
 The IEEE International Conference on Intelligent Computation Technology
And Automation, p. 404-407.

 Evans, B. (2011). Beginning Arduino Programming. Arduino Programming


Microcontroller
 Fu, T. Wang, X &Yang, G. (2010). Design of automatic temperature-control circuit
 Module in tunnel microwave heating system, in: Proceedings of the IEEE
International Conference on Computational and Information Sciences.
 pp. 1216-1219.

 Hedges, R.E, (1947), Automatic temperature control for transport


airplanes, IEEE Trans. Am. Inst. Electr. Eng. 66 (1) 1197-1202.

 Ian, B. (1992). Self-programmable temperature control system for a


heating and cooling System. United States of America Patent US5088645
A.

 Johnson, J.E, Maccarini,P.F.,Neuman,D. & Stauffer, P.R., (2006). Automatic


temperature controller for multi element array hyperthermia systems, IEEE
Trans. Biomed.
 Eng. 53 (6), 1006-1015.
 Levine, M.R., (2013). Automatic temperature adjusting system for air
conditioner Room. China Patent CN103335385 A.
 Li, H., Zhu & Li -Y. Bai. (2009). Temperature monitoring system based
on AT89C51 microcontroller, in: IEEE International Symposium on IT in
Medicine Education,
 ITIME, Vol. 1, pp. 316-320.

 Loup, T.O., Torres, M., Milian, F.M. & Ambrosio, P.E. (2011) Bluetooth
embedded system For room-safe temperature monitoring, Latin Am. Trans.
IEEE (Rev. IEEE
 Am. Lat.) 9 (6) 911-915.

 Ludwig,S. & Pritchard,J. (2010).10 principles of sustainable, cost-


effective design: building a safer, more efficient machine, in: Control
Engineering Magazine,
 October 2010
 Mengistie, D. (2018). Edelweiss Applied Science and Technology Providing
Water to the Plants Automatically Using Microcontroller, 2(1), 105–112.

 Minoru, N. (1996). Automatic temperature control system. United


States of America Patent US3241603 A.

 Ogu, E.C., Ogunlere, S. & Ogu, C. (2016). A control and security


system for internal Temperature breaches using the ATMEL AT89C52
microcontroller, Int. J.
 Adv. Stud. Comput. Sci. Eng. 5 (1) 1-7.

 Pengfei, L., Jiakun, L. & Junfeng, J. (2010). Wireless temperature


monitoring system Based on the Zigbee technology, in: 2010 2nd
International Conference on
 Computer Engineering and Technology (ICCET), Vol. 1, pp. 160-163.
 Pimpalgaonkar, A., Jha, M., Shukla, N., & Asthana, K., (2013). A
precision temperature Controller using embedded system, Int. J. Sci. Res.
Publ. 3 (12), pp. 1-3.

 Poll,S.B. (2006). Automatic heater controller. United States of


America Patent US4086466.

You might also like