I’m working on a research project at my University where I’m building a drone to fly indoors and carry a 3D Lidar Sensor. Currently I have the drone flying and I am trying to use a LeddarOne connected to the UART port on the Navio2 board for height data. I followed through the ArduPilot documentation for the sensor first.
In the file /etc/default/arducopter :
So far I have tried using:
-C /dev/ttyAMA0 115200
I have tried setting it to both Telem2 and Telem3.
In mission planner I have set the corresponding serial port type as 9 with 115 baud.
Every combination I have tried has given me the “Bad LIDAR Health” warning and the sonarrange value is always at 0.
I am fairly new to how serial communication works and sure that I am doing something simple wrong but not sure what it is.
May I ask you to describe the powering of the LiDAR?
I have the sensor powered though the 5V and GND on the UART port.
I will try to power it from the servo rail and see if that does it. I believe it draws somewhere around 250mA which is probably the issue as I’m pretty sure the Pi can’t supply that.
The Ardupilot docs provide this information: “Bad LiDAR Health” message is caused because the rangefinder isn’t enabled for landing. This is done through the
RNGFND_LANDING parameter and if the set you should see the message disappear.
Inside the Full Parameter List I was unable to find the value for RNGFND_LANDING.
I believe the RNGFND_LANDING is only used in Arduplane.
What software do you use?
RNGFND_LANDING is also used in Mission Planner.
I am using Mission Planner but even when I search it is not there. I’m wondering if it’s the EKF being set up to use the sensor.
May I ask you to clarify what do you mean by EKF?
Some users corresponded that powering the LiDAR on at the same time as the flight controller can lead to the message you are seeing. Try powering them with some delay.
Also, I can suggest to look up this section from Ardupilot docs describing your issue: Rangefinders (landing page).
I have tried powering them on separately with no success. Also, by EKF I mean the system that makes all the decisions as to what sensors to listen to. It stands for Extended Kalman Filter. The ardupilot documentation explains it much better.
Also, the link you provided points to the arduplane documentation and I believe that the RNGFND_LANDING does not apply to Copter as I cannot find it anywhere within Mission Planner.
May I ask you to check this Ardupilot guide? There is a list of parameters that Mission Planner needs for LeddarOne LiDAR.
These parameters are valid for Copter as well as for Planer.
I have switched to trying to use a Terabee TeraRanger Evo 60m I2C ToF sensor from robotshop. I have gone through all the steps to connect the sensor over I2C and I am so far unable to get it to work also. Will I need to use ROS in order to use external sensors? I have tried to avoid ROS as I have never used it and don’t have the time to get it figured out.
May I ask you to describe your current setup? This will help me to understand what can be wrong here. Also, the sensor powering might be important here, since some TeraRanger LiDARs should be powered before the flight controller.
A Terabee TeraRanger Evo sensor should work fine with Navio2 without using ROS.
I’d like to recommend checking the I2C wired connection. This guide might be helpful for you. You can find information about Navio2 Pinout here.
Thank you I was able to get the sensor working along with a PX4Flow sensor. The issue with the Lidar was the polling rate of the I2C in the Pi configuration.