Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 6

DEPARTMENT OF INFORMATION TECHNOLOGY

FACULTY OF ENGINEERING AND TECHNOLOGY, UNIVERSITY OF SINDH,


JAMSHORO

SENG-621 Pervasive Computing


BS (Software Engineering) Part-IV
Lab 5
Downloading, Installing and configuring Arduino on Windows

Step 1: download Ardunio from following link


https://docs.arduino.cc/software/ide-v1 Note: select zipped package

When the download finishes, proceed with the installation and please allow the driver
installation process when you get a warning from the operating system.

Step 2: Choose all components to install.


Step 3: Choose the installation directory and Click Install
The process will extract and install all the required files to execute properly the Arduino
Software (IDE)
Step 4: In order to configure Arduino IDE for Arduino board on Windows, first connect
Arduino board with your PC using USB port (Arduino UNO in this case)

Step 5: Select properties of this PC/My computer, select device manager> Ports

Step 6: Note down COM port number Arduino is connected with (COM3 in this case).
 In case can’t find COM port Arduino is connected with open Device Manager -> select
View tab -> choose Show hidden devices.
 In case can’t find COM port Arduino is connect with, select unknown drivers> right
click it and select install drivers.
Step 7: Open Arduino IDE go to File>Example> basics>Blink file.
Step 8: Upload the sketch on board by going to Sketch menu>upload option or by pressing
Ctrl+U.
If built-in LED on Arduino starts blinking after each second, then arduino IDE is successfully
configured on your PC.
DEPARTMENT OF INFORMATION TECHNOLOGY
FACULTY OF ENGINEERING AND TECHNOLOGY, UNIVERSITY OF SINDH, JAMSHORO

SENG-621 Pervasive Computing


BS (Software Engineering) Part-IV
Lab 6
Interfacing LED and Temperature sensor (LM35) with Arduino Microcontroller
Introduction

 LM35 is a temperature measuring device having an analog output voltage proportional


to the temperature.
 It provides output voltage in Centigrade (Celsius). It does not require any external
calibration circuitry.
 The sensitivity of LM35 is 10 mV/degree Celsius. As temperature increases, output
voltage also increases.             E.g. 250 mV means 25°C.

 It is a 3-terminal sensor used to measure surrounding temperature ranging from -55 °C


to 150 °C.
 LM35 gives temperature output which is more precise than thermistor output.

LM35 Temperature Sensor

VCC: Supply Voltage (4V – 30V)


Out: It gives analog output voltage which is proportional to the temperature (in degree Celsius).
GND: Ground

Lab Objective:
Measuring the temperature of surroundings using LM35 and displaying it on the serial monitor
of Arduino.

Step 1: Configure following given circuit.


Here, LM35 output is given to analog pin A1 of Arduino UNO. This analog voltage is converted
to its digital form and processed to get the temperature reading.

 Step 2: Open New Sketch window and type following Sketch for Temperature Measurement
const int lm35_pin = A1; /* LM35 O/P pin */
void setup() {
Serial.begin(9600);
}

void loop() {
int temp_adc_val;
float temp_val;
temp_adc_val = analogRead(lm35_pin); /* Read Temperature */
temp_val = (temp_adc_val * 4.88); /* Convert adc value to equivalent voltage */
temp_val = (temp_val/10); /* LM35 gives output of 10mv/°C */
Serial.print("Temperature = ");
Serial.print(temp_val);
Serial.print(" Degree Celsius\n");
delay(1000);
}
Step 3: Connect board with PC, Upload Sketch on Arduino.
Step 4: open serial interface by going into tools> Serial Monitor or pressing Ctrl+Shift+M.

You might also like