ES-38ESP32AdvancedPremium

ESP32 Parking Sensor (HC-SR04 + 5-LED Bar + Buzzer + OLED)

The ESP32 version of a car parking sensor! The HC-SR04 ultrasonic sensor measures the distance to the object in front. As it gets closer, a 5-LED bar fills up (green → yellow → red) and the buzzer beeps faster. Very close (under 10 cm), a continuous alarm sounds and all LEDs light up. The SSD1306 OLED display shows the live distance in cm in large text, plus a status message.

0.0(0)
14 completed
ESP32 Parking Sensor (HC-SR04 + 5-LED Bar + Buzzer + OLED)
You build a car's parking sensor yourself with an ESP32. The HC-SR04 sensor measures how far away the obstacle in front of it is; once it comes within a metre, the five-LED light bar starts to fill, the buzzer beeps slowly and the beeps speed up as it gets closer. The OLED screen shows the distance in centimetres along with warnings such as 'near' and 'stop', and below 10 centimetres the alarm never stops.

Source Code

Premium Content

The source code, block version and FAQ of this project are open to Premium members.

  • All Project Code
  • Block version
  • Frequently Asked Questions