Context and objective
This IoT project implements an aquatic monitoring system around an ESP32. It measures water temperature in real time with a DS18B20 and water level with an HC-SR04 ultrasonic sensor, then presents both readings locally.
Architecture
The DS18B20 communicates with the ESP32 over OneWire. The HC-SR04 uses two GPIO pins for Trigger and Echo, while a 16×2 LCD connects through I2C using SDA and SCL. The Arduino program centralizes acquisition and sends values to both the LCD and serial monitor. The complete assembly is represented in Wokwi.
Implementation
The code uses the OneWire, DallasTemperature and LiquidCrystal_I2C libraries. Wiring is described in diagram.json, dependencies in libraries.txt, and simulation settings in wokwi-project.txt. Wokwi is used to validate integration of both sensors and the display before physical deployment.
Results and deliverables
The system displays temperature and level readings simultaneously on the LCD and serial monitor. Deliverables include sketch.ino, the Wokwi wiring diagram, configuration and library files, and the complete project report.
Lessons learned
The project demonstrates how to integrate different protocols on one microcontroller, turn an ultrasonic reading into usable level information, and validate embedded wiring and software through simulation before building the physical device.