Projects with Ryan Slaugh: DIY Gas Leak Detector

Projects with Ryan Slaugh: DIY Gas Leak Detector

Hi, this is Wayne again with a topic “Projects with Ryan Slaugh: DIY Gas Leak Detector”.
In this episode of projects, we’ll take the atmospheric detector kit from the maker shed and make a prototype propane leak detector. This simple detector made out of pvc pipe and using one of the gas sensors in the lcd and an arduino will allow the user will to detect leaks in propane connections, whether it be in barbecue grills or in rvs. In the atmospheric detector kit you get everything showing here, except for the arduino and the breadboard. You get these two gas sensors an mq6 and mq2. They can detect different types of gases and you also get a serial lcd really easy to connect to a to an arduino. The libraries are available online.

The schematic and the code is available. With this video. You get two resistors they’re 10k.

Projects with Ryan Slaugh: DIY Gas Leak Detector

Each you get a fet or field effect transistor. We won’t use that in this project you get two switching transistors. These are important and, of course, our favorite lm7805 power converter for five volts. You also get a bunch of different wires to wire everything up together.

Projects with Ryan Slaugh: DIY Gas Leak Detector

The kit is actually very thorough in what it gives you and the book is easy to read as well. I’Ll use my nine volt project box, as i have in the past for power, the gas detectors themselves are mounted onto their own little printed circuit boards. With a three pin connector, you have power ground and signal. In essence, the gas detectors themselves are just variable.

Projects with Ryan Slaugh: DIY Gas Leak Detector

Potentiometers, give you a variable resistance out via what type of gas they’re detecting inside each sensor is a little heater that will be powered by the five volts applied to them. So, as always, we begin by hooking up our breadboard power rails, hooking, my arduino and here’s. The transistors these will actually switch the load or switch the heaters on. You can’t power the heaters in the sensors directly from the arduino.

It doesn’t have enough power out to do so so use the switched. Switching transistors, i hook the 10k resistor at the base of the switching transistor and the other end to our 5 volt rail. The other end of the resistor goes into a digital pin on the arduino, so it can be controlled. The actual sensors come with a nice. Three pin wiring already made up you just plug them in to where the colors will be corresponding. You want, of course, red to vcc ground is black and the white wire. There is your signal wire that will go into the analog input of your arduino, plug that directly into the breadboard right by the switching transistor that controls it put in the other gas sensor.

There find a place to mount running all the wires, then i’ll wire in the signal line into analog input. I use analog input 5 and 4 on my arduino for the gas sensors. Next comes the lm7805 i’ll put it on my breadboard and power, one of the rails on the side closest to me there to 5 volts, which is where the gas sensors will plug in.

So that way it takes the 9 volt steps it down to 5.. Next is the serial lcd. Again, it comes with its own wire, it’s a four wire connection. You have vcc and ground, you can use five volts and then, of course, the ground wire and you do need the rx and tx for the lcd to work and that’s put into two different digital pins on the arduino. Now, when you turn it on, the first thing that will happen is a 10 second buffering.

What this is doing is the arduino tells the transistors to turn on the 5 volts to the sensors and they start the heater and that heats them up and gets them to start taking data after this 10 seconds, you’ll see that your arduino is actually gathering the Data now remember, you’ll, see 0 to 1023 points in an analog input. That’S what we’re seeing right now over time, if you let them heat up even more and actually the spec sheet says to give them a 24 hour soak for best use. If you want long-term sensing, those numbers will gradually level out, but when gas is introduced, you’ll see the one sensor there reacts and the numbers increase when in this case propane is present in simp. In short, that’s the simple connections of the atmospheric detector kit for the gas detectors to start building on my prototype.

I’Ll use three quarter inch: pvc here i’ll start with a pvc t joint and cut the top of it off with my bandsaw. This will create sort of a cradle more on that in just a little bit. Next, on the same bandsaw i’ll, just cut off a small section of three quarter: inch: pvc pipe for a handle or a body of the detector itself from here using another pvct.

I create a little collection unit, so a handle a cradle and the end i’m going to put a little section of pipe with a notch cut out of it. This notch here is so the sensor can sit directly on the flush end of the pipe there’s. A little potentiometer there on the end of the sensor that can fit down in that notch, trying to turn around here. So you can see every angle that pipe sits right in the end and that’s where the detector will be placed. I might end up turning that around in order to get the wires to run just a little easier. I did have to change my programming a bit. I now only use one sensor when you turn it on it. First still does the 10 second warm-up turns the heater on in the sensor and does the heat on settle routine, as i have called it here. So 10 seconds turns it on and does that next it’ll actually collect a 10 second average.

I want it to take 10 readings, one every second and average them together after that. It then goes to a half, a second sampling, one every 500 milliseconds and does a rolling average and shows you here the average and what the current sample has been when gas is brought near the sensor. If the current goes over a certain limited amount, we’ll get three stars and it will alarm telling us we have a gas leak.

So here’s the final creation, the sensor in the end. This is a cradle where you can lay your propane hose or the line that you’re scanning and there i have the readout telling me what the current average is. If we have propane come near or a leak, we get three stars telling us that the rate of propane has elevated and therefore we have a leak. Perhaps one change i might do – is drill a few holes here to allow the gas to escape quicker. Well now this is our first take at a prototype of a diy gas detector. I hope it’s given you some ideas.

Happy building, .