---
title: "Aranet"
description: "Rust libraries and tools for Aranet environmental sensors (CO2, temperature, humidity, radon, radiation) via Bluetooth Low Energy."
impact: "Full-stack sensor monitoring from BLE to dashboards, with offline storage and IoT integrations"
github_url: "https://github.com/cameronrye/aranet"
technologies: ["Rust", "BLE", "SQLite", "Tokio", "egui", "ratatui", "Prometheus"]
featured: true
order: 1
architecture: "flowchart TB\n    subgraph Sensors[\"Aranet Sensors\"]\n        A4[\"Aranet4<br/>CO2, Temp, Humidity\"]\n        ARn[\"AranetRn+<br/>Radon\"]\n        ARad[\"Aranet Radiation\"]\n    end\n    subgraph Core[\"aranet-core\"]\n        BLE[\"BLE Scanner\"]\n        Proto[\"Protocol Parser\"]\n    end\n    subgraph Store[\"aranet-store\"]\n        DB[(\"SQLite<br/>Local Storage\")]\n    end\n    subgraph Interfaces[\"User Interfaces\"]\n        CLI[\"aranet-cli\"]\n        TUI[\"aranet-tui<br/>Terminal Dashboard\"]\n        GUI[\"aranet-gui<br/>Desktop App\"]\n    end\n    subgraph Service[\"aranet-service\"]\n        REST[\"REST API\"]\n        WS[\"WebSocket\"]\n        MQTT[\"MQTT Publisher\"]\n        Prom[\"Prometheus Metrics\"]\n    end\n    Sensors -->|\"BLE Advertisements\"| BLE\n    BLE --> Proto\n    Proto --> DB\n    DB --> CLI\n    DB --> TUI\n    DB --> GUI\n    DB --> REST\n    REST --> WS\n    REST --> Prom\n    REST --> MQTT\n"
problem: "Aranet environmental sensors produce valuable air quality data, but the official tooling is limited to mobile apps with no automation, no local storage, and no integration path for monitoring infrastructure. Researchers, home automation enthusiasts, and air quality-conscious developers need programmatic access to sensor readings, historical data, and alerting without depending on cloud services or closed ecosystems."
solution: "Built a Rust workspace of seven crates spanning the full stack: a core BLE library for direct sensor communication, local SQLite persistence with incremental sync, a CLI with scan/read/history commands, a terminal dashboard with sparkline charts and threshold alerts, a desktop GUI, and a background service exposing a REST API with WebSocket streaming, Prometheus metrics, MQTT publishing, and webhook notifications."
results: ["Cross-platform support for macOS, Linux, and Windows", "Multi-sensor coverage: Aranet4, Aranet2, AranetRn+, and Aranet Radiation", "Passive BLE monitoring without requiring device connections", "Published to crates.io and Homebrew for easy installation"]
metrics: [{"label":"Crates","value":"7"}, {"label":"Sensors","value":"4 devices"}, {"label":"Interfaces","value":"CLI, TUI, GUI, API"}, {"label":"Integrations","value":"Prometheus, MQTT, InfluxDB"}]
canonical_url: https://rye.dev/projects/aranet/
---

Aranet is a comprehensive Rust implementation for connecting to Aranet environmental sensors via Bluetooth Low Energy. The workspace provides everything from low-level BLE communication to polished user interfaces and production monitoring integrations.

## Key Features

- **Multi-sensor support**: CO2, temperature, pressure, humidity, radon, and radiation readings from four Aranet device families
- **Historical data download**: Resumable checkpoints, date filters, and incremental sync with local SQLite storage
- **Passive monitoring**: Read BLE advertisements without establishing a device connection
- **Terminal dashboard**: Sparkline charts, CO2/radon threshold alerts, vim keybindings, and CSV export via ratatui
- **Desktop GUI**: Multi-panel egui interface with alert system and system tray
- **Background service**: REST API with WebSocket streaming for real-time data
- **Observability**: Prometheus metrics endpoint with pre-built Grafana dashboard template
- **IoT integration**: MQTT publisher with Home Assistant auto-discovery, InfluxDB export, webhook notifications

## Why Rust

Environmental monitoring runs continuously on modest hardware. Rust's zero-cost abstractions and memory safety make it the right choice for a long-running BLE daemon that needs to be reliable without consuming resources. The workspace structure keeps each concern in its own crate while sharing the core protocol implementation across every interface.

## Architecture decisions

The seven-crate workspace follows a clear layering:

- **aranet-types** provides platform-agnostic shared types
- **aranet-core** handles all BLE communication and protocol parsing
- **aranet-store** manages local SQLite persistence with deduplication and incremental sync
- **aranet-service** adds the daemon layer with REST, WebSocket, MQTT, Prometheus, and webhook integrations
- **aranet-cli**, **aranet-tui**, and **aranet-gui** are thin interfaces over the core and store crates

This separation means adding a new integration or interface requires no changes to the sensor communication layer.

## Distribution

The project ships via multiple channels to minimize friction:

- **Homebrew**: `brew tap cameronrye/aranet && brew install aranet`
- **crates.io**: `cargo install aranet-cli`
- **GitHub Releases**: Shell and PowerShell installers, macOS DMG bundles
- **Docker Compose**: Pre-configured stack with Prometheus and Grafana

## Outcome

Aranet proves that embedded sensor tooling does not need to be locked behind mobile apps or cloud services. By building from BLE packets up through storage, APIs, and dashboards in a single Rust workspace, the project gives users full control over their environmental data with the reliability and performance characteristics that monitoring infrastructure demands.