Arduino LPG Gas Leakage Detection System With Auto Cut-Off Regulator

by ROBO HUB in Circuits > Arduino

4914 Views, 19 Favorites, 0 Comments

Arduino LPG Gas Leakage Detection System With Auto Cut-Off Regulator

gas leakage detection.JPG
gas leakage.gif
gas ld.gif
gas leakeg.JPG

Hey guys i would say this is one of the useful instructables that i have published and you may ask why is that!

I will tell you the reason behind this, If you have entered the kitchen or cooked something you might have come across this scenario atleast once and that is “Forgetting to turn off the gas” Apart from this there are also instances of “Flame getting turned off because of food spillage/liquid spillage on the burner” The end result from both the cases is the Gas leakage.

Note: Im referring to LPG gas don't get confused with petrol since in some regions gas means petrol!

LPG leakage can cause great problems so in this instructable I will show you a way in which if the gas leakage is detected the regulator switch will be automatically turned off and you will also be alerted, How cool is that!

I will give a cream layer of information on this and for more detailed information you can read the below steps of my instructables

MQ2 is a sensor that detects the LPG, methane, and smoke and it triggers the servo to control the regulator, i have put all the system together so that even a common man can understand to build and use this device, below i have given all the circuit diagram and explanation along with arduino program to make this gas leakage detection system



Supplies

w1.png
2w.png
3w.png
4w.png
5w.png
6w.png
7w.png
8w.png
9w.png
10w.png

These are the list of components used to build this project

Arduino Uno board

MQ2 Gas Sensor

Buzzer small

LED

Old regulator

18650 Battery with holder and switch

Servo Motor/ micro servo

Jumper Wires

Breadboard (optional)

Piece of cardboard

Hot glue

Arduino IDE and Programming cable

Note that these are amazon affiliate links and i may receive a small percent on qualifying sale at no extra cost to you this will help me to come up with other great project ideas like this

Circuit and Program

ckt.jpg
14w.png
13w.png
glo.jpg

The first step is building the circuit after you have all the components ready if you are new to this don't worry here is the Circuit explanation for those who have trouble understanding the diagram, The project has 3 main components, MQ2 sensor, Servo and buzzer(With Led)

MQ2 Gas Sensor connections

VCC pin is Connected to 5V on the Arduino

GND pin is Connect to GND on the Arduino

AO (Analog Output): Connect to analog pin A0 on the Arduino.

Buzzer

Positive which is longer leg is connect to digital pin 8 on the Arduino

Negative (shorter leg) is connected to GND on the Arduino

Servo Motor Connection

Red Wire to 5V on the Arduino

Brown Wire to GND on the Arduino

Orange Wire to digital pin 9 on the Arduino

After you have connected all these components together we can head over to uploading the code to Uno.

Simply copy and paste the below code to your IDE, select proper port number and click on upload and you should see the code uploading without any issues.

Circuit Setup

16w.png
15w.png
anni.jpg
rigid flex pcbs.png
flexxible pcbs.png
rigid flex pcbs.jpg
rigid pcb.jpg
18w.png

After we have all the components connected to each other we can place it on the piece of cardboard, i had a few pieces of 3d printed parts which served the purpose of holding the gas sensor and the servo

You can also use piece of cardboard or if you have a 3d printer you can print similar shapes to hold the sensors

Use a decent amount of hot glue so that the parts are firm on the cardboard.

I started by using double-sided adhesive on the nano, later worked on gluing the gas sensor and followed by the breadboard and the gas regulator 

Here since we have moving parts make sure the regulator and the servo are glued well and wont shake when it is working

This is not only the way you can set this up as per your requirements as of my requirement i found this the most appropriate.

You also can simplify this circuit with a Simple small PCBComplete your electronic projects in the best way from PCBWay

They are raining great offers since their 10th anniversary is live enter now by clicking here

Why them? They have provided me with the best PCB and The quality is just amazing compared to other providers in the market, They also have Color PCB printing Try it out.

Don't have a 3d printer? You can get the best 3d printing service here

Check Here for Rigid-flex Pcbs with this your circuit becomes flexible! I have added the images to this step kindly check.

A revolutionary solution that combines the best of both rigid and flexible circuitry to elevate your electronic projects to new heights.

With their expertise in advanced manufacturing techniques, they offer a seamless integration of rigid and flexible components, ensuring enhanced reliability, durability, and space-saving benefits.

PCBWay's 10th anniversary is approaching, and there will be a special event in June/July! Stay tuned for exciting offers.

Regulator On/off Mechanism

23w.png
22w.png
25w.png

The most important part of this project is this on and off mechanism, i tried many ways but in the end i found that using spring has many advantages.

The number one advantage is the shocks, the servo and the regulator switch movements are slightly different and if you are thinking to glue the horns of servo directly the servo wont be able to function well.

So i used spring and this also minimises the shock, glue the spring to the regulator switch and allow to dry completely followed by gluing the end of the spring to the servo horns.

Make sure you have sufficient distance for the swing movement in the switch and no obstacles are on the way during its action.

Before gluing turn on the project check for the position of the servo horn, after the gas regulator switch is turned to off by the servo to reset the device you have to manually turn on the regulator and all thanks to the spring to provide this flexibility



How to Use

24w.png
26w.png
IMG_5918.JPG

This is very easy! All you have to do is connect this setup to the regulator and make sure that the regulator switch is aligned well with the horns of the servo.

To take the best advantage of this setup make sure that the gas sensor has elongated wires and the sensor is placed near the burner(take care of the heat part!)

Now when you power on the setup the servo returns to its original position(when the regulator switch is On now adjust the regulator position and leave the rest to this setup!.

In case if you forget to turn of the gas or in some case due to spillage of the food on the burner the fire on the gas goes off so now the leakage of gas happens at this moment the mq2 picks up the gas.

It alerts you with the sound of buzzer along with red light and instantly the servo horn moves thereby turning off the regulator switch.

to reset the system all you have to do is manually turn on the regulator switch along with servo horn and now turn on the power and the system is ready for use now.

This is all about this project if you have any suggestion for improvements let me know in the comments, Thanks and happy building

Working Video

Make LPG Gas Leakage Detection System with auto cut off regulator using Arduino in Easy Way

Here is the detailed video tutorial of this project, i have shown how to setup the components properly so that the mechanism runs smoothly.

You can see the amazing working mechanism in which the spring and servo controlling the regulator to turn of the gas supply.

If you still end up with any questions or have any suggestion for improvements there is a comment box below that will connect us, Thank you