Gas and smoke detector update

A while ago I made a rather silly project as I had a spare MQ2 sensor laying round left over from a previous experiment. I decided to build a circuit that simply displays the analog value from the sensor on a 7 segment display. It was a bit pointless but it did detect gas, farts 🙂 and smoke. I have since modified the project so it displays more meaningful results. I used an example to calculate the parts per million reading from the sensor by using a formula that works it out from the sensor’s response curve. This is found in the device’s data sheet. I still don’t expect it to be accurate but it definitely works.

I’m going to be re-visiting some of my earlier projects and either scrapping or improving them now that I have learnt more about embedded programming and Ansi C / C++.

The original post and modified code is here.