Arduino Lab Manual - Expt5
Arduino Lab Manual - Expt5
LAB MANUAL
(2023 – 2024)
BEEL456D
ARDUINO AND RASPBERRY
PI BASED PROJECT
IV Semester
E&E Engineering
Name: _____________________________________________
U S N: _____________________________________________
1
Arduino & Raspberry PI Based Project – BEEL456D
Aim:
To interface Bluetooth with Arduino and write a program to send sensor data to Smartphone
using Bluetooth.
Apparatus Required:
Theory:
Arduino:
Arduino is an open-source, board that has a Microchip ATmega328P microcontroller on it.
This microcontroller has a set of Digital & Analog input and output pins. The operating voltage
of the board is 5V. It has 14 digital I/O pins & 6 Analog input pins. The clock frequency of the
microcontroller is 16 MHz’s
Bluetooth Module HC – 05:
HC-05 is a Bluetooth module which is designed for wireless communication. This module can
be used in a master or slave configuration.
Bluetooth serial modules allow all serial enabled devices to communicate with each other
using Bluetooth.
It has 6 pins,
2
Arduino & Raspberry PI Based Project – BEEL456D
4. TXD: Transmit Serial data (wirelessly received data by Bluetooth module transmitted out
serially on TXD pin)
5. RXD: Receive data serially (received data will be transmitted wirelessly by Bluetooth
module).
The DHT11 is a basic, low cost digital temperature and humidity sensor.
DHT11 is a single wire digital humidity and temperature sensor, which provides
humidity and temperature values serially with one-wire protocol.
DHT11 sensor provides relative humidity value in percentage (20 to 90% RH) and
temperature values in degree Celsius (0 to 50 °C).
DHT11 sensor uses resistive humidity measurement component, and NTC
temperature measurement component.
Block Diagram:
Sensor Arduino
DHT11 Bluetooth Smart Phone
Hardware Connections:
3
Arduino & Raspberry PI Based Project – BEEL456D
Program:
#include <dht.h>
#define dhtpin A0
dht DHT;
void setup() {
Serial.begin(9600);
}
void loop() {
delay(2000);
DHT.read11(dhtpin);
Serial.println("Humidity:");
Serial.print(DHT.humidity);
Serial.println("Temperature:");
Serial.print(DHT.temperature);
delay(2000);
}
Conclusion: