AAQR — Autonomous Air Quality Rover
A robot that drives a route on its own, stops at each waypoint, and measures the air. It combines ROS 2 navigation with a distributed sensor pipeline on Raspberry Pi hardware, mounted on a Roomba chassis. Built in 2023–24 across two repos, now one documented project.
how it works
- Record a route. Drive the robot to each location and save its pose with a keypress. Poses are written to a YAML file per map.
- Navigate. Nav2 drives the robot through the saved waypoints in order.
- Pause and sample. At every waypoint the robot waits 5 seconds while the onboard sensor node reads the air.
- Stream. Readings go over HTTP as JSON to a Flask server on a second Raspberry Pi.
- Store and correlate. The server saves everything to a timestamped SQLite database and ties readings to the robot's physical position.
three components
navigation/
ROS 2 package on a TurtleBot4: a waypoint recorder, an autonomous navigator, and a TF2 listener that publishes the robot's position.
sensor/
A script on a Raspberry Pi Zero that reads every Enviro+ sensor, shows values on an LCD, and POSTs JSON to the server.
server/
A Flask app on a Raspberry Pi 4 that receives readings, stores them in SQLite, and serves a live dashboard.
what it measures
| Sensor | Measurement |
|---|---|
| BME280 | Temperature, pressure, humidity |
| PMS5003 | Particulate matter: PM1, PM2.5, PM10 |
| Enviro+ gas | Oxidising, reducing and NH3 compounds |
| LTR559 | Proximity and ambient light |
| ST7735 LCD | Live readout on the robot |
server api
| Endpoint | Purpose |
|---|---|
| POST /send-data | Receives sensor JSON from the Pi Zero |
| GET /data | Last 5 minutes of readings as JSON |
| GET /view-live-data | Live sensor dashboard |
| GET /view-timestamp-data | Sensor averages per waypoint |
| GET /health | Server health check |
waypoint file
Saved poses are plain YAML, so a route is easy to read, edit and version.
1: position: {x: 1.23, y: 4.56, z: 0.0} orientation: {x: 0.0, y: 0.0, z: 0.707, w: 0.707} 2: position: {x: 2.10, y: 1.80, z: 0.0} orientation: {x: 0.0, y: 0.0, z: 0.0, w: 1.0}