Ultrasonic Sensor
Measure distance without eyes
The rover is heading for a wall. Watch the sound waves the sensor sends and the distance it measures, and brake the moment it enters the safe zone. The speed goes up over 5 rounds; in the last two rounds the marks on the track disappear too, so you can only trust the sensor.
An ultrasonic sensor sends out sound waves like a bat and measures how long they take to come back. That’s how it knows how many cm away the object in front is. Parking sensors in cars, fill-level meters in smart trash cans and wall detection in robot vacuums all work this way.
HC-SR04: the most popular ultrasonic sensor for learning. It measures distances from 2 to 400 cm with ±3 mm precision.
Faster beeps mean the wall is getting closer; real parking sensors work the same way. In the dark rounds, keep your eye on the cm value on the sensor screen.