Introduction: Room Temperature Monitoring Using Arduino and LM-35
In this project we will monitor room temperature with LM 35 temperature sensor. I use a LCD to display the temperature. Make the connections according to circuit diagram and upload the source code to the arduino board. Here i prefer Arduino Mega 2560 board. You can choose Arduino UNO or any other Arduino board for this task.
Step 1: Requirement
Hardware:-
1. Arduino Board.
2. LM-35 (Temperature Sensor).
3. 16x2 LCD.
4. Resistor (1 K ohm).
5. Breadboard.
6. Jumper Wires.
Software:-
1. Arduino IDE.Download Here.
Step 2: Circuit Diagram
Step 3: Source Code
#include
lcd(7,6,5,4,3,2);
int val;
int tempPin = 1;
void setup( ) {
pinMode(tempPin, INPUT);
lcd.begin(16, 2);
lcd.clear( );
}
void loop( ) {
val = analogRead(tempPin);
float temp = ( val*500)/1023;
float farh = (temp*9)/5 + 32;
lcd.setCursor(0, 0);
lcd.print("Temp(C)=");
lcd.print(temp);
lcd.print("*C");
lcd.setCursor(0,1);
lcd.print(" Temp(F)=");
lcd.print(farh);
lcd.print("F");
delay(1000);
}

Participated in the
Microcontroller Contest 2017
3 Comments
Question 3 years ago on Step 2
sir iss program ko ek baar daalne k baad without usb connection work krega ye mtlb battery s power de bs agr toh
Answer 2 years ago
yes, it will work on battery.
3 years ago
sir ye jo program daal rhy h iska aruino m position ko leke bhi kya programming vary krti h