- CO2 measuring range: 400-8192 PPM
- 12 hours of battery life provided by a 18560 cell
- Pretty graphs on a web interface
- Data can be exported to Excel and software alike
Breaking it down
I bought a cheap plastic box on Aliexpress for this project. I drilled some holes on the front for screws, LED's, the button and made some space for the screen. On the back, I've made space for a power cord and an on/off rocker switch.
Inside the unit, there's a small fan running in ten-second intervals for refreshing air inside to get better measurements.
The box ended up being a bit large for the project. When I ordered all the parts I had planned to use an Arduino MEGA as well but ended being able to use the ESP32 for everything. But with all the clutter, fan, battery, screen, etc. it's not that oversized.
What it measures:
- TVOC - CCS811
- CO2 - CCS811
- Temperature - BMP280
- Atmospheric pressure - BMP280
Most data points here should explain themselves. But some people might be unfamiliar with TVOC. Total volatile organic compounds is a group of different molecules like alcohols, aldehydes, ketones, organic acids, amines, aliphatic and aromatic hydrocarbons.
The CCS811 doesn't actually claim to measure CO2. Instead, it measures something called eCO2. It's a calculated number, not the actual amount of CO2. But because there is a very tight correlation between TVOC's and CO2 that's no problem for measuring air quality, and it works wonders for the job.
You could actually argue that it's a better way of doing it, in terms of measuring air quality because TVOC's are a better measurement for air quality.
While testing I have made some different observations that affect the measurement if the source is relatively close.
- Opening a coke - if opened closely it will affect the reading.
- Taking shoes off - if your shoes smell after a long day it will show up.
- Spray deodorants - if you apply spray deodorant, then you should probably not do so near this.
Others more obvious observations include painting, cleaning products and so on...
The ESP hosts a web interface providing:
- Real-time data
- 24 hours graphs for temperature and CO2
- Downloadable log
- Remote restart
Calibration and precision:
As of now, I've made four units. Running them close to each other for some time they even out up to 100 PPM CO2 difference. This is more than enough precision for this purpose. But I've tested them up against a professional CO2 monitor as well with similar accuracy. And of course, they've been tested against fresh air which is somewhere between 350 and 400 PPM CO2.
When you first power on the device, it will try to connect to the last WiFi. If that times out after a minute, it will power on an AP called "AirMonSetup" and display an IP address. Simply connect to the AP and go to the IP and you will be guided by an intuitive WiFi connecting interface (largely thanks to the WiFiManager.h library!).
After connecting it will take some minutes for the sensor to warm up. This process usually only takes 10 minutes, despite the datasheet claiming 20 minutes. But this is no worry since it's made for 24/7 operation so it won't be restarted often.
The CCS811 will also require a burn-in first time it's used. This can take a couple of days before reliable data starts showing.
During normal operation, a new data entry is saved every second logging the previously mentioned data points...Read more »