BTP Final Report
BTP Final Report
2
3
ACKNOWLEDGEMENT
We would like to express our gratitude and appreciation to all those who made itpossible to
complete this project. Special thanks to our project supervisor Dr. Sanjay Kumar Chak
whose help, stimulating suggestions, and encouragementhelped us in writing this report. We
also sincerely thank our colleagues for the timespent proofreading and correcting our mistakes.
We would also like to extend our gratitude to the staff of the Department of Mechanical
Engineering, NSUT for providing us with this golden opportunity andguiding us at all times.
4
ABSTRACT
The LPG Gas Leakage Detection System Using Arduino presents an innovative and integrated
solution to address safety concerns associated with liquefied petroleum gas (LPG) usage. The
system employs a combination of advanced sensors, microcontroller technology, and
automated actuators to provide real-time detection and response to potential gas leaks. The
MQ-2 gas sensor, interfaced with an Arduino Uno microcontroller, facilitates accurate gas
detection, triggering immediate alerts through a 5V buzzer and an LCD 16x2 screen for visual
and audible notifications. The integration of a SIM900A GSM module enables remote
notifications, ensuring timely responses even when users are not physically present. To
mitigate potential hazards, the system utilizes a servo motor for an automatic cut-off of the gas
supply and a 5V fan for rapid gas dispersal. LED lights offer visual indicators of the system's
status. Jumper wires streamline connections for efficient prototyping. The project's
comprehensive approach, combining detection, notification, and automated response
mechanisms, underscores its potential for enhancing safety in environments where LPG is
utilized. The recommendations for further enhancements aim to refine the system's capabilities
and user experience, ensuring its effectiveness in diverse scenarios.
5
LIST OF CONTENTS
1 Introduction 8-9
2 Methodology 10 - 11
3 Programming 12 - 16
5 Conclusion 26 - 34
6 Refrences 35
6
LIST OF FIGURES
4 Arduino uno 18
5 MQ-2 Sensor 19
6 Buzzer 20
7 LCD Display 20
8 Fan 22
9 LED 23
11 Jumper Wires 25
12 Flow Chart 25
13 Circuit Diagram 26
15 OFF position 29
16 ON Position 30
7
S. No Title Page Number
17 MQ-2 sensor 31
8 Servomotor 36
9 Block Diagram 36
10 Pulse Diagram 37
11 Servopinout Diagram 37
8
LIST OF TABLES
S. No Title Page
Number
1 Technical Specification of Servomotor 34
9
CHAPTER 1
INTRODUCTION
1.1 Motivation
The motivation to develop an automatic LPG gas detection system using Arduino is driven by
a paramount concern for safety, both in residential and industrial settings. LPG, being highly
flammable, poses a significant risk of explosions and fires when leaked. The development of
an automated detection system seeks to address this by providing a proactive solution to
identify gas leaks promptly. This not only ensures the safety of individuals and protects
property from potential damage but also plays a crucial role in minimizing the environmental
impact of uncontrolled gas releases. Moreover, the project offers an opportunity to contribute
to energy conservation by efficiently managing resources. The use of Arduino facilitates the
creation of a customizable and adaptable system, allowing for the integration of IoT
capabilities for remote monitoring. Beyond its practical implications, the project serves as a
platform for educational growth, offering hands-on experience in electronics, programming,
and sensor integration. In essence, the motivation stems from a comprehensive commitment to
safety, environmental responsibility, and the pursuit of knowledge and skill development.
The background of the study provides a contextual foundation for understanding the rationale
and significance of a particular research endeavor. In the context of developing an automatic
LPG gas detection system using Arduino, the background encompasses several critical
elements. Firstly, it delves into the inherent risks associated with LPG, emphasizing its highly
flammable nature and the potential for accidents, explosions, and fires when leaks occur. This
establishes the urgency and necessity of implementing a robust and proactive safety solution.
Additionally, the background explores existing safety measures and technologies related to gas
detection, highlighting any gaps or limitations that the proposed system aims to address. It may
touch upon the prevalence of gas-related incidents in residential and industrial settings,
underscoring the need for advanced, reliable detection mechanisms.
Furthermore, the background may discuss relevant regulatory standards and guidelines
governing the safe use of LPG, emphasizing the importance of compliance in the development
10
of the proposed system. Understanding the broader social and environmental implications of
uncontrolled gas leaks contributes to the overall justification for the research project.
In summary, the background of the study serves to establish the problem or need that the
automatic LPG gas detection system aims to solve, providing a comprehensive understanding
of the context, significance, and gaps in the current state of gas safety technology.
The Figure 1 above is an example of LPG explosion in which three people, including two
minor sisters, were killed in an explosion due to leakage in a cooking gas cylinder in a house in
Delhi .Such accident might occur when it is not properly-monitored.
11
The number of registered LPG consumers had increased from 106 million in 2008/09 to 263
million in the year 2017/2018. This has contributed to reducing mortalities due to pollution.
Still, an LPG cylinder in the household also increases the chance of fatal injury due to the blast
effect (Support for Clean Cooking in India 2020).
Liquid petroleum gas (LPG) is a group of flammable hydrocarbon gases which are liquefied
through pressurization. It is a blend of butane and propane gas mainly. The LPG can be stored
in a larger tank as well as in the gas cylinder. In India, the domestic supply of LPG is provided
in 14.2 and 5.0 kg cylinder. LPG has a faint smell because of deliberately added mercaptan to
help its detection. The vapor of LPG is heavier than air; thus, it normally settles down in lower
space in the event of a leak. It also condenses the water vapor in it to form a whitish fog, which
is easy to identify (Indane Gas 2020).
The LPG is also one of the gasses which is difficult to detect by human’s limitation of senses.
“Cook said that natural gas caused the explosion, but he was unable to detect any gas fumes
because a workplace accident had robbed him of his sense of smell. He happened to leave
the house to pick up his daughter from school when the house blew up” .
12
1.4 Proposed System
The "LPG Gas Leakage Detection using Arduino" system, proposed as an advanced safety
measure, aims to address the critical issue of gas leaks in environments utilizing liquefied
petroleum gas (LPG). The primary focus of this innovative system is on timely detection and
immediate response to prevent potential disasters such as explosions. At the core of the system
is a robust alarm system that activates upon sensing a gas leak, providing an audible warning to
individuals in the vicinity.
In conjunction with the alarm, the system incorporates a Short Message Service (SMS) alert
feature. This functionality serves to notify users promptly, even if they are not physically
present at the location, enabling quick and remote response to the detected gas leak.
Furthermore, the system goes beyond mere alerts by implementing an automatic supply cut
mechanism. In the event of a gas leak, the system ensures the immediate cessation of the gas
supply, preventing further leakage and significantly minimizing the risk of accidents and
property damage.
By seamlessly integrating an alarm system, SMS alerts, and an automatic supply cut, the
proposed LPG Gas Leakage Detection system using Arduino strives to create a comprehensive
and proactive safety solution. This not only enhances the overall safety protocols but also
demonstrates a commitment to minimizing the potential consequences of gas-related
emergencies in diverse settings.
BLOCK DIAGRAM-:
13
This tool operates by utilizing a gas sensor that responds to the detected levels of LPG gas. The
sensor produces a voltage corresponding to the concentration of gas, with higher levels
resulting in increased voltage output. When the Arduino detects the sensor's output indicating
the presence of gas, it triggers the activation of a buzzer and displays a message on the LCD,
signaling a high gas level indicative of a potential leak. Simultaneously, the GSM SIM900A
module sends a notification message to a predefined phone number.
Conversely, if the sensor does not detect a gas leak, it remains inactive, continuously
monitoring for any signs of an LPG gas leak. Upon program execution, the system promptly
identifies the presence of LPG gas through the sensor, and the Arduino microcontroller reads
the gas levels. In the event of a detected gas leak, the system responds by illuminating a red
LED, activating the buzzer, automatically shutting off the gas regulator supply via a servo
motor, and activating an exhaust fan to mitigate the leakage. A notification message is then
sent to alert about the gas leak. Once the issue is resolved, a green LED indicates that the
system is back to normal.
In the absence of an LPG gas leak, the system persists in monitoring the gas levels using the
LPG gas sensor until a potential leak is identified. This comprehensive approach ensures
efficient and timely response to gas-related incidents while maintaining continuous monitoring
for enhanced safety.
14
CHAPTER 2
METHODOLOGY
Figure -3
15
normal pressure by application of cooling using refrigeration. LPG comes from two
sources. It occurs naturally in oil and gas fields and is separated from the other
components during the extraction process from the oil or gas field. LPG is also one of the
by-products of the oil refining process.
□ Because of its relatively few components, it is easy to achieve the correct fuel
to air mix ratio that allows the complete combustion of the product. This gives LPG
it's clean burning characteristics.
□ Both Propane and Butane are easily liquefied and stored in pressure containers.
These properties make the fuel highly portable, and hence, can be easily transported in
cylinders or tanks to end-users.
□ LPG is a good substitute for petrol in spark ignition engines. Its clean burning
properties, in a properly tuned engine, give reduced exhaust emissions, and extended
lubricant and spark plug life.
16
□ As a replacement for aerosol propellants and refrigerants, LPG provides
alternatives to fluorocarbons which are known to cause deterioration of the earth's ozone
layer.
□ The clean burning properties and portability of LPG provide a substitute for
indigenous fuels such as wood, coal, and other organic matter. This provides a solution
to de- forestation and the reduction of particulate matter in the atmosphere (haze), caused
by burning the indigenous fuels.
□ Colourless.
□ Odourless.
□ Flammable.
17
2.2 HARDWARE DESCRIPTION
Figure -4
18
2.2.2 MQ-2 SENSOR
The MQ-2 sensor is a widely utilized gas sensor known for its versatility in detecting various
gases present in the air. Designed for applications requiring gas concentration monitoring,
this sensor is particularly popular in projects related to gas leakage detection, air quality
assessment, and industrial safety systems. Its capacity to detect gases such as methane,
butane, propane, alcohol, carbon monoxide, and smoke makes it invaluable in diverse
scenarios. The sensor's operational principle relies on monitoring changes in resistance
triggered by the presence of specific gases. As the concentration of a particular gas fluctuates,
the sensor's resistance experiences a corresponding change. The MQ-2 sensor typically
comprises a ceramic element with a built-in heater, a metal oxide semiconductor layer, and
electrodes. The heater plays a crucial role in initiating the sensing process, making this sensor
an essential component in various electronic systems where accurate and reliable gas
detection is paramount.
Figure- 5
19
2.2.3. Buzzer
The 5V buzzer is a compact and versatile audio signaling device widely employed in
electronic projects and applications. Designed to operate with a 5-volt power supply, this
buzzer emits a distinctive and attention-grabbing sound when activated. Its compact size and
low voltage requirement make it suitable for integration into a variety of electronic systems,
ranging from simple alert mechanisms to more complex projects such as security systems and
environmental monitoring setups. The buzzer typically consists of a piezoelectric element
that vibrates rapidly when an electrical current is applied, producing an audible sound. Its
straightforward design and ease of use make the 5V buzzer an ideal choice for providing
auditory alerts and notifications in a diverse range of applications, enhancing the overall
functionality and user awareness of electronic systems.
Figure- 6
Figure- 7
20
2.2.5 Servomotor
The servo motor is a fundamental component often integrated into electronic projects to
facilitate controlled and precise rotational movements. In the context of projects like gas
detection or automation systems, the servo motor plays a pivotal role. Unlike traditional
motors, a servo motor is equipped with a feedback mechanism, typically in the form of a
potentiometer, that enables accurate positioning. This feedback loop allows for precise
control over the motor's angular position, making it an ideal choice for applications where
controlled and repeatable movements are essential.
In a gas detection system, for instance, the servo motor can be employed to automatically
shut off the gas supply in the event of a leak. Upon detection of a gas leak by sensors, the
servo motor responds by mechanically turning off the gas regulator, effectively mitigating the
potential hazard. This automated response mechanism enhances the safety of the system and
prevents further leakage.
The servo motor's versatility, ease of integration with microcontrollers like Arduino, and
ability to provide controlled motion in a specified range make it invaluable for a wide array
of projects, offering precision and reliability in various applications that require specific
angular positioning and automation.
2.2.6 5V Fan
The 5V fan is a crucial component in electronic projects designed to regulate temperature and
enhance ventilation. Characterized by its compatibility with a 5-volt power supply, this fan is
commonly used in various applications, including cooling systems, environmental
monitoring, and electronic device cooling. Its low voltage requirement makes it suitable for
integration with microcontrollers like Arduino and other low-power systems.
The 5V fan typically features a compact design with blades that generate airflow when
powered. In projects such as gas detection or environmental monitoring, the fan can be
strategically placed to facilitate the dispersal of gases or improve air circulation. This is
particularly important in scenarios where prompt ventilation is required to address gas leaks
or maintain optimal conditions within an enclosed space.
21
The ease of integration, energy efficiency, and reliability of the 5V fan make it an ideal
choice for applications demanding controlled air movement in electronic systems. Its use
contributes to the overall effectiveness and safety of projects by ensuring proper ventilation
and aiding in the mitigation of potential hazards.
Figure -8
22
2.2.7 LED Light
LED lights, or Light Emitting Diodes, serve as essential components in a myriad of electronic
projects, contributing to both functional and aesthetic aspects. These semiconductor devices
emit light when an electric current passes through them, offering several advantages such as
energy efficiency, longevity, and design flexibility. LED lights are commonly utilized in
projects for signaling, illumination, and visual feedback. In applications like gas detection
systems or environmental monitoring, LEDs can be employed as status indicators, providing
a visual representation of system conditions. The ability to control LED lights with precision,
especially when integrated with microcontrollers like Arduino, allows for dynamic and
programmable lighting effects. Their low power consumption makes them ideal for battery-
operated projects, and the availability of LEDs in various colors adds a customizable element
to designs. In summary, LED lights are versatile components that enhance both the
functionality and visual appeal of electronic projects, playing a crucial role in conveying
information and creating engaging user experiences.
Figure -9
23
The module features a SIM card slot, ensuring secure authentication and user identification.
This makes it a reliable choice for projects where data security is paramount. Whether
employed for remote monitoring, automated communication, or alert systems, the SIM900A
GSM module enhances the functionality of electronic projects by providing a reliable and
efficient means of cellular communication.
Figure -10
24
Figure -11
Figure-12
25
2.4 Circuit Design
Figure -13
26
CHAPTER 3
PROGRAMMING
27
28
CHAPTER 4
Figure-15 ON position
29
3.1.2 Threshold value is less than 400
When Gas value less than Threshold value i.e 400 .Green led and buzzer Remains off
followed by rotation of the servomotor at it’s intial postion 0 degrees and fan remains off.
Gsm module don’t send any sms. .
The MQ2 sensor is one of the most widely used in the MQ sensor series. It is a MOS (Metal
Oxide Semiconductor) sensor. Metal oxide sensors are also known as Chemiresistors because
sensing is based on the change in resistance of the sensing material when exposed to gasses.
The MQ2 gas sensor operates on 5V DC and consumes approximately 800mW. It can detect
LPG, Smoke, Alcohol, Propane, Hydrogen, Methane and Carbon Monoxide concentrations
ranging from 200 to 10000 ppm.
Parts-per-million, or ppm for short, is the most commonly used unit for measuring gas
concentration. ppm is simply the ratio of one gas to another. For example, 500ppm of carbon
monoxide means that if you could count a million gas molecules, 500 would be carbon
monoxide and the remaining 999500 would be other gasses.
30
Note that the MQ2 gas sensor detects multiple gases, but cannot identify them! That is
normal; most gas sensors operate in this manner. Therefore, it is best suited for measuring
changes in a known gas density rather than detecting which one is changing.
The MQ2 is a heater-driven sensor. It is therefore covered with two layers of fine stainless
steel mesh known as an “anti-explosion network”. It ensures that the heater element inside
the sensor does not cause an explosion because we are sensing flammable gasses.
It also protects the sensor and filters out suspended particles, allowing only gaseous elements
to pass through the chamber. A copper-plated clamping ring secures the mesh to the rest of
the body.
When the outer mesh is removed, the sensor looks like this. The sensing element and six
connecting legs that extend beyond the Bakelite base form the star-shaped structure. Two (H)
31
of the six leads are in charge of heating the sensing element and are linked together by a
Nickel-Chromium coil (a well-known conductive alloy).
The remaining four signal-carrying leads (A and B) are connected with platinum wires. These
wires are connected to the body of the sensing element and convey slight variations in the
current flowing through the sensing element.
Figure-18
The tubular sensing element is made of Aluminum Oxide (AL2O3) based ceramic with a Tin
Dioxide coating (SnO2). Tin Dioxide is the most important material because it is sensitive to
combustible gasses. The ceramic substrate, on the other hand, improves heating efficiency
and ensures that the sensor area is continuously heated to the working temperature.
When a SnO2 semiconductor layer is heated to a high temperature, oxygen is adsorbed on the
surface. When the air is clean, electrons from the conduction band of tin dioxide are attracted
to oxygen molecules. This creates an electron depletion layer just beneath the surface of the
SnO2 particles, forming a potential barrier. As a result, the SnO2 film becomes highly
resistive and prevents electric current flow. In the presence of reducing gasses, however, the
surface density of adsorbed oxygen decreases as it reacts with the reducing gasses, lowering
the potential barrier. As a result, electrons are released into the tin dioxide, allowing current
to freely flow through the sensor.
32
4.3 MQ2 Gas Sensor Module Hardware Overview
The MQ2 gas sensor is simple to use and has two different outputs. It not only provides a
binary indication of the presence of combustible gasses, but also an analog representation of
their concentration in air.
The sensor’s analog output voltage (at the A0 pin) varies in proportion to the concentration of
smoke/gas. The higher the concentration, the higher the output voltage; the lower the
concentration, the lower the output voltage. The animation below shows the relationship
between gas concentration and output voltage.
This analog signal is digitized by an LM393 High Precision Comparator and made available
at the Digital Output (D0) pin.
The module includes a potentiometer for adjusting the sensitivity of the digital output (D0).
You can use it to set a threshold so that when the gas concentration exceeds the threshold
value, the module outputs LOW otherwise HIGH.
- Rotating the knob clockwise increases sensitivity and counterclockwise decreases it.
33
Figure-21
In addition, the module has two LEDs. The Power LED illuminates when the module is
turned on, and the Status LED illuminates when the gas concentration exceeds the threshold
value.
3.4 Technical Specifications
34
3.5 MQ2 Gas Sensor Module Pinout
Let’s take a look at the pinout now.
Figure-22
VCC supplies power to the module. Connect it to the 5V output of your Arduino.
D0 indicates the presence of combustible gasses. D0 becomes LOW when the gas
concentration exceeds the threshold value (as set by the potentiometer), and HIGH otherwise.
When first used after a long period of storage (a month or more), the sensor must be fully
warmed up for 24-48 hours to ensure maximum accuracy.
If the sensor has recently been used, it will only take 5-10 minutes to fully warm up. During
35
the warm-up period, the sensor typically reads high and gradually decreases until it stabilizes.
3.7 How Servo Motor Works ?
Servos are motors that allow you to precisely control physical movement because they
generally move to a position rather than continuously rotating. They are simple to connect
and control because the motor driver is built right into them.
Servos contain a small DC motor connected to the output shaft through gears. The output
shaft drives a servo horn and is also linked to a potentiometer (pot).
Figure-23 SERVOMOTOR
The potentiometer provides position feedback to the error amplifier in the control unit, which
compares the current position of the motor to the target position.
In response to the error, the control unit adjusts the motor’s current position so that it matches
the desired position.
In control engineering, this mechanism is known as a servomechanism, or servo for short. It
is a closed-loop control system that uses negative feedback to adjust the motor’s speed and
direction to achieve the desired result.
36
3.7.1 Servotor Internal working?
You can control the servo motor by sending a series of pulses to it. A typical servo motor
expects a pulse every 20 milliseconds (i.e., the signal should be 50Hz).
The length of the pulse determines the position of the servo motor.
. A short pulse of 1 ms or less will rotate the servo to 0 degrees (one extreme).
. A pulse duration of 1.5 ms will rotate the servo to 90 degrees (middle position).
. A pulse duration of 2 ms or so will rotate the servo to 180 degrees (other extreme).
Pulses ranging from 1ms to 2ms will rotate the servo to a position proportional to the pulse
width. The animation below will help you understand the relationship between pulses and
position.
3.7.2 Servo Motor Pinout
GND serves as a common ground for the motor and the logic.
5V is a positive voltage that powers the servo.
Control is an input for the control system.
The color of the wires varies between servo motors, but the red wire is always 5V and GND
is either black or brown. The control wire is usually orange or yellow.
37
CHAPTER 4
CONCLUSION AND RECOMENDATION
4.1 Conculsion
In conclusion, the development of the proposed LPG Gas Leakage Detection system using
Arduino integrates a myriad of essential components and technologies to create a
comprehensive safety solution. By combining the capabilities of the MQ-2 gas sensor for
accurate gas detection, the Arduino Uno microcontroller for intelligent processing, the 5V
buzzer and LCD 16x2 screen for immediate visual and audible alerts, the SIM900A GSM
module for remote notifications, and the servo motor for automated gas supply cut-off, this
project addresses critical safety concerns associated with LPG gas leaks. The inclusion of a
5V fan further enhances safety by facilitating the rapid dispersal of leaked gas. The use of
LED lights provides a clear visual indication of the system's operational status. Jumper wires
serve as the flexible and efficient connectors, enabling seamless integration of components.
Together, these elements form a robust and adaptable system that not only detects gas leaks
promptly but also responds with a series of automated actions to mitigate potential hazards.
The combination of precision, efficiency, and modularity embodied in this project
underscores its significance in enhancing safety measures in environments where LPG is
utilized, showcasing the potential for technology to contribute to the well-being and security
of individuals and property.
5.2 Recommendation
For the continuous improvement and refinement of the LPG Gas Leakage Detection system,
several recommendations can be considered. Firstly, implementing machine learning
algorithms or advanced pattern recognition techniques could enhance the system's ability to
distinguish between false alarms and actual gas leaks, thereby reducing the likelihood of
unnecessary disruptions. Additionally, incorporating multiple gas sensors with specific gas
detection capabilities would broaden the system's scope to detect a wider range of potentially
harmful gases. Integration with a cloud-based platform could enable real-time monitoring and
data logging, providing users with historical gas concentration trends and facilitating more
informed decision-making. Moreover, conducting rigorous testing in diverse environmental
conditions and scenarios will contribute to the system's robustness and reliability. Lastly,
creating a user-friendly interface or a mobile application for remote monitoring and control
would enhance accessibility and user experience. These recommendations aim to elevate the
LPG Gas Leakage Detection system's performance, versatility, and user engagement,
ultimately ensuring its effectiveness in diverse settings and scenarios.
38
REFERENCES
1. https://www.indiatvnews.com/news/india/three-killed-in-gas-cylinder-blast-in-delhi-
18761.html
2. Hussain A. Attia, Halah Y. Ali, ”Electronic Design of Liquefied Petroleum
GasLeakage Monitoring, Alarm, and Protection Based
3. System Based on Discrete Components”, International Journalof Applied Engineering
Research ISSN 0973-4562 Vol.No. 11.
4. Nivedhitha S,Padmavathy A P,Susaritha U S, “ Development of Multipurpose Gas
Leakage and Fire Detector with Alarm system”,
5. 2013 Texas Instruments India Educator‟Conference.
6. E. JebamalarLeavline, D. Asir Antony Gnana Singh, B. Abinaya H. Deepika, “LPG
Gas Leakage Detection and Alert
7. System”,International Journal of Eletronics Engineering Research, ISSN 0975-6450
Vol.No. 9.
8. Ankit Sood,Bablu Sonkar, Atul Ranjan, Ameer Faisal, “Microcontroller Based LPG
Gas Leakage Detector using GSM Module,
9. International Journalof Electrical and Electronics Research, Vol.3, Issue.2, pp: (264-
269), Month: April-June 2015.
10. Alan M John, Bhavesh Purbia, Ankit Sharma, Mrs. A. S. Udapurkar. “LPG/CNG Gas
Leakage Dectection System with GSM and
11. Communication Engineering, Vol.No. 6, Issue 5, May 2017.
12. https://lastminuteengineers.com/mq2-gas-senser-arduino-tutorial/
13. https://lastminuteengineers.com/servo-motor-arduino-tutorial/
39