KEMBAR78
ARDUINO BASED TIME AND TEMPERATURE DISPLAY | DOCX
ECE PROJECT REPORT
ARDUINO BASED TIME AND TEMPERATURE DISPLAY
SUBMITTED BY
-BHOJ KUMAR SINGH
-SEC:- E1614
-REG. NO:-11607789
ACKNOWLEDGEMENT
At the very beginning, I would like to thank all those who have helped me in making this project.
Without their support, it would have been impossible for me to make this project. At first, I
would like to thank my ECE teacher, Manie Kansal mam . Mam has been a great teacher for me
as well as my classmates. Then, I would like to thank the LPU administration for providing all
the facilities required by students.
INDEX
CONTENTS PAGE NO.
1. Introduction 1
2. Abstract 2
2.1.Working
2.2. Application
3. Components
3.1.Arduino developed board 3
3.2. LM-35 The temperature sensor 4
3.3. RTC ds1307 time sensing device 5
3.4. LCD 6
3.5. Misc(wires,potentiometer,breadboard etc) 8
4. Circuit diagram 9
4.1.Interfacing of RTC with Arduino and LCD
4.2.Interfacing of LM35 with Arduino and LCD
5. Program code 10
6. Reference 11
List Of Figures
1. Complete project of arduino based time and temperature display.
2. Arduino wth its pin conFiguration
3. Pin conFiguration of LM 35
4. LM 35
5. RTC ds 1307 Front view
6. RTC ds 1307 Back view
7. Pin descrption of RTC
8. Pin description of 16*2 LCD
9. A 16*2 LCD
10. A 10K Potentiometer
11. Jump Wires
12. Connection in Breadboard
13. Interfacing of RTC ds1307 with Arduino and LCD
14. Interfacing of LM35 with Arduino and LCD
15. Coding of the project
INTRODUCTION
This Arduino based time and temperature display project, displays time and temperature
according to the situation and surrounding. This project consists of Arduino Uno board, LM-35
the temperature sensor,RTC ds 1307 for sensing time and LCD for displaying the measured . The
LM 35 measures and displays time in Degree Celsius. RTC can work as a complete package of
clock and calendar as it can measure hour, min, sec, day, month, yearand can automatically
adjust for month having 30 or 31 days, even for leap year.
Fig 1- Complete project of arduino based time and temperature display
WORKING OF PROJECT
 The main component of this project is the Arduino developed board. It is like heart of
circuit of this whole project which control all its operation.
 An IC LM 35 is used as an temperature sensor. It is interfaced with the analog pin of
Arduino board.
 The RTC ds 1307 is used as an time measuring device. It senses current time i.e. hour,
min, second and day of the week. It is interfaced with Arduino board using 2 analog pins.
 The Arduino has an built in analog to digital convertor which converts these analog
signals to digital and displays on the LCD.
APPLICATIONS
 This type of assembly can be used to control many temperature based devices like fan,
AC’s and DC motors can also be controlled by using this.
 Arduino based auto intensity control of street light.
 Arduino can be used to make home automation system by interfacing with a Bluetooth
and a smartphone with arduino.
 Traffic signal based on microcontroller system.
 Heat sensing devices which ncan be used for safety precautions.
COMPONENTS
1. Arduino
 Arduino is an open-source project that created microcontroller-based kits for building
digital devices and interactive objects that can sense and control physical devices. It is an
open source hardware and software project, created with a simple aim in mind, to be as
simple as possible.
 It is used by artists, hackers, hobbyists, and professionals to easily design, prototype and
experiment with electronics.
 An Arduino contains a microchip, which is a very small computer that you can program.
You can attach sensors to it so that it can measure conditions (like how much light there
is in the room). It can control how other objects react to those conditions (room gets dark.
LED turns on).
 Microcontrollers use inputs and outputs like any computer. It provide sets of digital and
analog input/output (I/O) pins that can interface to various expansion boards and other
circuits.
 For programming the microcontrollers, the Arduino project provides an integerated
development environment (IDE) based on a programming language named Processing
which also supports the languages C and C++.
Fig 2- Arduino wth its pin conFiguration
2. LM 35 The Temperature Sensor
 LM35 is a precision IC temperature sensor with its output voltage proportional to the
temperature (in oC).
 The LM35 does not require any external calibration or trimming to provide typical
accuracies of ±1⁄4˚C at room temperature and ±3⁄4˚C over a full −55 to +150˚C
temperature range.
 The LM35’s low output impedance, linear output, and precise inherent calibration make
interfacing to readout or control circuitry especially easy.
 As it draws only 60 µA from its supply, it has very low self-heating, less than 0.1˚C in
still air.
 The LM35 is rated to operate over a −55˚ to +150˚C temperature range.
 The sensor circuitry is sealed and therefore it is not subjected to oxidation and other
processes. With LM35, temperature can be measured more accurately than with a
thermistor.
 It has got 3 pins Ground, Output, and Vcc.The Output pin is connected to analog pin of
Arduino and Vcc is given 5V.
Fig 3- Pin conFiguration of LM 35
Fig 4-LM 35
3. RTC ds1307
 RTC is an 8 pin device using an I2C interface.
 The DS1307 is a low-power clock/calendar with 56 bytes of battery backup SRAM.
 The clock/calendar provides seconds, minutes, hours, day, date, month, and year
information.
 The end of the month date is automatically adjusted for months with fewer than 31 days,
including corrections for leap year. The clock operates in either the 24-hour or 12- hour
format with AM/PM indicator.
 The DS1307 has a built-in power-sense circuit that detects power failures and
automatically switches to the backup supply.
 RTC has different pins but we only need 4 pins SDA, SCL, GND and Vcc for our this
project.
 SDA & SCL pins of RTC are given to A4 and A5 analog pin of Arduino respectively.
Fig 5- RTC ds 1307( Front ) Fig 6-RTC ds 1307( Back)
Fig 7-Pin descrption of RTC
4. Liquid Crystal Display
 LCD (Liquid Crystal Display) screen is an electronic display module and find a wide
range of applications
 They come in many sizes 8x1 , 8x2 , 10x2 , 16x1 , 16x2 , 16x4 , 20x2 , 20x4 ,24x2 , 30x2
, 32x2 , 40x2 etc . First digit shows number of columns and second digit show number of
rows.
 In this project we have used a 16*2. This means 16 characters per line by 2 lines and 20
characters per line by 2 lines, respectively.
 Their programming is also same and they all have same 14 pins (0-13) or 16 pins (0 to
15). ALL LCDs have
i. Eight(8) Data pins
ii. VCC (Apply 5v here)
iii. GND (Ground this pin)
iv. RS (Register select)
v. RW (read - write)
vi. EN (Enable)
vii. V0 (Set Lcd contrast)
 8-Data pins carries 8-bit data or command from an external unit such as microcontroller.
 There are three important pins in LCD RS,RW,EN.
RS(Register select)
There are two registers in every LCD
i. Command register
When we send commands to lcd these commands go to Command register and
are processed their..
- When RS=0 Command Register is Selected.
ii. Data Register
When we send Data to lcd it goes to data register and is processed their.
- When RS=1 Data Register is selected.
RW(Read - Write)
1. When RW=1 We want to read data from lcd.
2. When RW=0 We want to write to lcd.
EN(Enable signal)
1. When you select the register(Command and Data) and set RW(read - write) now its time to
execute the instruction.
2.This requires an extra voltage push to execute the instruction and EN(enable) signal is used
for this purpose. Usually we make it en=0 and when we want to exectue the instruction we make
it high en=1 for some milli seconds. After this we again make it ground en=0.
Fig 8- Pin description of 16*2 LCD
Fig 9- A 16*2 LCD
5. OTHER COMPONENTS
Potentiometer
 A potentiometer, informally a pot, is a three-terminal resistor with a sliding or rotating contact
that forms an adjustable voltage divider.
 If only two terminals are used, one end and the wiper, it acts as a variable
resistor or rheostat.
 In this project , a10K potentiometer is used.
 In this project pin connection of pot are done as:-
1. GND—connected to ground from Arduino.
2. OUTPUT—connected to 3rd pin of LCD.
3. INPUT—input of 5V is given from Arduino.
FI G
Fig 10-A 10K Potentiometer Fig 11- Jump Wires
Breadboard
 A breadboard is a construction base for prototyping of electronics.
 Breadboard does not require soldering, it is reusable. This makes it easy to use for creating
temporary prototypes and experimenting with circuit design.
Fig 12-Connection in Breadboard
Jump Wires
 A jump wire is an electrical wire or group of them in a cable with a connector or pin at
each end Individual jump wires are fitted by inserting their "end connectors" into the slots
provided in a breadboard, the header connector of a circuit board.
CIRCUIT AND CONNECTION
Fig 13-Interfacing of RTC ds1307 with Arduino and LCD
Fig 14-Interfacing of LM35 with Arduino and LCD
PROGRAM
Using this program we can display time and temperature
Fig 15-Coding of the project
RESULT
In this whole project I have shown how effectively Arduino can be used with different
components to create something good. In this project I have interfaced Arduino with LM35 and
RTC ds1307 to display time and temperature of the surroundings on a 16*2 LCD.
REFERENCE
 First I would thank my ECE teacher Miss Manie Kansal for her proper guidance.
 https://m.youtube.com/watch?v=NDwSrgfsiYQ
 http://www.alldatasheet.com/
 http://www.engineersgarage.com/
 All the Lovely faculty of Lovely Professional University
ARDUINO BASED TIME AND TEMPERATURE DISPLAY

ARDUINO BASED TIME AND TEMPERATURE DISPLAY

  • 1.
    ECE PROJECT REPORT ARDUINOBASED TIME AND TEMPERATURE DISPLAY SUBMITTED BY -BHOJ KUMAR SINGH -SEC:- E1614 -REG. NO:-11607789
  • 2.
    ACKNOWLEDGEMENT At the verybeginning, I would like to thank all those who have helped me in making this project. Without their support, it would have been impossible for me to make this project. At first, I would like to thank my ECE teacher, Manie Kansal mam . Mam has been a great teacher for me as well as my classmates. Then, I would like to thank the LPU administration for providing all the facilities required by students.
  • 3.
    INDEX CONTENTS PAGE NO. 1.Introduction 1 2. Abstract 2 2.1.Working 2.2. Application 3. Components 3.1.Arduino developed board 3 3.2. LM-35 The temperature sensor 4 3.3. RTC ds1307 time sensing device 5 3.4. LCD 6 3.5. Misc(wires,potentiometer,breadboard etc) 8 4. Circuit diagram 9 4.1.Interfacing of RTC with Arduino and LCD 4.2.Interfacing of LM35 with Arduino and LCD 5. Program code 10 6. Reference 11
  • 4.
    List Of Figures 1.Complete project of arduino based time and temperature display. 2. Arduino wth its pin conFiguration 3. Pin conFiguration of LM 35 4. LM 35 5. RTC ds 1307 Front view 6. RTC ds 1307 Back view 7. Pin descrption of RTC 8. Pin description of 16*2 LCD 9. A 16*2 LCD 10. A 10K Potentiometer 11. Jump Wires 12. Connection in Breadboard 13. Interfacing of RTC ds1307 with Arduino and LCD 14. Interfacing of LM35 with Arduino and LCD 15. Coding of the project
  • 5.
    INTRODUCTION This Arduino basedtime and temperature display project, displays time and temperature according to the situation and surrounding. This project consists of Arduino Uno board, LM-35 the temperature sensor,RTC ds 1307 for sensing time and LCD for displaying the measured . The LM 35 measures and displays time in Degree Celsius. RTC can work as a complete package of clock and calendar as it can measure hour, min, sec, day, month, yearand can automatically adjust for month having 30 or 31 days, even for leap year. Fig 1- Complete project of arduino based time and temperature display
  • 6.
    WORKING OF PROJECT The main component of this project is the Arduino developed board. It is like heart of circuit of this whole project which control all its operation.  An IC LM 35 is used as an temperature sensor. It is interfaced with the analog pin of Arduino board.  The RTC ds 1307 is used as an time measuring device. It senses current time i.e. hour, min, second and day of the week. It is interfaced with Arduino board using 2 analog pins.  The Arduino has an built in analog to digital convertor which converts these analog signals to digital and displays on the LCD. APPLICATIONS  This type of assembly can be used to control many temperature based devices like fan, AC’s and DC motors can also be controlled by using this.  Arduino based auto intensity control of street light.  Arduino can be used to make home automation system by interfacing with a Bluetooth and a smartphone with arduino.  Traffic signal based on microcontroller system.  Heat sensing devices which ncan be used for safety precautions.
  • 7.
    COMPONENTS 1. Arduino  Arduinois an open-source project that created microcontroller-based kits for building digital devices and interactive objects that can sense and control physical devices. It is an open source hardware and software project, created with a simple aim in mind, to be as simple as possible.  It is used by artists, hackers, hobbyists, and professionals to easily design, prototype and experiment with electronics.  An Arduino contains a microchip, which is a very small computer that you can program. You can attach sensors to it so that it can measure conditions (like how much light there is in the room). It can control how other objects react to those conditions (room gets dark. LED turns on).  Microcontrollers use inputs and outputs like any computer. It provide sets of digital and analog input/output (I/O) pins that can interface to various expansion boards and other circuits.  For programming the microcontrollers, the Arduino project provides an integerated development environment (IDE) based on a programming language named Processing which also supports the languages C and C++. Fig 2- Arduino wth its pin conFiguration
  • 8.
    2. LM 35The Temperature Sensor  LM35 is a precision IC temperature sensor with its output voltage proportional to the temperature (in oC).  The LM35 does not require any external calibration or trimming to provide typical accuracies of ±1⁄4˚C at room temperature and ±3⁄4˚C over a full −55 to +150˚C temperature range.  The LM35’s low output impedance, linear output, and precise inherent calibration make interfacing to readout or control circuitry especially easy.  As it draws only 60 µA from its supply, it has very low self-heating, less than 0.1˚C in still air.  The LM35 is rated to operate over a −55˚ to +150˚C temperature range.  The sensor circuitry is sealed and therefore it is not subjected to oxidation and other processes. With LM35, temperature can be measured more accurately than with a thermistor.  It has got 3 pins Ground, Output, and Vcc.The Output pin is connected to analog pin of Arduino and Vcc is given 5V. Fig 3- Pin conFiguration of LM 35 Fig 4-LM 35
  • 9.
    3. RTC ds1307 RTC is an 8 pin device using an I2C interface.  The DS1307 is a low-power clock/calendar with 56 bytes of battery backup SRAM.  The clock/calendar provides seconds, minutes, hours, day, date, month, and year information.  The end of the month date is automatically adjusted for months with fewer than 31 days, including corrections for leap year. The clock operates in either the 24-hour or 12- hour format with AM/PM indicator.  The DS1307 has a built-in power-sense circuit that detects power failures and automatically switches to the backup supply.  RTC has different pins but we only need 4 pins SDA, SCL, GND and Vcc for our this project.  SDA & SCL pins of RTC are given to A4 and A5 analog pin of Arduino respectively. Fig 5- RTC ds 1307( Front ) Fig 6-RTC ds 1307( Back) Fig 7-Pin descrption of RTC
  • 10.
    4. Liquid CrystalDisplay  LCD (Liquid Crystal Display) screen is an electronic display module and find a wide range of applications  They come in many sizes 8x1 , 8x2 , 10x2 , 16x1 , 16x2 , 16x4 , 20x2 , 20x4 ,24x2 , 30x2 , 32x2 , 40x2 etc . First digit shows number of columns and second digit show number of rows.  In this project we have used a 16*2. This means 16 characters per line by 2 lines and 20 characters per line by 2 lines, respectively.  Their programming is also same and they all have same 14 pins (0-13) or 16 pins (0 to 15). ALL LCDs have i. Eight(8) Data pins ii. VCC (Apply 5v here) iii. GND (Ground this pin) iv. RS (Register select) v. RW (read - write) vi. EN (Enable) vii. V0 (Set Lcd contrast)  8-Data pins carries 8-bit data or command from an external unit such as microcontroller.  There are three important pins in LCD RS,RW,EN. RS(Register select) There are two registers in every LCD i. Command register When we send commands to lcd these commands go to Command register and are processed their.. - When RS=0 Command Register is Selected. ii. Data Register When we send Data to lcd it goes to data register and is processed their. - When RS=1 Data Register is selected. RW(Read - Write) 1. When RW=1 We want to read data from lcd. 2. When RW=0 We want to write to lcd.
  • 11.
    EN(Enable signal) 1. Whenyou select the register(Command and Data) and set RW(read - write) now its time to execute the instruction. 2.This requires an extra voltage push to execute the instruction and EN(enable) signal is used for this purpose. Usually we make it en=0 and when we want to exectue the instruction we make it high en=1 for some milli seconds. After this we again make it ground en=0. Fig 8- Pin description of 16*2 LCD Fig 9- A 16*2 LCD
  • 12.
    5. OTHER COMPONENTS Potentiometer A potentiometer, informally a pot, is a three-terminal resistor with a sliding or rotating contact that forms an adjustable voltage divider.  If only two terminals are used, one end and the wiper, it acts as a variable resistor or rheostat.  In this project , a10K potentiometer is used.  In this project pin connection of pot are done as:- 1. GND—connected to ground from Arduino. 2. OUTPUT—connected to 3rd pin of LCD. 3. INPUT—input of 5V is given from Arduino. FI G Fig 10-A 10K Potentiometer Fig 11- Jump Wires Breadboard  A breadboard is a construction base for prototyping of electronics.  Breadboard does not require soldering, it is reusable. This makes it easy to use for creating temporary prototypes and experimenting with circuit design. Fig 12-Connection in Breadboard Jump Wires  A jump wire is an electrical wire or group of them in a cable with a connector or pin at each end Individual jump wires are fitted by inserting their "end connectors" into the slots provided in a breadboard, the header connector of a circuit board.
  • 13.
    CIRCUIT AND CONNECTION Fig13-Interfacing of RTC ds1307 with Arduino and LCD Fig 14-Interfacing of LM35 with Arduino and LCD
  • 14.
    PROGRAM Using this programwe can display time and temperature Fig 15-Coding of the project
  • 15.
    RESULT In this wholeproject I have shown how effectively Arduino can be used with different components to create something good. In this project I have interfaced Arduino with LM35 and RTC ds1307 to display time and temperature of the surroundings on a 16*2 LCD. REFERENCE  First I would thank my ECE teacher Miss Manie Kansal for her proper guidance.  https://m.youtube.com/watch?v=NDwSrgfsiYQ  http://www.alldatasheet.com/  http://www.engineersgarage.com/  All the Lovely faculty of Lovely Professional University