Home Safety Report (Final)

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

A

PROJECT REPORT
On

“HOME SAFETY SYSTEM USING IoT”


Submitted in partial fulfilment of
the requirements for the award of the Degree of
BACHELOR OF SCIENCE
IN
Electronics and Telecommunication

by
Mr. SOUMYAPRADA RATH (Roll. No :202153044)

Mr. AYUSH BHANJA (Roll No: 202153008)

Mr. SHREEMAN ANIRUDHA SENAPATI (Roll No: 202153034)

Under the esteemed guidance of


Mr. Deepak ku. Mohapatra Mr. Umakanta Samantasinghara

(External Guide) (Internal Guide)

DEPARTMENT OF ELECTRONICS AND TELECOMMUNICATION

BJB AUTONOMOUS COLLEGE

BHUBANESWAR.

2023-24

1
CERTIFICATE

This is to certify that Mr./ Miss SOUMYAPRADA RATH, AYUSH BHANJA,


SHREEMAN ANIRUDHA SENAPATI bearing Roll Nos 202153044,
202153008, 202153034 are the students of IMSc.ETC of BJB Autonomous
College, Bhubaneswar have undergone a project work on HOME SAFETY
SYSTEM USING IoT, at N-TECHNOLOGY from JANUARY 20 to MARCH
25 under my supervision & guidance.

Certified that to the best of my knowledge, this work done here is very
correct and accurate. During this period they have shown knee interest, dedication
and hard work for the development of this project

I wish all success in their future endeavour.

Signature of the Guide with seal

Name:

Designation:

Dept. of Electronics and Telecommunication

BJB (Autonomous) college

Bhubaneswar

2
BONAFIED CERTIFICATE

This is to certify that Mr./ Miss SOUMYAPRADA RATH, AYUSH BHANJA,


SHREEMAN ANIRUDHA SENAPATI bearing Roll Nos 202153044,
202153008, 202153034 are the students of IMSc.ETC of BJB Autonomous
College, Bhubaneswar have undergone a project work on HOME SAFETY
SYSTEM USING IoT, at N-TECHNOLOGY from JANUARY 20 to MARCH
25 under our supervision & guidance.

Certified that to the best of our knowledge this work done here is
very correct and accurate. During this period they have shown keen interest,
dedication and hard work for the development of this project

We wish all success in their future endeavour.

Sign. of External Sign. Of HOD

Examiner Dept. Of IMSc(ETC)

ACKNOWLEDGEMENT

No project is the outcome of the individual effort. Right from its inception to the
completion of the project, we are benefited by the suggestions and valuable inputs
from many people. Without their help, we would not have been able to complete
this project. So, we seize this opportunity to thank all of them who have helped us
to complete this project.

We would like to express our deep sense of gratitude to our external guide
Mr./Miss DEEPAK KU. MOHAPATRA his/her inspiring guidance and
cooperation for the successful completion of the project.

3
We would also like to express our hearty thanks to our
internal project guide Mr./Miss. UMAKANTA SAMANTASINGHAR who has
provided continuous guidance and suggestions to undertake and complete the
project work in his esteemed organization.

We are also very much thankful to the Head of the Department and other
faculty members, for their support and cooperation to the successful completion of
the project.

Signature of the Student(s)

DECLARATION

We do hereby declare that this project report on “HOME SAFETY SYSTEM


USING IoT” is original and the result of our own work.

This project has not been published elsewhere or submitted to any


other college/University or institute for the award of any degree or diploma. This is
being submitted for the partial fulfilment of my Bachelor of Science in Electronic
and Telecommunication degree.

Signature

Place: BJB (AUTONOMOUS) COLLEGE

Date: 13/04/2024

4
CONTENT

SL NO. TOPICS PAGE NO.

1. Cover page i

2 Certificate from Industry/Organization ii

3. Certificate from Department iii

4. Acknowledgement iv

5. Declaration v

6. Content vi

7 Abstract 1

8 Introduction 2

9 Project Overview & Methodology 3

10 Hardware/Software requirements

11 Component Study and review

12 Dataflow diagram/Block Diagrams

13 Circuit Analysis & Design

14 Coding & Testing

15 Output snapshots & Result Discussion

5
16 Advantages & Limitations

17 Conclusion & Future Scope

18 References

ABSTRACT

IOT or internet of things is an upcoming technology that allows us to control hardware devices
through the internet. Here we propose to use IOT in order to control home appliances, thus
automating modern homes through the internet. This system uses two loads to demonstrate as house
lighting and a fan. Our user-friendly interface allows a user to easily control these home appliances
through the internet. For this system we use a NODE MCU microcontroller. This microcontroller is
inbuilt with a esp8266 wifi module to get user commands over the internet. Relays are used to
switch loads. Here two sensor that is flame sensor and gas sensor is used to continue measure the fire
and poisonous gas. If room gas level or detects fire in the home it activates the buzzer and send
notification to the IOT terminal. The entire system is powered by a 12 V transformer. After receiving
user commands over the internet, microcontroller processes these instructions to operate these loads
accordingly and. Thus, this system allows for efficient home automation over the internet.

With the rapid advancement of technology, the concept of the Internet of Things (IoT) has
gained significant attention, particularly in the domain of home safety and security. This abstract
presents an innovative IoT-based home safety system integrated with fire and gas sensors aimed at
enhancing residential safety measures. The proposed system employs a network of interconnected
sensors and actuators to monitor and respond to potential fire and gas leakage incidents promptly.
The core components of the system include fire and gas sensors strategically positioned within the
household premises. These sensors continuously monitor environmental parameters such as
temperature, smoke density, and gas concentrations. In the event of any abnormality detected by the
sensors, real-time alerts are generated, triggering immediate actions to mitigate the potential risks.

The IoT-based architecture of the system enables seamless communication between the
sensors, actuators, and a central control unit. Utilizing wireless communication protocols such as Wi-
Fi or Bluetooth, the sensors relay data to the control unit, which analyses the information and
initiates appropriate responses. Additionally, the system can be accessed remotely via smartphone
applications or web interfaces, providing homeowners with real-time monitoring and control
capabilities from anywhere. Upon detecting a fire outbreak, the system activates various safety
measures autonomously. This may include triggering alarms to alert occupants, activating sprinkler
systems to suppress the fire, and communicating with emergency services for swift intervention.

6
Similarly, in the case of gas leaks, the system can automatically shut off the gas supply and ventilate
the affected area to prevent the escalation of hazards.

INTRODUCTION

In an era characterized by rapid technological advancements and increasing


concerns regarding home safety, the integration of Internet of Things (IoT)
technologies has emerged as a promising solution. The fusion of IoT with
traditional safety systems has paved the way for innovative approaches to mitigate
risks and enhance protection within residential environments. This report delves
into the development and implementation of an IoT-based home safety system,
specifically focusing on the utilization of fire and gas sensors. The primary
objective of this system is to proactively detect and respond to potential fire and
gas leakage incidents, thereby safeguarding lives and property.

The integration of fire and gas sensors within the IoT framework enables
real-time monitoring and remote management capabilities, empowering
homeowners with greater control and visibility over their safety environment.
Leveraging the connectivity and data processing capabilities of IoT devices, the
system enhances situational awareness and facilitates timely interventions in the
event of emergencies. Furthermore, the report explores the technical specifications,
design considerations, and operational functionalities of the IoT-based home safety
system. It examines the underlying architecture, sensor deployment strategies,
communication protocols, and alarm mechanisms essential for effective hazard
detection and response. Through a comprehensive analysis of case studies,
experimental results, and user feedback, this report aims to evaluate the efficacy,
reliability, and practicality of the proposed IoT-based home safety system. By
highlighting its strengths, limitations, and potential areas for improvement, it seeks
to provide valuable insights for researchers, developers, and stakeholders interested
in enhancing residential safety through IoT technologies. In recent years, the
integration of smart technologies into our homes has revolutionized the way we
interact with our living spaces. Among these advancements, the concept of the
Internet of Things (IoT) has emerged as a transformative force, offering
unprecedented levels of connectivity and automation. One of the most critical

7
applications of IoT in the realm of home automation is the implementation of home
safety systems. These systems utilize interconnected sensors, actuators, and
intelligent algorithms to monitor, analyse, and respond to potential safety hazards
in real-time. The traditional approach to home safety relied heavily on passive
measures such as smoke detectors and carbon monoxide alarms, which provided
limited functionality and required manual intervention in case of emergencies.
However, with the advent of IoT technologies, the landscape of home safety has
undergone a profound evolution. IoT-based home safety systems offer a holistic
approach to safeguarding residential properties, incorporating a diverse array of
sensors and smart devices to detect and mitigate various threats effectively.

Central to the functionality of IoT-based home safety systems are sensors capable
of detecting a wide range of environmental parameters. These sensors can monitor
factors such as temperature, humidity, smoke, gas concentrations, and even motion,
providing comprehensive coverage of potential safety risks. By continuously
analysing the data collected from these sensors, the system can identify anomalies
and trigger appropriate responses to address emerging threats promptly. Moreover,
the connectivity enabled by IoT technologies allows for seamless communication
between the various components of the home safety system. Wireless protocols
such as Wi-Fi, Bluetooth, and Zigbee facilitate the exchange of information
between sensors, actuators, and a centralized control unit. This interconnectedness
not only enables real-time monitoring but also allows homeowners to remotely
access and manage their safety systems through smartphones, tablets, or web
interfaces. The incorporation of automation and intelligent algorithms further
enhances the capabilities of IoT-based home safety systems. Machine learning
algorithms can analyse historical data to identify patterns and anomalies, enabling
the system to anticipate potential hazards and take proactive measures to prevent
accidents. Additionally, the system can automate responses to detected threats,
such as activating alarms, shutting off utilities, or even contacting emergency
services autonomously.

In summary, IoT-based home safety systems represent a significant


advancement in residential safety management. By leveraging the power of IoT
technologies, these systems offer unparalleled levels of monitoring, control, and
automation, thereby enhancing the overall safety and security of our homes. As the
IoT ecosystem continues to evolve, the potential for further innovations in home
safety systems remains vast, promising safer and more resilient living environments
for homeowners worldwide.

8
PROJECT OVERVIEW & METHODOLOGY

Overview:
The project aims to develop an IoT-based home security system with integrated fire and gas sensors.
The system will provide real-time monitoring and alerts for detecting fire or high gas levels in the
home environment. Additionally, it will include control mechanisms such as activating a buzzer
alarm and triggering relays to turn on/off devices like fans and lights.

Methodology
Requirement Analysis

 Identify the key requirements of the home security system, including sensor types,
communication protocols, and user interface preferences.
 Define the functionalities such as sensor data processing, alarm triggering, and remote
monitoring.

System Design

 Design the system architecture, including hardware and software components.


 Select appropriate sensors (fire sensor, gas sensor), microcontroller, Wi-Fi module, and other
peripherals.
 Determine the communication protocols for sensor data transmission and integration with the
Blynk cloud platform.

Hardware Implementation:

9
 Assemble the hardware components based on the system design.
 Connect the sensors to the microcontroller, ensuring proper wiring and signal integrity.
 Integrate additional hardware such as buzzer and relays for alarm and control functionalities.

Software Development

 Develop firmware for the microcontroller to handle sensor data acquisition, processing,
and communication.
 Implement algorithms for detecting fire/smoke levels and gas concentrations based on
sensor readings.
 Integrate the Blynk library for IoT connectivity and create a user interface for remote
monitoring/control.

Testing and Validation:

 Conduct comprehensive testing of the system to verify its functionality and reliability.
 Test sensor accuracy, alarm triggering mechanisms, and remote monitoring features.
 Validate the system's response under different scenarios, including fire/smoke detection
and gas level variations.

Documentation and Report in

 Document the entire development process, including hardware schematics, software code,
and test results.
 Prepare a project report outlining the project overview, methodology, implementation
details, and test findings.
 Provide recommendations for future improvements and enhancements to the system.

10
HARDWARE/SOFTWARE REQUIREMENTS

Hardware Requirements:
1. Microcontroller: ESP32.

3. Fire Sensor: Smoke detector or flame sensor.

4. Gas Sensor: MQ series gas sensor for detecting harmful gases like carbon monoxide (CO).

5. Buzzer: Audible alarm for alerting occupants in case of fire or high gas levels.

6. Relays: Electromechanical relays for controlling devices such as fans and lights.

7. Power Supply: Suitable power source to power the microcontroller and peripherals.

8. Breadboard/Jumper Wires: For prototyping and connecting components.

9. Enclosure: Housing to protect the circuitry and components.

Software Requirements:
1. Arduino IDE: Integrated Development Environment for programming the microcontroller.

2. Blynk Library: Library for interfacing Arduino with the Blynk cloud platform.

3. Libraries for Sensors: Install libraries required for interfacing with fire and gas sensors.

11
4. Blynk Mobile App: For monitoring and controlling the security system remotely via a smartphone
or tablet.

5. Text Editor: Optionally, a text editor for documenting code and project details.

6. Internet Connection: Required for connecting the Wi-Fi module to the Blynk cloud platform.

COMPONENT STUDY AND REVIEW:

 Wi-Fi Module (ESP8266 or ESP32):

 ESP8266 and ESP32 are popular Wi-Fi modules known for their low cost and integrated Wi-
Fi capabilities.
 ESP8266 is suitable for basic IoT applications, offering Wi-Fi connectivity at a lower price
point.
 ESP32 provides more features such as Bluetooth support, higher processing power, and more
GPIO pins.
 Both modules can be programmed using the Arduino IDE and have extensive community
support.

 Fire Sensor (Smoke Detector or Flame Sensor):

 Smoke detectors are commonly used for fire detection in home security systems.
 They typically consist of a smoke chamber and a sensing element that detects smoke
particles.
 Flame sensors are another option for detecting flames directly, commonly used in industrial
settings.
 Consider factors such as detection range, sensitivity, and response time when choosing a fire
sensor.

 Gas Sensor (MQ series gas sensor):

 MQ series gas sensors are widely used for detecting various gases, including carbon
monoxide (CO), methane (CH4), and LPG.

12
 They operate based on the principle of gas conductivity, where gas molecules adsorb onto the
sensor surface, changing its resistance.
 MQ sensors are affordable and easy to use but may require calibration for accurate gas
concentration measurements.
 Consider the specific gas(s) to be detected and the sensitivity of the sensor when selecting an
MQ series sensor.

 Buzzer:

 Buzzer or piezo buzzers are commonly used for generating audible alarms in electronic
systems.
 They produce sound when an alternating voltage is applied to them, making them suitable for
alerting users in case of emergencies.
 Consider factors such as sound output level, frequency, and power requirements when
choosing a buzzer for the home security system.

 Relays:

 Relays are electromechanical switches used for controlling high-power devices with low-
power signals.
 They consist of a coil and contacts, where energizing the coil closes or opens the contacts,
controlling the connected device.
 Choose relays with appropriate current and voltage ratings based on the devices (e.g., fans,
lights) to be controlled.
 Solid-state relays (SSRs) are also an option, offering faster switching and no mechanical
wear, but they may be more expensive.

Power Supply:

 Ensure the power supply can provide stable and sufficient voltage and current for the
microcontroller, sensors, and other components.
 Consider factors such as input voltage range, output voltage/current, efficiency, and safety
features (e.g., overcurrent protection, short circuit protection).
 Choose a power supply that meets the specific requirements of the components and provides
reliable operation.

13
CIRCUIT ANALYSIS & DESIGN:

1. Microcontroller Interface:
o Connect the Arduino Uno to the Wi-Fi module (ESP8266 or ESP32) using UART
communication for internet connectivity.
o Utilize digital and analog pins of the Arduino Uno for interfacing with sensors (fire
sensor, gas sensor), buzzer, and relays.

2. Sensor Interface:
o Connect the fire sensor output to a digital pin of the Arduino Uno for detecting fire or
smoke presence.
o Interface the gas sensor output with an analog pin of the Arduino Uno to measure gas
concentration levels.
o Ensure proper voltage levels and signal conditioning for accurate sensor readings.

3. Buzzer Alarm:
o Connect the buzzer to a digital pin of the Arduino Uno to generate audible alarms.
o Trigger the buzzer alarm when the fire sensor detects smoke/fire or when gas
concentration exceeds the threshold level.

4. Relay Control:

14
o Utilize digital pins of the Arduino Uno to control the relays for switching devices
such as fans and lights.
o Activate the relay connected to the fan when smoke/fire is detected to exhaust the
fumes.
o Activate the relay connected to the light when smoke/fire is detected for illumination
and evacuation assistance.

5. Power Supply:
o Provide a stable power supply to the Arduino Uno, sensors, Wi-Fi module, and other
components.
o Use a regulated power supply or batteries with appropriate voltage and current
ratings.
o Ensure proper grounding and decoupling capacitors to minimize noise and ensure
reliable operation.

6. Protection Mechanisms:
o Implement overcurrent protection for the components to prevent damage in case of
faults.
o Include surge protection devices or transient voltage suppressors to protect against
voltage spikes and transients.
o Use fuses or circuit breakers as necessary to protect against overcurrent conditions.

7. PCB Design Considerations:


o Design a printed circuit board (PCB) layout that minimizes signal interference and
ensures proper routing of connections.
o Arrange components on the PCB to optimize space utilization and facilitate assembly
and maintenance.
o Include mounting holes and labels for easy identification and installation.

8. Testing and Validation:


o Verify the functionality of each circuit block through simulation and prototyping.
o Test the response of the system under various scenarios, including fire/smoke
detection and gas level variations.
o Validate the reliability and accuracy of sensor readings, alarm triggering mechanisms,
and relay control.

9. Optimization and Refinement:

15
o Fine-tune the circuit design to optimize performance, minimize power consumption,
and improve reliability.
o Consider feedback from testing and user requirements for refinement and iteration of
the design.
o Document the finalized circuit design, including schematics, PCB layout, and
component specifications.

CODING AND TESTING


CODING
#define BLYNK_TEMPLATE_ID "TMPL3ryZci95U"

#define BLYNK_TEMPLATE_NAME "iotsystem63"

#define BLYNK_AUTH_TOKEN "sKDb3wS4prP7Bo6nYr6etz-sK6jz3PcX"

// Comment this out to disable prints and save space

#define BLYNK_PRINT Serial

#include <WiFi.h>

#include <WiFiClient.h>

#include <BlynkSimpleEsp32.h>

#include <LiquidCrystal_I2C.h>

LiquidCrystal_I2C lcd(0x27,20,4);

char auth[] = BLYNK_AUTH_TOKEN;

char ssid[] = "admin";

16
char pass[] = "12345678";

String fire_status="";

int buzzer=25;

void setup() {

lcd.init(); // initialize the lcd

// Print a message to the LCD.

lcd.backlight();

Serial.begin(9600);

Blynk.begin(auth, ssid, pass);

pinMode(buzzer, OUTPUT);

pinMode(32, INPUT);

pinMode(13, OUTPUT);

pinMode(12, OUTPUT);

digitalWrite(13 , LOW);

digitalWrite(12 , LOW);

void loop() {

Blynk.run();

int fire= digitalRead(32);

int gas_value = analogRead(34);

int gas_map = map(gas_value ,2000, 2800, 0, 100);

if(gas_map > 30)

digitalWrite(buzzer , HIGH);

delay(1000);

17
digitalWrite(buzzer , LOW);

if(gas_map < 30)

digitalWrite(buzzer , LOW);

if(fire==0)

fire_status="fire detected!!!";

digitalWrite(buzzer , HIGH);

delay(1000);

digitalWrite(buzzer , LOW);

if(fire==1)

fire_status=" NO Fire ";

digitalWrite(buzzer , LOW);

if(gas_map >30 || fire==0)

digitalWrite(12 , HIGH);

digitalWrite(13 , HIGH);

delay(20000);

18
if(gas_map < 30 && fire==1)

digitalWrite(12 , LOW);

digitalWrite(13 , LOW);

Serial.print("-");

Serial.print(gas_value);

Serial.println("-");

if(gas_map <1){gas_map=0;}

lcd.setCursor(0,0);

//lcd.print("Fire:");

lcd.print(fire_status);

//lcd.print("ug/M3 ");

lcd.setCursor(0,1);

lcd.print("co2:");

lcd.print(gas_map);

lcd.print(" % ");

Blynk.virtualWrite(V0, fire_status);

Blynk.virtualWrite(V1, gas_map);

19
20
21
22
23
24
25

You might also like