Monitor The Pollution On Your Commute

Commuting through the urban sprawl of a 21st century city brings exposure to significant quantities of pollution. For a Medway Makers member that meant the Isle of Dogs, London, and a drive through the Blackwall Tunnel under the Thames. When you can taste the pollution in the air it’s evident that this isn’t the best environment to be in, but just how bad is it? Time to put together an environmental monitoring and recording rig.

Into the build went an ESP32 module, an SPS30 particulate sensor, an MH-Z19 CO₂ sensor, an HTU21D temperature and humidity sensor, and a uBlox NEO 6M GPS module. The eventual plan is to add an SD card for data logging, but in the absence of that it connects to a Raspberry Pi running Grafana over InfluxDB for data analysis. The result provides a surprising insight into the environmental quality of not just a commute but of indoor life. We’re sorry to say that they don’t seem to have posted any of the code involved onto the Medway Makers writeup, though we hope that’s an oversight they’ll rectify by the time this has gone live.

This isn’t the first environmental monitor to grace these pages, indeed we’ve had quite a few as Hackaday Prize entries.

17 thoughts on “Monitor The Pollution On Your Commute

  1. Nice project! $80+ worth of sensors and modules. Would be nice if this was a wearable device, warning you about harmful levels of pollution. I’ve got such a sensor in a (commercial) air cleaning device but that’s hardly portable. During Easter there’s a lot of burning wood piles across the country, the pollution from that makes it hard to breathe. Clean air is becoming a hard to get commodity these days.

  2. Uh Hackaday, don’t tease me please!!
    This CO2-sensor looks really interesting, but it’s almost 22€ (about the same in USD iirc)… I searched on the internet and found quite some information like here and probably here (im afraid it’s in russian with i don’t understand). However i also found this . It’s in german, but the TL;DR is these sensors are horrible, have a lot of noise, false readings and so on. The manufacturer didn’t respond well altough the guy bought 500 of the sensors. Making a good sensor is hard. They talk about sensors from swedish (iirc) company Senseair, but it’s not the same price. Their sensor costs about 80$ which is quite a lot for a “fun” project. There is an Aliexpress-listing for about 40$ but i don’t trust it.

    Does anybody here had the opportunity to check this MHZ19 against a known-good, professional (and expensive) measuring device? How good/bad is it really? What about aging?

    1. Hey, at least it’s not a VOC sensor being advertised for CO2. I see a lot of VOC sensors advertised as calculating “equivalent CO2” but that number is complete bullshit.

          1. Thank you!
            Th price is intersting, but I’m afraid it looks like they don’t ship to Europe… (The website show 46$ shipping with EMS and when i click to modify the method they tell me they don’t ship to my country at all…)
            Thank your for the warning about ESD.

    2. I bought a MH-Z14A from bang good and never used. The datasheet is sketchy but you are supposed to calibrate it for one hour every day in 400ppm CO2. Or maybe it self calibrates and automatically resets to 400ppm at that moment? no idea…

      It turns out that a lot of gas sensors have the same deal: they drift a lot over time and need to either be calibrated or flat out replaced often.

        1. Thanks a lot! This is a good reason to be determined to spend more money and buy the Sensirion one people were mentioning.
          I like the way google translates the beginning of the article: “In order to finally decide the outcome of the age-old feud in the office between “those to whom it blows” and “those who are stuffy” decided to splurge on the budget CO2 sensor in atmospheric air”

          1. Well, nothing to unexpected for cheap chinese stuff. If i understand correctly the thing works, there are just some quirks about the range. Is this true? I’m still not sure if i should buy this one or a more expensive device.

  3. if it helps, automotive gas analysers use replaceable sensors and they measure CO, CO2, 02, NOx and HC . im sure these could be a source of reasonably priced and accurate test elements.

    1. But is it not so that automotive gas sensors only function at high temperatures? If one looks up “oxygen sensor”, the only thing that comes up is an automotive type that seems to be intended for use in the combustion stream. And when one finally does find a normal, 5v, room temperature type, it costs the moon.

      1. there are two types of lambda sensors, the old binary sensor which only “toggles” between 0,1volts and 0,9V with some hysteresis for a specific amount of oxygen (that’s why they are called binary, they just indicates if the mixutre is either lean or rich in oxygen) and the newer wideband sensors which gives a more reliable analog readings, although are a bit more tricky to interface since they operate as a current source instead of a voltage source. There are specific ICs meant to control those wideband sensors but there is not much documentation aviable since it’s usually bosch propietary technology and not much is out there. They have a built-in resistive heater that the engine control unit turns on when the engine is cold and after a while it just PID’s the heater when the exhaust gases are hot enough. I might be wrong but the wideband ones don’t require such a high temp to operate although they are designed to be pluged into the exhaust pipe so…

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.