Gas Sensor: a Grove Sensor Adapter project
The Grove gas sensor allow for some unique experiments. The gas module can detect "H2, LPG, CH4, CO, Alcohol," and we're using the MQ5 model which is best at detecting "LPG, Natural Gas, Town Gas." With the mindsensors Grove Sensor Adapter it's super easy to connect it to your EV3 and start taking measurements, so let's get right to it.
The Grove Sensor Adapter is connected to sensor port 1, and the Grove gas sensor is connected to the adapter.
The sensor and adapter are mounted on the side for convenience, and to keep everything together.
First we need to calibrate the gas sensor, as every environment is different. This program displays the initial R0 value. We just run the program and copy the number.
Then we can start taking readings! The main measurement we're interested in is the RS/R0 ratio.
With the graph below you can find how many parts-per-million there are of these gasses. Our measurement is 6.5369 is right at the air level, very little or none of the other gasses detected. Remember the scales of this graph are logarithmic!
The first program is fairly straight-forward. It takes 100 readings from the sensor, calculates the average.
With that average it does a bit of math and displays the R0 value on screen.
The first block of the second program is that R0 number we just got. This program also takes a measurement, does a bit of slightly-different math, and shows the result on screen.
Some of the intermediate numbers are also shown, if you want to take a look at those.
This sensor is great at detecting any gas leakage, and has high sensitivity and response time. The Grove Sensor Adapter makes it a snap to get the sensor's value on the EV3. The gas sensor enables some very unique experiments!
The graph and gas types are from the Seeed wiki for Grove devices.