A personal air quality monitoring system that provides real-time environmental data through IoT sensors and cloud visualization.
Aeroscan is an open-source air quality monitoring system powered by an ESP32 microcontroller. It measures PM2.5, PM1.0, and PM10 particulate matter levels using a PMS7003 sensor, along with temperature and humidity data from a DHT22 sensor. The system calculates the Air Quality Index (AQI) based on US EPA standards and streams real-time data to a cloud endpoint for visualization and analysis.
This is a lightweight, breadboard prototype designed for experimentation with IoT, environmental sensing, and data analytics — no production overhead, just pure functionality.
The Aeroscan ecosystem consists of four main components:
Next.js-based web application for data visualization and system management.
Real-time data streaming and client communication.
- Repository: aeroscan-ws
Custom protocol for ESP32-to-cloud data transmission.
- Repository: aeroscan-protocol
Microcontroller code for sensor data collection and processing.
- Repository: aeroscan-esp32
- Real-time Air Quality Monitoring: Live PM2.5, PM1.0, and PM10 measurements
- Environmental Sensing: Temperature and humidity tracking via DHT22
- AQI Calculation: Automatic Air Quality Index computation using US EPA standards
- Live Data Visualization: Interactive charts and real-time dashboards
- Cloud Integration: Seamless data uploading and storage
- IoT Connectivity: Wi-Fi enabled ESP32 for wireless data transmission
- Open Source: Fully open prototype for experimentation and learning
- ESP32 microcontroller (Wi-Fi enabled)
- PMS7003 particulate matter sensor
- DHT22 temperature and humidity sensor
- Breadboard and jumper wires
- Power supply (USB or external)
- PMS7003: Measures PM1.0, PM2.5, and PM10 with ±10µg/m³ accuracy
- DHT22: Temperature range -40°C to 80°C, humidity 0-100% RH
- Next.js 15+ - React framework with App Router
- TypeScript - Type-safe development
- Tailwind CSS - Utility-first styling
- @tremor/react - Data visualization
- WebSocket Client - Real-time data consumption
- WebSocket Server - Real-time data streaming
- Custom Protocol - ESP32 communication
- Cloud Storage - Data persistence and analytics
git clone https://github.com/priyanshpatel18/aeroscan.git
cd aeroscannpm install
# or
yarn install
# or
pnpm installCreate a .env.local file:
DATABASE_URL = "postgresql://postgres:postgres@localhost:5432/aeroscan?schema=public"
NEXT_PUBLIC_WS_URL = ws://localhost:5555npm run dev
# or
yarn dev
# or
pnpm devOpen http://localhost:3000 to view the dashboard.
| Repository | Description | Technology |
|---|---|---|
| aeroscan-ws | WebSocket server for real-time data streaming | Node.js, WebSocket |
| aeroscan-protocol | Communication protocol for ESP32-cloud data transmission | Custom Protocol |
| aeroscan-esp32 | ESP32 firmware for sensor data collection | C++, Arduino IDE |
The system implements US EPA Air Quality Index standards:
| AQI Range | Air Quality | PM2.5 (µg/m³) | Health Impact |
|---|---|---|---|
| 0-50 | Good | 0-12 | Minimal impact |
| 51-100 | Moderate | 12.1-35.4 | Acceptable for most |
| 101-150 | Unhealthy for Sensitive | 35.5-55.4 | Sensitive groups may experience symptoms |
| 151-200 | Unhealthy | 55.5-150.4 | Everyone may experience symptoms |
| 201-300 | Very Unhealthy | 150.5-250.4 | Health warnings |
| 301+ | Hazardous | 250.5+ | Emergency conditions |
aeroscan/
├── src/
│ ├── app/ # Next.js App Router pages
│ ├── components/ # React components
│ ├── lib/ # Utility functions
│ ├── hooks/ # Custom React hooks
│ └── types/ # TypeScript definitions
├── public/ # Static assets
└── docs/ # Documentation
- Set up and deploy the WebSocket server
- Configure your ESP32 with the firmware
- Ensure the communication protocol is properly implemented
npm run build
vercel --prodNEXT_PUBLIC_WS_URL=wss://your-websocket-server.com
DATABASE_URL=postgresql://postgres:postgres@localhost:5432/aeroscan?schema=public- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is open source and available under the MIT License.
- US EPA for AQI calculation standards
- PMS7003 and DHT22 sensor documentation
- ESP32 community and Arduino ecosystem