How to build a laser range finder

Why use an ordinary measuring tape when you can measure things with a laser? If there is ever an opportunity to incorporate lasers in everyday activities, we must take it. Here, Hesam Moshiri shows you how to build your own laser ranger finder using our RP2040 chip.

How to build a laser range finder

Hardware

  • Waveshare RP2040-Zero board
  • Time-of-flight (ToF) distance sensor
  • 2.4″ TFT display

These all talk to each other thanks to a custom PCB designed in Altium Designer 23.

How to build a laser range finder
A closer look at the RP2040-Zero
(image from waveshare.com)

Time of flight

Don’t worry, I also had to look that up. Time-of-flight (ToF) sensors are the kind you would use if you wanted an automatic tap to turn on when someone’s hand is waved in front of it, or if you wanted to teach a robot to detect obstacles.

How to build a laser range finder
This is the VL53L0X time-of-
flight sensor that Hesham used

ToF sensors work in a similar way to a bat’s sonar system. They both measure the length of time it takes for energy to travel a distance. In this instance, the sensor measures the length of time it takes laser light to travel between the sensor and the object it is pointed at and back again. You may have seen builders or estate agents using them to take absolutely perfect measurements of room sizes.

How does it work?

The RP2040-Zero communicates with the ToF sensor via I2C. The sensor measures the distance between itself and the nearest object in front of it, and relays that measurement back to the RP2040-Zero, which then throws the number up on the LCD screen. It works best with solid objects like walls, and you’ll get some light fluctuation if you try to measure soft things like clothing or plants.

How to build a laser range finder

The custom PCB is also equipped with a relay and a buzzer. You could code your range finder to sound the buzzer when the measurement is within certain parameters. And you could use the relay to automatically activate and turn something on or off when an object gets close to the sensor or moves away from it. That’s how the automatic taps in fancy bathrooms work.

Build your own!

How to build a laser range finder

There is tons more information on Hesam’s excellent project page. If you’re interested in building your own ToF sensor range finder, you’ll find full specs here, including schematics and the PCB layout. You’ll need to register for an Altium account if you want to download the source code. Scroll to the bottom of this page and you’ll find a link to do that, just above the list of references. Also, go and subscribe to Hesam’s YouTube channel. We like him.

Print Friendly, PDF & Email

Leave a Comment

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

Server Status

Aradippou Chat 1 Chat 2 Larnaca Limassol Nicosia

Chat Links

Official Links.

1. Chat 1.
2. Chat 2.

Alternative Mirror Links.

1. KiwiIRC 1.
2. KiwiIRC 2.

Other Web Clients.

1. IrcCloud.

Recent Posts

Related Posts:

Advertisement

Archives

Super Club Radio

Mighty Deals

CyIRC

CyIRC Tweets

Scroll Up
Fatal error: Uncaught WMAC\JSMin_UnterminatedStringException: WMAC\JSMin: Unterminated String at byte 1180: "+o.accessToken}}).then(e=>{if(!e.ok)throw e;return e});return a.catch(e=>{console.error(`Failed to logout chatrix session. deviceId: ${o.deviceId}`)}),a}})(); in /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php:215 Stack trace: #0 /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php(157): WMAC\JSMin->action(2) #1 /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php(96): WMAC\JSMin->min() #2 /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/class-main.php(375): WMAC\JSMin::minify('(function(){"us...') #3 /home/bszucbfe/public_html/wp-includes/class-wp-hook.php(310): WMAC_PluginMain->jsSnippetcacher('(function(){"us...', '/home/bszucbfe/...') #4 /home/bszucbfe/public_h in /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php on line 215