0% found this document useful (0 votes)
15 views3 pages

Slip 14 Copy1

Uploaded by

adityaharbade
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)
15 views3 pages

Slip 14 Copy1

Uploaded by

adityaharbade
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/ 3

Assignment No. 14: Demonstration of Temperature sensor.

Aim: To demonstrate Temperature sensor application using Arduino Uno


Objectives:
1. To understand the basics of Temperature sensor LM35 working. 2.
To develop & write Temperature sensor program using Arduino Uno
platform and demonstrate it.
3. To implement your ideas and programming coding skill using

Software and hardware required:


1. Arduino IDE
2. FCT make Arduino Circuit Board
Diagram:

Temperature Sensor with LCD and Indicators (LED & Buzzer )


Procedure:
LM35 .LED & LCD Arrays

1. Connect the Arduino Uno board to the PC through USB cable.


2. Start Arduino IDE from PC and open new Sketch and the program/code
for that and save as Temp_sensor.
3. Verify/Compile the program and Upload the code into Arduino Uno.
4. Make necessary connections according diagram.
5. Observe the output running on the board.
6. Repeat the procedure for other programs to implement your ideas and
programming coding skill.

Program:

#include<LiquidCrystal.h>
//pins of the LCD. (RS, E, D4, D5, D6, D7) LiquidCrystal
lcd(6, 7, 5, 4, 3, 2);

const int sensor=A0; // Assigning analog pin A1 to variable 'sensor'

float tempc; //variable to store temperature in degree Celsius float

tempf; //variable to store temperature in Fahreinheit float vout;

//temporary variable to hold sensor reading int BUZ= 8; char sign

= 223; vout=analogRead(sensor);
lcd.print("***Tempeature***");
lcd.setCursor(0,1)
; lcd.print(tempc);
lcd.print(sign);
lcd.print("C ");
lcd.print(" ");
lcd.print((tempc*
1.8)+32);
lcd.print(sign);

lcd.print("F ");
delay(1000); //Delay of 1 second for ease of viewing in serial monitor

if (tempc > 32)


{

digitalWrite(Green_LED, HIGH):
digitalWriteRed_LED, LOW);
digitalWrite(BUZ, LOW);

}
}

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy