Hardware Targets & Specifications
Relevant source files
The following files were used as context for generating this wiki page:
Introduction
The OpenAwair project targets two specific indoor air quality monitoring devices: the Awair Glow C and the Awair Element. These devices originally relied on cloud services that were discontinued in 2022. The project's hardware scope involves repurposing the existing physical components and internal microcontrollers to support local-first operation via custom firmware and host-side tooling.
Both target devices share a common core processing module but differ significantly in their peripheral sensor arrays and user interface components. The firmware is designed to auto-detect the device type—for instance, by probing for the presence of a CO₂ sensor—to apply the appropriate driver configurations and logic.
Sources: CLAUDE.md:5-9, CLAUDE.md:144-145
Core Processing Architecture
Both the Awair Glow C and Awair Element are built upon the Laird Sterling-EWB module. This module integrates high-performance processing with wireless connectivity.
| Component | Specification |
|---|---|
| MCU | STM32F412 (ARM Cortex-M4) |
| Wi-Fi/BLE | Cypress CYW4343W |
| Debug Interface | SWD (SWDIO, SWDCLK, NRST, GND, 3.3V) |
| Board ID (Element) | AWAIR-LITE-MAIN V2.0 |
Sources: CLAUDE.md:11-13, CLAUDE.md:27-28, firmware/README.md:5-7
Memory and Programming
The MCU may arrive with read-protection enabled, requiring a full erase before custom firmware can be loaded via ST-Link or J-Link programmers using the test pads on the PCB. The flash memory is organized into regions to support safe Device Firmware Updates (DFU):
- Bootloader Region (64-128KB): Handles BLE-based DFU and recovery.
- Application Region: Contains the main firmware, including networking stacks and sensor scheduling.
Sources: CLAUDE.md:28-29, CLAUDE.md:58-61
Device Specifics & Peripherals
Awair Glow C
The Glow C is designed as a smart plug with integrated air quality sensors and a nightlight.
- Sensors:
- SHTC3: Temperature and Humidity (I²C)
- SGP30: TVOC and eCO₂ estimate (I²C)
- PIR: Motion detection (GPIO)
- Actuators/UI:
- Relay: Smart plug control (GPIO)
- RGB LED: Nightlight and status indication (GPIO/PWM)
Sources: CLAUDE.md:15-20
Awair Element
The Element is a dedicated air quality monitor featuring a dot-matrix display and more precise gas sensing.
- Sensors:
- SHT30: Temperature and Humidity (I²C)
- SGP30: TVOC (I²C)
- Honeywell HPMA115S0: PM2.5 (UART)
- Telaire T6703: CO₂ NDIR (UART/I²C)
- Ambient light sensor
- UI: Dot-matrix LED display.
Sources: CLAUDE.md:22-26
Data and Component Flow
The following diagram illustrates the relationship between the hardware components and the firmware abstraction layers.
The firmware manages different sampling intervals for sensors: Temperature/Humidity are read every ~1s, while the SGP30 VOC sensor is sampled every 2-10s and requires baseline persistence to flash every 12 hours.
Sources: CLAUDE.md:46-52, CLAUDE.md:65-70, host/src/firmware/device.ts:8-23
Software Configuration
The hardware targets are defined in the firmware configuration to allow for conditional compilation and runtime identification.
Firmware Target Definitions
#ifndef OPENAWAIR_FIRMWARE_CONFIG_H
#define OPENAWAIR_FIRMWARE_CONFIG_H
#define OPENAWAIR_MODEL_GLOW_C 1
#define OPENAWAIR_MODEL_ELEMENT 2
typedef struct {
unsigned int model;
const char *device_id;
} openawair_device_config_t;
#endif
Sources: firmware/include/firmware_config.h:1-12, firmware/src/main.c:3-10
Telemetry Data Model
The hardware capabilities are mapped to the following technical data structures for telemetry and host integration:
| Field | Type | Description |
|---|---|---|
temperatureC | number | Temperature in Celsius |
humidityPercent | number | Relative humidity % |
vocPpb | number | Volatile Organic Compounds (ppb) |
pm25UgM3 | number | Particulate Matter 2.5 (µg/m³) |
co2Ppm | number | Carbon Dioxide (ppm) |
motionDetected | boolean | PIR sensor status (Glow C only) |
ambientLightLux | number | Light level (Element only) |
Sources: host/src/shared/telemetry.ts:1-20
Summary
The OpenAwair project leverages the STM32F412-based Laird Sterling-EWB module found in both Glow C and Element hardware. While the core processing and wireless capabilities are identical, the project implements a modular driver system to handle the unique sensor payloads (I²C and UART) and physical actuators (relays and LEDs) of each target device.