LiDAR related issue in a Heli -Banewake TF02

Hi,

I installed a Benewake TF02 to experiment with Train Following. All the parameters are set as recommended in the TF02 manual and all worked well on the bench.

At the test flight all was not well. In Loiter mode if the altitude exceeded the TF02 outdoor range (5 meters in my case) I would get a “Bad LiDAR Health” message and immediately lose GPS and Compass (EFK error) which caused a EKF Fail Safe - AltHold. Had to switch to Acro or Stabilize and land. Tried this several times with exact same result.

It seems like there is a problem when the system has to switch from Range Finder altitude reading to Barometer.

I would appreciate if our experts here could help me with this issues since as is, this LiDAR unit cannot be used.

My heli is a Trex 700/800 Gasser with Pixhawk 2.1- V3.5.7 flying well in all Flight Modes.

All the LiDAR related parameters that I changed are;
Serial2Baud = 115 (Telemetry 2)
Serial2Protocal = 9 (Lidar)
RNGFND_GNDCLEAR=13
RNGFND_MAX_CM=500 (above 6 meters I get a “bad Lidar Health” msg
RNGFND_MIN_CM=5
RNGFND_SCALING=1
RNGFND_TYPE=8 (according to manual)
RNGFND_PWRNG=10
EK2_ALT_SOURCE=1
EK2_RNG_USE_HGT=50
EK2_RNG_SPD=6
TERRAIN_ENABLE=1
TERRAIN_FOLLOW=1
WPNAV_RFND_USE=1

links to two of the bin files;
https://drive.google.com/open?id=17CHWvWTricrB_gUmgiav1WYVHPmumiAJ
https://drive.google.com/open?id=1qCfOOxnXH0zSjvTjFgVynF50O5hGiTTm

I’m having a similar issue with TF02. The sensor is properly configured but reporting extremely unreliable ranging despite being used under 10m. Unsure whether the sensor performance is terrible or perhaps the driver needs work?

I’ve tested outdoor, over grass and concrete surfaces. I get nothing but persistent “bad lidar health” messages and unusable ranging.

Hi,

Good to know that it is not only me.
Which platform do you have the TF02 installed in?
Do you also get a EKF error right after “bad lidar health” message and lose GPS and Compass and consequently “EKF Fail Safe”?

I know this is an old issue but I thought I’d add some comments because I’ve been working on the Benewake driver for Copter-3.6.

So the first and perhaps most important thing is that when attempting terrain following the EK2_ALT_SOURCE should not be set to 1 (for RangeFinder), instead it should be left at the default which is 0 (for barometer).

Similarly the EK2_RNG_USE_HGT should be left at the default of -1.

As a side note, I find it strange that a significant number of users continue set the EK2_ALT_SOURCE parameter to “1”. As far as I know the only documentation we have on this parameter says that it should not be used for terrain following so if anyone knows why people are going astray I’d love to understand this so we can protect against it.

Hi rmackay9,

Thanks for taking the time and helping me with this issue.

After a “flyaway” that I had, decided to disconnect the TF02 and wait for the release of Copter 3.6 which has a driver for Benewake.

I will set the mentioned EK2 parameters to your recommendation values and test after upgrading to 3.6. It will be in about 2 weeks as I am away from home, and report back.

For me it was the description in “EK2_RNG_USE_HGT”, especially the last sentence that said “Set to -1 to prevent range finder use”. I thought, well I do want the use of the range finder so I have to set this parameter to a safe % of RNGFND_MAX_CM.
For EK2_ALT_SOURCE it was the "Option " that mentioned “1:Use Range Finder” and obviously I was incorrect in changing both parameters.

I do have one question. What happens say in Loiter mode, if I start a climb and exceed the Range Finder max distance limit. Does the system switch to barometer and continue safely to climb unit I stop the climb?

@Nadman1,

Re the last question, yes. When it detects that the range finder is outside it’s range it switches to use the barometer. One key thing to be careful of though is that the RNGFND_MAX_CM is set correctly. This tells AP what the maximum range of the range finder is.

rmackay9,

Thanks for making that clear.
I will make sure to set RNGFND_MAX_CM to below 10 meters for TF02 as I fly outdoors.

cheers,

Hi rmackay9

I just updated my FW to the new version “3.6.3” so to be able to select the TF02 as RNG… Type (19) and test it. However, I now get the message BAD LiDAR Health. When I switch RNG… Type back to Light Ware Serial (8) correct altitude is displayed and no error message.
Is there an issue with the driver for the Heli version of the FW?

regards,

Nader,

That sounds like the TF02 has been configured to output the lightware serial protocol instead of the benewake protocol. So an issue with the setup of the lidar itself. I’m unsure how to use the benewake configuration tool to change the protocol that the lidar uses I’m afraid…

rmackay9,

Thanks for your reply.
I checked the TF02 configuration software and there is no option were we can select which protocol to use. May be there is a special device command for doing this. I will contact Benewake and ask.

o.k. found out that we need to uncheck the “PIX MODE” in the TF02 setup software and then we can select RNG_TYPE as “19”.