

DifferentialPressureSensor
A esp32-s3 project to record data from an I2C differential barometer, with a oled display, usb mass storage interface and web UI. Optimized for low power battery operation
- Size
- 88.5 × 65 mm
- Copper layers
- 2
- Thickness
- 1.6 mm
- Parts
- 15
- Nets
- 45
- Pads
- 88
- Tracks, vias
- 216, 0
- Routed
- Yes
- KiCad
- KiCad 9.0 (file 20241229)
- Created
- 7 Aug 2025
- Updated
- 13 Jul 2026
Overview
DifferentialPressureSensor is an open-source printed circuit board by maunope, from the maunope/DifferentiaPressureSensor repository on GitHub, published under the Apache-2.0 licence. It is a 2-layer board of 88.5 × 65 mm with 15 parts on 45 nets, routed with 216 tracks and 0 vias.
It is built around the BS170. Its parts include 5 resistors, 1 IC and 1 diode. It belongs with the lEDs and displays and sensors and measurement boards and the ESP32 boards of this library.
Main components
1README
README.mdESP32-S3 Differential Pressure Datalogger
This project is a datalogger built on the ESP32-S3 platform using the ESP-IDF framework. It's designed to read environmental data from a BMP280 sensor, display it on an OLED screen with a menu-driven interface, and log the data to an SD card. The system uses a DS3231 Real-Time Clock (RTC) for accurate timestamping and exposes the SD card as a USB Mass Storage Device for easy data access.
Please refer to the following main guides for usage guidance and documentation:
- User Interface Guide: A complete guide to the on-screen menu system and controls.
- Web UI Guide: Instructions for using the web interface to manage files.
- Software Architecture: An in-depth look at the software design, tasks, and communication mechanisms.
- Board Design: Details on the custom PCB, hardware components, and pinout.
Overview
Key Features
- Sensor Datalogging: Periodically reads:
- Temperature and atmospheric pressure from a BMP280 sensor.
- Differential pressure from an Omron D6F-PH sensor.
- LiPo battery voltage and percentage.
- Device uptime in seconds.
- Dual-Mode Data Smoothing: Configurable Kalman filtering is applied to all sensor readings. The system uses two distinct sets of filter parameters for "Normal" and "High-Frequency" logging modes. All parameters (
kf_*_q,kf_*_r,kf_*_q_hf,kf_*_r_hf) can be customized inconfig.ini. If high-frequency (_hf) parameters are omitted, the system automatically calculates sensible defaults based on the normal-frequency values. - SD Card Storage: Logs sensor data to CSV files on an SD card, with support for file rotation based on size (1MB limit, approx. 2 weeks of recording at 1 point per minute).
- Real-Time Clock (RTC): Utilizes a DS3231 RTC for accurate timestamps. The system can synchronize its time from the RTC on startup.
- OLED Display & UI: Features a menu-driven user interface on an OLED display, controlled by a rotary encoder with a push-button. The UI displays:
- Real-time sensor data (temperature, pressure, differential pressure, battery status).
- Current local timestamp (CET/CEST).
- SD card write status.
- Persistent status icons for battery level, charging status, and SD card write errors.
- A settings menu to manage the RTC, SD card, view configuration, and display a QR code linking to the project repository.
- NTP Time Sync: Can synchronize the RTC with an NTP server over Wi-Fi.
- Web Server: Can start a web server to allow downloading and previewing logged data files directly from a web browser.
- Multiple Sampling Modes: Supports "Normal", "High Frequency", and "Paused" logging modes, selectable via the UI.
- Robust Power Management: Implements a command-driven deep sleep cycle to conserve battery. The datalogger task explicitly signals when it's safe to sleep, preventing race conditions and ensuring data integrity. The device wakes up on a timer for the next log or via user interaction. A safety threshold on battery voltage avoids data corruption when measured battery voltage is too low to guarantee stable power to the 3.3V rail.
- Web File Management: The web interface allows users to list, preview, download, and delete log files directly from the device.
- Exclusive File System Access: To prevent data corruption, the system ensures that only one component (Datalogger, Web Server, or USB Mass Storage) can access the SD card at a time. For example, starting the web server will pause the datalogger, and connecting the device to a PC will disable both the web server and the datalogger.
- Configuration & Persistence:
- Permanent Settings: Key parameters like sleep intervals, Wi-Fi credentials, and sensor models can be configured via a
config.inifile on the SD card. These settings are loaded into flash memory and persist across reboots. - Session Settings: UI-selected modes (like "High Frequency" or "Paused") are stored in RTC memory and persist through deep sleep cycles, but will be reset to their default values after a full power cycle or reboot.
- Permanent Settings: Key parameters like sleep intervals, Wi-Fi credentials, and sensor models can be configured via a
- RTOS-based: Built on FreeRTOS, with separate tasks for data logging and UI rendering for a responsive and robust application.
Hardware Components
- Microcontroller: ESP32-S3
- Sensors:
- BMP280: Barometric Pressure and Temperature (I2C)
- Omron D6F-PH: Differential Pressure (I2C)
- Storage:
- MicroSD Card Slot (SPI)
- Display:
- OLED Display (I2C)
- User Input:
- Rotary Encoder with Push-button
- Timekeeping:
- DS3231 Real-Time Clock (I2C)
- Power:
- LiPo Battery with a voltage divider for monitoring.
For more details on the custom PCB, see the board design documentation.
Hardware Notes
DS3231 RTC Configuration
Please be aware that this firmware automatically configures any connected DS3231 Real-Time Clock with specific default settings upon boot. These settings are optimized for low-power operation and resilience. For details on the exact register values being set, please refer to the readme.md file located in the lib/i2c_ds3231/ directory.
Usage
- Configuration: Copy the
config_sample.inifile to the root of your SD card and rename it toconfig.ini. Edit this file to set your Wi-Fi credentials, sensor model, and other parameters. - Operation: The device is controlled with the rotary encoder and its built-in push-button. For a detailed explanation of the menu system and on-screen information, please see the User Interface Guide.
- Web Interface: When the web server is active, you can manage files from your browser. See the Web UI Guide for more details.
Software & Libraries
- Framework: ESP-IDF
- RTOS: FreeRTOS
- Component Management: Dependencies like
qrcodeandtinyusbare managed by the ESP-IDF Component Manager via theidf_component.ymlfile. Theesp_tinyusbcomponent for USB Mass Storage is enabled and configured directly throughmenuconfig, with settings reflected in the PlatformIO build profiles. - Software Architecture: The project is built on a multi-tasking architecture using FreeRTOS. For a detailed explanation of the tasks and how they communicate, see the Software Architecture Guide.
- Custom Libraries (located in
lib/): This project uses a modular structure with several custom libraries. Click on a library name to see its specific documentation.config_manager: Handles loading configuration from an INI file.i2c_bmp280: Driver for the BMP280 sensor.i2c_d6fph: Driver for the Omron D6F-PH sensor.i2c_ds3231: Driver for the DS3231 RTC.i2c_oled: Driver for the OLED display.kalman: kalman filter implementation.lipo_battery: Logic for reading battery voltage.ntp_client: Helper for synchronizing time from an NTP server.rotary_encoder: Driver for the rotary encoder input.spi_sdcard: High-level manager for SD card operations and USB MSC.ui: Manages the complete user interface, menu, and pages. See the UI Guide.web_server: Provides a web interface for downloading log files. See the Web UI Guide.wifi_manager: Centralizes Wi-Fi connection and disconnection logic.
Parts
15| Qty | Value | Footprint | References |
|---|---|---|---|
| 4 | Conn_01x04_Pin | Connector_PinHeader_2.00mm:PinHeader_1x04_P2.00mm_Vertical | Ji2c1, Ji2c2, Ji2c3, Joled1 |
| 3 | 4.7k | Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_Horizontal | R1, R4, R5 |
| 2 | 1k | Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_Horizontal | R2, R3 |
| 2 | BS170 | Package_TO_SOT_THT:TO-92_Inline | Qi2c1, Qoled1 |
| 2 | ~ | Connector_PinHeader_2.00mm:PinHeader_1x05_P2.00mm_Vertical | Jrotary1, Jspi1 |
| 1 | ESP32-S3-DEVKIT-LIPO | Olimex ESP32 S3 LiPo Devkit:XCVR_ESP32-S3-DEVKIT-LIPO | U1 |
| 1 | LED | LED_THT:LED_D3.0mm | D1 |
Questions
How big is the DifferentialPressureSensor PCB?
It measures 88.5 × 65 mm and has 2 copper layers, 1.6 mm thick.
What parts does the DifferentialPressureSensor use?
15 parts, built around the BS170. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.
Where can I download the DifferentialPressureSensor KiCad files?
From the maunope/DifferentiaPressureSensor repository on GitHub, at the commit this page was made from: the board is board/DifferentialPressureSensor/DifferentialPressureSensor.kicad_pcb and its schematic board/DifferentialPressureSensor/DifferentialPressureSensor.kicad_sch. PCBKit opens the board in the browser, with nothing to install.
Can I use the DifferentialPressureSensor design in my own project?
Its repository publishes it under the Apache-2.0 licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).
Similar boards
- 2 layers21.1 × 26.9 mm

- 2 layers94.6 × 46.1 mm

- 2 layers97.1 × 97 mm

- 2 layers121 × 68 mm

Freeds sanchez
pablozg/freeds
Derivador de energía solar excedente creado por Pablo Zerón, Diseño PCB por Amcalo, Tester original por Aeizoon, Wiki por Zoilo Mora
42 parts108 - 2 layers167.6 × 97.5 mm

AS3397 proto DIP
PhysicsDptAngers/polyUAnalog
Open source, analog and polyphonic synthesizer
142 parts88MIT - 2 layers70 × 55 mm

- 2 layers

T41-Main+RF board V012
DRWJSCHMIDT/T41
This is the repository for the officially released V10, V11, and V12 versions of the T41 Software Defined Transceiver hardware and kits.
255 parts66 - 2 layers71.1 × 24.1 mm

Dactyl manuform gimbal
sffubs/dactyl_manuform_gimbal
Instrutions and designs for building the dactyl-manuform-gimbal keyboard
20 parts57