Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
14 views7 pages

Lab 7

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views7 pages

Lab 7

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 7

Department of Electrical & Electronic Engineering

Rajshahi University of Engineering & Technology


LAB Report
Course Code : Electrical Shop Practice

Course Title : EEE 3100

Experiment No. : 07

Experiment Name : Implementation of Bluetooth and Voice-Controlled Home


Automation System using HC-05 and Arduino.

Submitted By: Submitted To:

Name : Al-Momin Hosen Asif Zaman Rizve

Roll : 2101102 Lecturer

Section : B Department of Electrical & Electronic


Engineering
Rajshahi University of Engineering &
Technology

Date of Experiment : 20 May, 2025

Date of Submission : 27 May, 2025


Experiment No.: 07

Experiment Name: Implementation of Bluetooth and Voice-Controlled Home Automation


System using HC-05 and Arduino.

Theory: The HC-05 Bluetooth module typically operates within a range of about 33 feet,
although factors like obstacles and electromagnetic interference can reduce this distance. It uses
a serial communication interface compatible with UART, allowing for reliable data
transmission and reception. The module's settings, including device name, operating mode, and
communication parameters, can be configured using AT commands. It functions on a DC
voltage between 3.6V and 6V and features an integrated antenna, enhancing the efficiency and
stability of its wireless communication.

Fig.7.1: HC-05 module

Fig.7.2: 2-channel relay module

A relay is an electrically controlled switch used to manage devices and systems operating at
higher voltages. In relay modules, the switching mechanism is typically driven by an
electromagnet. The main function of the relay module is to switch electrical devices and
systems on and off. It also offers isolation between the low-voltage control circuit and the high-
voltage system, improving safety and reliability during operation.
Interfacing the HC-05 Bluetooth module with an Arduino Uno R3 enables wireless control of
home automation devices through Bluetooth communication. The HC-05 can function in either
master or slave mode and pairs with smartphones or other Bluetooth-enabled devices. It
communicates with the Arduino via serial communication using the TX and RX pins. In a home
automation system, the Arduino receives commands from the connected Bluetooth device
through the HC-05, processes the data, and controls appliances such as lights, fans, or security
systems. This setup provides a simple, cost-effective solution for building a smartphone-
controlled wireless home automation system.

Required Apparatus:

Table 7.1: Table for Required Apparatus

Sl. No. Components Specification Quantity


1 Arduino UNO ATmega328P Microcontroller 1
2 HC-05 Bluetooth Module UART 3.3V TTL Logic 1
3 Relay Module 5V, Single Channel 1
4 Light Bulb 230V, AC 1
5 Smartphone Android (Bluetooth capable) 1
6 Jumper Wires Male-to-Male/Male-to-Female As required
7 Power Supply 5V USB or Adapter 1

Circuit Diagram:

Fig.7.3: Switching light bulb using HC-05 through voice command


Experimental Setup :

Fig 7.4: Hardware Implementation of Switching light using HC-05

Aurdino Code:

char val;
void setup() {
pinMode(13,
OUTPUT);
Serial.begin(9600);
digitalWrite(13, HIGH);
}
void loop() {
if (Serial.available()) {
val = Serial.read();
Serial.println(val);
}
if (val == '1')
{ digitalWrite(13,
LOW);
}
else if (val == '2')
{ digitalWrite(13,
HIGH);
}
Experimental procedure:

1. Connect HC-05 to Arduino (TX to RX, RX to TX, VCC to 5V, GND to GND).
2. Connect a relay module to digital pin 8 of Arduino to control the light.
3. Upload the code to Arduino using Arduino IDE.
4. Pair your smartphone with the HC-05 module via Bluetooth.
5. Use a Bluetooth terminal app or voice assistant to send commands (‘1’ to turn ON, ‘0’
to turn OFF).
6. Observe how the light responds to Bluetooth or voice commands

Hands-on Learning Projects for Mastery of Home Automation using Arduino and HC-05
Bluetooth Module

Task No.: 01
Task Name: Dual Mode Control System for Light Automation (Manual and Auto Switching)

Objective:
 To design and implement a control system that switches between manual and automatic
modes for light automation. In manual mode, the light bulb is controlled directly via
Bluetooth commands ('1' for ON, '0' for OFF). In automatic mode, a timer or sensor-
based logic automatically controls the light's state, ensuring dynamic operation.

Code :
int mode = 0; // 0 for manual, 1 for
auto char command;
void setup() {
Serial.begin(9600);
pinMode(8, OUTPUT);
}

void loop() {
if (Serial.available())
{ command =
Serial.read();
if (command == 'a') mode = 1;
else if (command == 'm') mode = 0;
else if (mode == 0 && command == '1') digitalWrite(8,
HIGH); else if (mode == 0 && command == '0')
digitalWrite(8, LOW);
}
if (mode == 1) {
// Example: Blink light
automatically digitalWrite(8, HIGH);
delay(1000);
digitalWrite(8, LOW);
delay(1000);
}
Task No.: 02
Task Name: Voice-Activated Smart Home Control using Mobile Assistant and Bluetooth
Communication

Objective:

 To develop a smart home control system that uses mobile assistant voice commands
(e.g., Google Assistant) to control a relay module via the HC-05 Bluetooth module.
The system interprets the voice commands through Arduino to control a light bulb or
motor in an automatic or manual fashion based on the user's spoken input.

Code:

char voice;
void setup()
{
Serial.begin(9600);
pinMode(8, OUTPUT);
}

void loop() {
if (Serial.available())
{ voice = Serial.read();
if (voice == '1') digitalWrite(8, HIGH); // Voice says "turn on
light" else if (voice == '0') digitalWrite(8, LOW); // Voice
says"turn offlight"
}
}

Results:

Experimental Result:

The experiment was checked through serial monitor .When the value 1 is given to the serial
monitor then the light bulb was ON and When the value 2 is given to the serial monitor then the
light bulb was OFF

Discussions:

The system worked in both manual and automatic modes. Bluetooth communication through
HC- 05 was reliable, and voice commands sent from the mobile assistant were done
correctly.The system maintained stable control over the relay. . In manual mode, the light bulb
is controlled directly via Bluetooth commands ('1' for ON, '0' for OFF). In automatic mode, a
timer or sensor- based logic automatically controls the light's state, ensuring dynamic operation.
By this experiment Real-time monitoring was achieved successfully.
Justification of CO2 and PO(j):
The dual-mode system ensures both manual and automated control, supporting energy-efficient
and safe operation of appliances. I was able to communicate the setup and results effectively,
showing practical understanding of Arduino-based embedded systems in smart automation
applications.

Conclusion:

This experiment successfully showed the implementation of a home automation system using
Bluetooth and voice commands. By interfacing Arduino and HC-05 with simple code and
control logic, real-time wireless control of devices was achieved. The system is helpful and
reliable for more devices and advanced control in future smart home projects.

You might also like