Raspberry Pi Python codebase for bcMeter (DIY), the source-available, portable black carbon measurement device for citizen science and air quality monitoring. Freely available for private, educational and research use (CC BY-NC 4.0). See bcmeter.org.
This repository replaces the legacy Raspberry Pi codebase with a redesign focused on maintainability, reliability, and a clearer installation and update workflow. The legacy Raspberry Pi repository remains available at dahljo/bcmeter.
- Optical absorption measurement for black carbon monitoring
- ADS8344E (SPI) + MCP342X (I2C) ADC support
- FastAPI-based web API and configuration interface
- OTA updates via GitHub Releases
- CSV data logging with session management
- Optional BME280 / SHT4x environmental sensors
- Optional SPS30 particulate matter sensor
- Optional GPS positioning
- Optional SIM7080G cellular modem support
- Multi-wavelength measurement support is in development
Recommended: download the current Raspberry Pi bcMeter image from bcmeter.org, flash it to a microSD card, boot the Raspberry Pi, then complete setup through the bcMeter web interface.
Manual installation is also possible on a fresh Raspberry Pi OS Lite installation. After booting the Pi with network access, log in and run:
wget -N https://raw.githubusercontent.com/dahljo/bcmeter-pi/main/install.sh
sudo bash install.shbcmeter/— Core modules (sensors, optics, pump, config, measurement engine)api/— FastAPI REST API routesinterface/— Web frontend assetsmain.py— Application entry pointbcMeter_config.json— Default configuration template; installed devices keep their local runtime config during updates
install.sh— Bootstrap wrapper for fresh Raspberry Pi OS Lite installs; it downloads/updates the installer and runs it insidescreen.install.py— Main installer/updater used by the image, manual installs, OTA updates, and v1-to-v2 migrations.
Private production, QC, lab-control, deployment, and credential-provisioning tools are deliberately maintained outside this public DIY repository. The device accepts updates only from the fixed GitHub Releases channel with a mandatory SHA-256 digest and safe archive extraction; arbitrary archive upload is not part of the public API. See SECURITY.md.
Source-available under the Creative Commons Attribution-NonCommercial 4.0 International license (CC BY-NC 4.0). Freely available for private, educational and research use. For commercial licensing, visit bcmeter.org.