LD06 LiDAR Integration with PX4 - Possible?

Hi PX4 community,

Quick question about sensor compatibility: Has anyone successfully integrated an LD06 LiDAR sensor with PX4 firmware?

I know this sensor works with ArduPilot out of the box, but I’d prefer to stick with PX4 if possible. I attempted switching to ArduPilot on my HolyBro X500V2 + Pixhawk 6X setup, but ran into configuration issues (drone tipped over during takeoff attempt - likely parameter/tuning related).

Before diving deeper into ArduPilot troubleshooting, wanted to check if there’s a PX4 path for the LD06. I’ve seen some discussion about generic UART rangefinders, but nothing specific to this sensor.

Any experience or pointers would be appreciated!

Setup:

  • HolyBro X500V2

  • Pixhawk 6X

  • PX4 latest stable

Thanks!

Hi,
Thanks for your interest in using PX4. I think we do not have the support for LD Lidar. Contributions are welcome ofc always if you could make it work.

Hi @farhang, thanks for confirming! I’d be interested in potentially porting the existing ArduPilot LD06 implementation to PX4. Could you point me in the right direction regarding:

  • Which PX4 repo/directories to look at for rangefinder/lidar drivers?
  • Any documentation on the driver development process?

Are there similar UART-based rangefinder drivers I could use as reference?
I’m fairly new to PX4 driver development, so any guidance on the general approach would be helpful before I dive into the ArduPilot code.
Thanks!

Sure,
We do not have any 360 range finder support as far as I know now.
I would say you start from here:

Just you might see how one of these sensros are implemented and follow it for LD06 depending on how you want to handle it.

Right now PX4 is handling similar sensors via ROS2 over companion computer:

Reviving an old thread. While I plan to eventually implement native 360° range finder support in PX4, I’m currently testing the ROS2/companion computer approach with a Raspberry Pi 5. Since ROS2 recommends Ubuntu LTS but I’m running Raspberry Pi OS, what is considered best practice in this case? My concern is whether Docker would introduce noticeable latency for collision prevention applications.

Additionally, I’m planning to combine the LD06 LiDAR data with a high-resolution Arducam for more robust obstacle avoidance. The camera would help with obstacle classification and detecting objects that LiDAR might miss (thin wires, tree branches, transparent surfaces, etc.).

Has anyone implemented a similar multi-sensor setup for collision prevention?