An alternative firmware for the OpenCO2 Mini by @davidkreidler. This firmware has a more restricted feature-set than the original firmware, the focus is given on BLE connectivity and faster measurement rate (1Hz).
- Connectivity with MyAmbience mobile app:
- Live data
- Data download
- FRC support
- Custom name support
- LED colors synced with MyAmbience alerts.
The firmware is built around the official STCC4 driver and the "UPT BLE server" library.
To update your OpenCO2Mini firmware you can follow the steps below:
- Download the binary of the latest release here
- Open the online programmer of ESPBoards.dev available here (or similar)
- Click
Connect to ESPand chose the your device in the list. - Select
Flash firmware - Add the
.binfile downloaded at step 1 and enter the Application address0x10000(not 0x1000 ! Which is the bootloader address.) - Click
Programbutton and wait for the upload to complete. - Once completed, the device can be power cycled by plugging it out and back in.
- You are done.
Development is done using PlatformIO.
- Install PlatformIO
- VS Code extension: install "PlatformIO IDE" from the Extensions marketplace.
- or CLI:
pip install -U platformio(requires Python 3.8+).
- VS Code: Open this folder, then in the PlatformIO panel select the
openco2-minienvironment and click "Build". - CLI:
- From the project root run:
pio run -e openco2-mini
- From the project root run:
The OpenCO2 Mini must be in bootloader mode to accept a new firmware.
- Prepare the device
- Hold down the button on the OpenCO2 Mini.
- While holding the button, plug the device into a USB‑C port of your computer.
- Release the button after it is connected. This puts the device into download (bootloader) mode.
- Upload
- VS Code: In PlatformIO, select the
openco2-minienvironment and click "Upload". - CLI:
pio run -e openco2-mini -t upload
- VS Code: In PlatformIO, select the
- Reset after upload
- After a successful upload, trigger a reset by unplugging the device and plugging it in again.
Notes
- The serial monitor (115200 baud) can be opened via PlatformIO after the device has rebooted.
- If upload fails, retry the bootloader sequence (hold button → plug in → release) and run the upload again.