Due to the COVID-19 pandemic, I—like many people in Japan—began working from home almost every day.
It didn’t take long to notice a problem: my home office often had poor ventilation, causing CO₂ levels to rise. This led to drowsiness, reduced concentration, and slower thinking—something studies confirm happens when indoor CO₂ goes up.
Here’s a quick guide to CO₂ levels and their effects:
- 400–600 ppm: Outdoor air level. Very good air quality.
- 600–1,000 ppm: Typical indoor environment. Little to no problem.
- 1,000–1,500 ppm: Mild drowsiness and reduced concentration may occur.
- 1,500–2,000 ppm: Noticeable drowsiness and decreased cognitive performance.
- Above 2,000 ppm: Significant decline in decision-making and cognitive function.
In Japan, office buildings must legally keep CO₂ below 1,000 ppm—but private homes have no such rule. This makes it easy to overlook ventilation when working remotely.
Why I Built My Own CO₂ MonitorI first tried a store-bought CO₂ monitor. While it worked well, I found it consumed more power than I expected—mostly because its screen was always on and updated data every second.
So, I decided to build my own low-power CO₂ monitor using electronic paper (e-paper). E-paper displays consume power only when the screen content is updated, making them very energy-efficient.
To further reduce power consumption, I chose a microcontroller that supports sleep mode and set the system to operate intermittently—waking up every few minutes to take readings and update the display.
For this project, I used the M5Paper, a device from M5Stack. It features an e-paper display and an ESP32-based module. The ESP32 supports the Light-Sleep mode. M5Paper also has a Grove port, which allows for easy connection to external devices.
By connecting a Sensirion SCD41 CO₂ sensor via the Grove port, I was able to build efficient CO₂ monitor tailored for home use.
The source code for this project is available on GitHub, so feel free to check it out if you're interested in building your own!
Hardware and DesignComponents:
- M5Paper – ESP32-based core device with a 4.7″ e-paper display and Grove port. The ESP32 supports Light-Sleep mode, allowing the device to enter a low-power state between measurements.
- Sensirion SCD41 CO₂ sensor – High-precision CO₂, temperature, and humidity sensor.
- Grove Cable – Simple I²C connection between sensor and M5Paper.
The M5Paper wakes every 20 minutes to:
- Power the sensor
- Take a CO₂ measurement
- Update the e-paper display
- Enter ESP32 Light-Sleep mode until the next cycle
According ESP32's datasheet the typical current consumption in Light-Sleep mode is about 0.8 mA. And the e-paper display don't consumes power when maintaining screen content.
This results in a highly efficient CO₂ monitor that’s ideal for long-term indoor air tracking.
Installation- Connect Sensirion SCD41 CO2 sensor to Grove Port.A (I2C) of M5Paper.
- Clone the repository:
git clone https://github.com/cubic9com/m5paper_scd41.git
cd m5paper_scd41
- Install Visual Studio Code if you haven't already.
- Open the project in Visual Studio Code:
code .
- Install
PlatformIO IDE
extension: Go to the Extensions view (Ctrl+Shift+X
). Search forPlatformIO IDE
and install it. - Open PlatformIO Home: In the left Activity Bar, click the PlatformIO icon. In the left Primary Sidebar, Go to
QUICK ACCESS > PIO Home > Open
. - Open the project: In the right Editor Groups, Click
Open Project
in thePIO HOME
tab. Select the clonedm5paper_scd41
project folder. - Upload the project: In the left Primary Sidebar, go to
PROJECT TASKS > m5stack-fire > General > Upload
.
- Pressing and holding the scroll wheel of M5Paper to perform Forced recalibration (FRC). Note: As you know, on the M5Paper, you turn it on by pressing and holding the scroll wheel for 2 seconds. Then continue pressing it.
- Wait 3 minutes.
- Your M5Paper will now display the CO2 concentration every 20 minutes. Note: To reduce power consumption, M5Paper enters Light-Sleep mode except during measurement and drawing.
Comments