DIY 360 degree realtime outdoor LIDAR

This project describes step-by-step how you can build yourself a 360 degree Lidar for realtime outdoor mapping and position tracking on that map (aka ‘localization‘). This idea is also called ‘SLAM’ (simultaneous localization and mapping). We use inexpensive parts for this Lidar, so this is probably the cheapest 360 degree realtime Lidar you can build!

Features:

360 degree, realtime operation (important: world ground must be flat – for a 3D world, see section at the page bottom)

sensor: LidarLight v2 (500 Hz measurements, approx. 1cm precision)

field of view (horizontal): 360 degree

range: 40m, indoor & outdoor

rotation speed: 1-10 Hz (can be adjusted by potentiometer)

diameter: 60 mm

3d printed chassis (so you need access to an 3d printer)

Parts needed:
Note: all parts will be available as a DIY kit in this shop soon.

encoder ring (3D print), layer height: 0.1mm
The encoder ring has 15 pits, one pit is shorter and allows to detect zero position. Each pit triggers a voltage transition (0/1/0/1/0/1 etc.) in the light barrier, indicating the next 12 degree step. Using a timer, the degree steps in between (0-12 degree) can be computed.

motor ring (3D print), layer height: 0.1mm

disc base (3D print), layer height: 0.3mm

disc lidar holder (3D print)
to be continued…(your ideas?)

disc cover (3D print)
to be continued…(your ideas?)

Assembling:
1. Stick encoder ring and bearing base together:

2. Add both to base plate (hot-glue at underside):

3. Make sure that your bearing runs smoothly (can make one rotation after driving it with one finger). My bearing had too much grease inside, so I had to disassemble the bearing and remove the grease. Assemble bearing, motor and wheel. The motor should run clock-wise when connected to +5V and GND. If not, swap the connector wires.

6. Wire as shown below:
Note: Keep soldering time for the photomicrosensor short (max. 3 seconds), otherwise you risk to damage this sensitive component.

7. Test mechanics
Make sure that the disc can turn with a constant speed (and not erratic). If the speed is not constant, the lidar will not work properly. My 3d printed parts were not very precise, so I had to rasp all parts so they fit and and do not rub.

8. Flash Arduino code
Since we are using the serial/USB converter for flashing the Arduino, resetting the Arduino automatically will not work. Press ‘Upload’ in the Arduino IDE and then press the RESET button on the Arduino to initiate the code upload.

Could this Lidar work in a 3D world (with sloped ground)? Well, by operating the 2D lidar in a vertical orientation. Then we get a 2D stripe of the world (including the current position on that 2D stripe) that we could use for mapping and localization – A compass would help us to estimate the orientation of new stripes (blue stripe).

12 thoughts on “DIY 360 degree realtime outdoor LIDAR”

Very nice work. I look forward to seeing if you can successfully use this as a real-time navigation tool. I was unable to get mine to work properly, as even at 300 Hz I was unable to make steering adjustments quickly enough to keep my robot from running into walls 🙁

Thanks ! 🙂
One more question, is there any specific resoning behind having the arduino on the spinning disc ? Would having the arduino beneath the disc, connected to the LIDAR through the slipring work as well ?

Hello, I just wanted to save one wire for the slip ring, so (TX,RX) when Arduino on top instead of (SCL,SDA,ENC) needed for Arduino beneath the disc. It should work beneath as well (although I haven’t tested this). Regards, Alexander

1) I don’t have one – I hope it’s not too difficult to read the fritzy…
2) The PMDC motor takes 170 mA load – yes, runs on USB
3) The 5V is coming from the USB TTL adapter (VCC) and going to the Arduino 5V pin, max current 200mA

I am working on a similar project. I also use a ir distance sensor. According to the datasheet I can get a sampling rate of about 20hZ.
So I was wondering what sensor you used to get that sample rate, and what is your fastest sample rate?

The LidarLite IR sensor has a sample rate of 1000 Hz. For different rotation rates, you get different samples per rotation (I could run them all):
rotation rate 10 Hz => 100 samples per rotation
rotation rate 5 Hz => 200 samples per rotation
rotation rate 1 Hz => 1000 samples per rotation
The lower the rotation rate, the less suitable for realtime applications. The higher the rotation rate, the lower the resolution. Using 2-5 Hz, I did get good results.