A Speaking Ultrasonic Distance Sensor


[Klaus] wanted some sort of aid for parking his car, and after running across a $4 ultrasonic sensor, decided to build his own speaking distance sensor (.de, Google Translation).

Inside [Klaus]’ device is an Arduino Uno, an HC-SR04 ultrasonic distance sensor, and an Adafruit Wave Shield. Originally, this parking/distance sensor used a small TFT to display the distance to an object, but after a few revisions, [Klaus] redesigned the device to speak the current distance, courtesy of an SD card and a soothing female voice.

Right now, the voice is set up to speak the distance from an object to the sensor from 10 cm to 1 m in 5cm increments. This isn’t the limit of the sensor, though, and the device can be easily reconfigured to sense a distance up to four meters.

The board doesn’t have an amplifier or speaker, but with the addition of a small amplifier, [Klaus]’ device is loud enough to be heard in even the noisiest environments.

Video demo below.


19 thoughts on “A Speaking Ultrasonic Distance Sensor

  1. I have been “disappointed” with ultrasonic reverse warnings – ever since I [almost] ran over my wife.
    While reversing out of my garage, the warnings were tripped – as usual – by the proximity of the garage door frame. So – as usual – I ignored it and kept going. Unfortunately, my wife chose that exact moment to DUCK DOWN, behind the car, to pick up some errant piece of garbage. She is only alive because I glimpsed her moving forward: once she bent over, she was invisible from the driver’s position.
    We had words after that. And my next car will have a reversing CAMERA.

      1. No, genius, assigning blame is totally beside the point. The point here is that sensors aren’t useful if they’re ignored, and they’re ignored when the false positive rate is too high.

          1. Some people just can’t stand to see garbage rolling around. Maybe it’s OCD, I don’t know. As Blue Footed Booby pointed out, the point was: I was used to ignoring the false positives.
            Oh, and SUV’s mask a lot with their high rear windows.

    1. Something wrong with the sensors you were born with?

      I have always found the “reverse cam” and “reverse sensors” to be a pain in the ‘tox: I just make a point of paying attention, and driving the car without dependance on an AI system. Personally, I can’t stand how cars have evolved with the excess sensors, computers and gadgets in them: it’s no wonder they’re so damned expensive.

  2. Buy arduino, buy sound shield, buy distance sensor shield, plug into each other, burn example code, stuff components inside box.

    Not only is this not a hack but he might as well have just bought a proper $15 reversing sensor kit off eBay. He’d have got 3-4 sensors and a little LED/beep display to be placed on his dash.

    1. I had the same volume problem. Apart from this hack i matched the speaker the best i could. Apart from the ohms i matched the watts. If the watt output is close to the maximum watt rating of the speaker, the speaker will work more efficient. I dont know the theory, but this is what i found out through testing. Another way to improve volume is the case. Mount your speakers in a sturdy case in a non flexible way. This way the case will work better as a sound box.

    2. They are using an opamp limited to 80mA drive for line level output
      instead of an amplifier designed for a speaker e.g. LM386.

      So the output drive current is limited to 80mA ^2 * 8ohms = 50mW. You
      might get higher power by using a high impedance speaker e.g. 32 ohms

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.