This is an old revision of the document!
Autor: Burciu Iustin Florian Email: iustin.burciu@stud.fiir.upb.ro Grupa: AAC
This project focuses on building an embedded system to monitor environmental comfort using the ESP32 development board, along with an LM35 temperature sensor and an MQ-4 gas sensor. It continuously evaluates environmental conditions and computes a comfort score based on temperature and gas readings.
The implementation was initially created as a local web server hosted directly on the ESP32, allowing real-time monitoring from any browser within the same Wi-Fi network. Later, a second version was developed using Firebase Realtime Database, enabling remote data access and logging in real time from anywhere in the world.
The project includes:
Used Components:
ESP32 Connections:
Component | ESP32 Pin | Description |
---|---|---|
LM35 VCC | 3.3V | Power supply |
LM35 GND | GND | Ground |
LM35 OUT | GPIO34 | Temperature signal |
MQ-4 VCC | VIN | Power supply (regulated) |
MQ-4 GND | GND | Ground |
MQ-4 A0 | GPIO32 | Gas level (analog) |
LED Blue | GPIO25 | Lights up at comfort score 100 |
LED Red | GPIO26 | Lights up if gas > 30 |
The designed system aims to monitor indoor environmental comfort by evaluating two essential parameters: temperature and gas concentration. These values are processed to calculate a comfort score ranging from 0 to 100, which reflects the overall air quality and thermal comfort.
The core functionalities of the system include:
This system provides continuous assessment of the indoor environment, with a user-friendly interface that enables real-time monitoring and alerts, both locally and remotely via cloud services.
In a separate sketch, the system can also:
1. Read Temperature and Gas:
```c float citesteTemperatura() {
int adc = analogRead(pinLM35); float voltaj = adc * (5.0 / 4095.0); return voltaj * 100.0;
}
int citesteGaz() {
return analogRead(pinMQ4);
}