Recursive Penguin

Co2 Data Logging

Recently I was convinced by a friend to get a CO2 sensor to check on the levels in my apartment, citing the correlation to CO2 and cognitive function. The sensor I picked up immediately showed that the levels in my apartment were around 1800ppm above the recommended amount. I wanted to be able to log the CO2 levels over time so I threw together this quick project to read the data out of the sensor. Now I can see how opening different windows or doing things like turning on the bathroom fan affect the CO2 levels and how fast.

If you're curious about logging CO2 levels and building a dashboard to show them this guide below should let you replicate my setup.

Parts🔗

C02 sensor AZ Instrument RH7722
This is device that will do the actual measurement.

Particle photon
This will connect to the CO2 sensor and send the data to adafruit.io

Barrel Connector
This lets us connect the Particle to the CO2 sensor

Prototyping kit
If you don't have a breadboard, a 1k resistor, or hookup wire this looks like an acceptable little kit

Wiring🔗

Hook up the Photon like this, using a 1k resistor as a pull up for the UART communication.

Setup Adafruit IO🔗

Setup an account on Adafruit IO
https://io.adafruit.com/

From there you will want to set up 3 new feeds named, temperature, humidity, and co2

Click the yellow AIO key link in the upper right to get your key and save it for the next step.

Programing the Photon🔗

Now follow the instructions to get your Particle Photon connected to your wifi https://setup.particle.io/
One that is complete load up the code for this project here: https://go.particle.io/shared_apps/5ddc83012b93b800054a08b4
On line 4 put your AIO key from earlier into the quotes replacing the key_here text.
You can now flash this code to the Photon.

Once that is done, go back to the Adafruit IO page and you should see data in your feeds. You can now make a new dashboard that uses these feeds to show information. Have fun!