OPENTOFLIDAR: A SCANNING LASER RANGEFINDER BUILT FROM SCRATCH FOR ABOUT 94 DOLLARS IN PARTS
A 2D scanning lidar with no rangefinder module hidden inside — the laser driver, timing electronics and analogue front end are all open hardware, and it maps a room well enough for SLAM.
by Ilia Sam
RoboticsOpen-hardware
Built withSTM32
- difficulty
- ●●●●●
- time
- several weekends
- license
- MIT
- repo
- repo ACTIVE870 stars
●●●●● · several weekends · MIT · 870 stars · repo ACTIVE
WHAT YOU’LL NEED
Jump to section
COMPAREE VERDICT
This is not a weekend project where you assemble a module someone else designed. It is a ground-up time-of-flight rangefinder where you solder the laser driver, the avalanche photodiode receiver, and the sub-nanosecond timing circuit yourself, then spend an afternoon calibrating the distance lookup table. The electronics are advanced — you are working with 20-nanosecond laser pulses and trying to resolve echoes to within 90 picoseconds — but the schematics and firmware are published, and the author characterised the performance in detail, so you are not guessing. Fifteen scans per second out to about 25 metres against a white wall, with resolution around 1 percent of distance but never better than plus or minus 2 cm. The author published Hector SLAM maps built with it, so it is good enough to navigate a robot around a flat. The one thing most likely to go wrong is the analogue receiver chain: if the avalanche photodiode bias or the TIA gain is slightly off, weak echoes disappear and your range drops to a few metres instead of twenty-five. You will spend time with an oscilloscope. If you want a lidar to use, buy one. If you want to understand how one works at the transistor level, this is the repository.
IN THE REPO
GOOD TO KNOW
- —Full Altium schematics, PCB layouts and ready Gerbers for the single main board (laser driver, receiver front end, timing and motor driver), plus PDF schematics.
- —STM32 firmware and a documented protocol for reading scans over serial.
- —Mechanical assembly drawings and a full spreadsheet BOM (LidarTotalBOM.xlsx, about 99 dollars in components without delivery; the README quotes about 94 dollars as of 2020, and prices will have moved).
- —Project wiki with assembly notes, calibration procedure and performance characterisation.
- —MIT licence — fully open for commercial use.
- —No custom optics: the transmit and receive lenses are standard surveillance camera parts you order by part number.
Parts to buy
7 itemsFrom our check of the build. Exact quantities and part numbers are in the creator’s BOM.
Can I build this?
Build at your own risk. Projects involve tools, electronics and sometimes mains voltage — follow the creator’s safety notes.
Videos
OpenTOFLidar demonstration
Author's own demonstration video showing live scans and the SLAM map output. No assembly walkthrough.
More builds like this
All projectsGallery
Start here
Navigation into the creator’s own docs — we don’t rewrite the guide, we route you to the source.
- 1.Read the project wiki (Start with the TDC data processing and Laser Safety pages — they explain how the timing is measured and how to handle the 905 nm laser.)
- 2.Check the BOM and order parts(The spreadsheet lists every component with supplier part numbers. Prices are from 2020, so verify availability and expect the total to be higher today.)
- 3.Fabricate the PCBs (Gerbers and Altium files are in the PCB folder; use v4 (better documented, integrated motor driver). It is a multilayer board with an internal ground plane, and the receiver has tight analogue layout — follow the author's design exactly.)
- 4.Assemble and calibrate the receiver (Follow the author's step-by-step assembly order and check each stage on the oscilloscope; the APD bias and TIA are the sensitive part.)
Resources
Documentation, files and community threads for this build — we link straight to the original sources and never rehost the creator’s files.
KNOWN ISSUES
- The avalanche photodiode is the single most common failure point. If the bias voltage is wrong or the TIA gain drifts, weak echoes vanish and your maximum range drops to a few metres. Expect to spend time with the oscilloscope tuning it.
- The 94-dollar component cost is the author's 2020 figure without delivery. Laser diode, APD and other prices have moved since, so re-price the BOM spreadsheet and check availability before ordering PCBs.
- No assembly video exists. The wiki has notes and the schematics are clear, but if you have never built a fast analogue receiver before, you are learning on this project.
- The walk-error calibration needs a series of measurements at one fixed distance with varying signal strength, fitted in the author's LidarTestingUtility. If you skip it or rush it, distance readings will drift with target brightness.
- 905 nm laser light is invisible and a genuine eye hazard. The author insists on IR-blocking protection glasses whenever the unit runs in non-scanning test mode; never point it at people or reflective surfaces.
- The scanning arc is about 230 degrees, not a full 360. The mechanical design can be modified to widen it, but that is additional work not covered in the repository.
Can I use a different laser diode or photodiode?
Possibly, but the receiver circuit is tuned for the specified avalanche photodiode's capacitance and the laser driver for the SPL PL90_3's pulse characteristics. Swapping either will require recalculating component values and recalibrating the distance table.
How does this compare to a Neato lidar or a Slamtec RPLidar?
The author does not benchmark it against commercial units. On paper it scans 15 times per second, reaches about 25 m on a white surface and covers about 230 degrees rather than a full circle. Commercial hobby lidars are cheaper and easier, but closed; this project is fully open and teaches you how time-of-flight works at the circuit level.
Is the SLAM performance good enough for a robot vacuum?
The author published Hector SLAM maps, so it is good enough to map a flat and localise a robot. Whether it is good enough for obstacle avoidance depends on your algorithm — the 2 cm resolution is coarse for tight spaces.
What is the power consumption?
About 0.1 A at 5 V, so half a watt in operation. Low enough to run from a small battery on a mobile robot.
Community builds
No community builds yet — be the first, we feature the best ones.
Discussion1
FROM THE COMPAREE TEAM
The README lists the component cost at about 94 dollars, but that figure is from 2020 — laser diodes and avalanche photodiodes have moved in price since then. What would you actually expect to pay for the full BOM today?
Ilia Sam
Ilia Sam designed OpenTOFLidar as a fully open alternative to commercial 2D scanning lidars, with no off-the-shelf rangefinder module hidden inside. The project was published in 2020 and remains one of the few DIY lidars where the laser driver, receiver and timing electronics are all open hardware.
DISCLAIMER
- Comparee is not the author of the projects featured here. All rights to each project belong to its creator — every page links to the original source, and we never host creators’ files.
- Information is provided without warranty and may become outdated as projects evolve. Prices are indicative bands only — always check the creator’s parts list for current costs.
- Building and operating any project is at your own responsibility. Protective equipment, safe workshop practice and compliance with local regulations are the builder’s responsibility.
CompareeTEAM1mo agoedited
Practical notes from our verification: the repository has Altium projects with Gerbers and PDF schematics, firmware, a PC test utility and a full BOM spreadsheet, and the wiki covers electronics assembly notes, TDC data processing, walk-error calibration and laser safety. There is no step-by-step video walkthrough; the demonstration video shows the lidar running. The README puts the component cost at about 94 dollars without delivery, explicitly as of 2020, so treat it as a historical baseline rather than today's price. A single board carries the microcontroller, the time-to-digital converter, the laser driver, the avalanche photodiode receiver and the motor driver, so this is fine-pitch, multi-layer electronics work. The step that needs the most care after assembly is calibration: the wiki describes a walk-error calibration you have to run before the distance readings are trustworthy. The README quotes a maximum range of about 25 metres on a white surface. Correction (4 October 2026): we re-checked this page line by line against the project's own repository, documentation and videos, and fixed errors in earlier versions.