This project is an ultrasonic-based radar system using an ESP32 running FreeRTOS to manage tasks and interrupts. A servo-mounted ultrasonic sensor scans the area in automatic or manual mode. An OLED screen shows mode and distance, while LED and buzzer alerts trigger on detection. Two modes and parameters can be setup using buttons and the OLED
Project Overview
This project presents an ESP32-based ultrasonic radar system combined with a real-time web visualization interface.
The system is divided into two main parts:
- A remote embedded device based on an ESP32, an ultrasonic sensor, and a servo motor for area scanning.
- A web-based visualization interface built with HTML, CSS, JavaScript, and Canvas to display radar data in real time.
The goal of this project is to demonstrate how low-cost embedded hardware can be combined with modern web technologies to build an interactive radar-style distance monitoring system.
System Architecture
1. Remote Device (ESP32 Radar Unit)
The remote device handles motion control, distance measurement, local user interaction, and data transmission.
Key features:
- ESP32 microcontroller (Wi‑Fi enabled)
- Ultrasonic distance sensor mounted on a 180° servo motor
- OLED display (128×64) for system status and configuration
- Local mode selection (automatic / manual) and settings display
- LED indicator and buzzer for target alert
- FreeRTOS-based task separation (measurement, display, control, communication)
- Developed using PlatformIO
The OLED screen allows the user to:
- View the current mode (AUTO / MANUAL)
- Display angle and measured distance
- Monitor detection status
- Easily configure the system without a PC
FreeRTOS is used to improve responsiveness and reliability by separating critical tasks such as:
- Sensor measurement
- Servo sweeping
- OLED refresh
- Alert handling
- Wi‑Fi communication
PlatformIO - project's structure
2. Web-Based Radar Visualization Interface
The second part of the project is a browser-based radar viewer used for real-time monitoring.
Technologies used:
- HTML / CSS
- JavaScript
- Canvas API
Main features:
- Radar-style polar grid
- Animated sweeping beam
- Real-time plotting of detected objects
- Display of angle, distance, and detection status
- Communication with the ESP32 over the local network
The interface receives angle–distance data from the ESP32 and renders them dynamically, providing a clear and intuitive radar visualization similar to real-world scanning systems.
How the System Works
- The ESP32 rotates the ultrasonic sensor using a servo motor.
- Distance measurements are taken at multiple angles.
- FreeRTOS tasks ensure smooth scanning, display updates, and communication.
- Data is sent over Wi‑Fi to the web interface.
- The browser-based viewer updates the radar visualization in real time.
Applications & Use Cases
- Embedded systems and FreeRTOS learning
- IoT and Wi‑Fi communication experiments
- Radar visualization and sensor fusion concepts
- Object detection and distance monitoring prototypes
Conclusion
This project combines real-time embedded control, local OLED-based configuration, and web-based visualization into a modular and extensible radar system.
The use of FreeRTOS improves scalability and system responsiveness, while the web interface offers a powerful and intuitive visualization layer.
Future extensions could include data logging, multi-target tracking, or mobile-friendly visualization.