Terrain Following with Rangefinder in Auto mode on 4.1b8 failure missing terrain data, rtl

First off all great job on b8! flew a 71 waypoint relative altitude auto mission flawlessly. Terrain_enable is set to 0 but fails on takeoff with missing terrain data. i want to do terrain following with rangefinder… log attached with params. please help!

log file: https://drive.google.com/file/d/1ZsvBc2GOP2e-9-TW5nV4Pnmkc8I8WDCa/view?usp=sharing

1 Like

I noticed the initial altitude was 20 ft and I read in an old post that if you’re doing a terrain missing you cannot go over the maximum rangefinder height, so I lowered to 16 ft even though the entire mission was at 10 ft except for the initial takeoff. I’d further introspected the lidar TF mini sensor it looked okay however there seemed to be new rngfnd value pairs that I don’t remember that were set. Additionally the sensor wasn’t acting normal it was kind of changing from like 19 or 20 to 5:00 to 7:00 just kind of all over the place when it was just sitting in place and when I lifted it off the ground it pretty much did the exact same thing so I know something funky is set there or the sensors broken which I don’t think is the case. Unfortunately I don’t know what the other settings are because the wiki on TF mini just basically tells you the settings you should settings and it doesn’t talk about the other settings. The docs weren’t clear enough for me to determine if those settinvs could be playing a role or not. It’s been working for some time so I don’t know if it’s me monkeying with firmware or parameters. If you have an idea I would love to hear it thanks.

@Aaron_Sims,

The rangefinder deifnitely does not seem to be working. The distances reported seem almost like random noise.

I see the RNGFND1_TYPE = 8 (Lightware Serial) which is meant for the Lightware lidar. For the Benewake TFMini I think RNGFND1_TYPE = 20 is probably better at least according to our wiki page.

Hi Randy,

Thanks fir having a look! As long as I have been using tfminis I’ve owned 4 they have never worked for me with the benewake driver. I discovered the only driver that has ever worked for serial for me, is the Lightware number 8 and there is a consensus on many wikis of the same information. Ive owned many labels of different brands but they all were pretty much the same hardware. I did on some older versions get 13 working unreliably. I discovered the lightware driver on forums online, and usually other guys that had operating problems with the Benewake said use the Lightware serial driver the other ones haven’t worked forever.

Maybe it’s a different lidar but I’ve even used the benewake TF mini software or firmware to configure it so I’m pretty sure it’s benewake.

Based on the behavior I’ve determined it’s probably the lidar sensor because I’ve never seen it act like this. It behaved the same way on serial2. Unless it’s the firmware which I suspect that I don’t suspect so much anymore though. Because that sensor has always worked, and I don’t think you’re firmware did anything to it because it’s amazing in b8, and I read reports from other testers testing terrain following.

Honestly b8 it was working so good I didn’t even want to load another earlier version ever again. It flew a payload that was overweighted like a feather. That on 3.6 the drone couldn’t even take off and developed excessive vibrations causing flip on take off. It actually ran a 71 waypoint mission flawlessly with battery to spare.

Also I couldn’t test it with the Benewake software because I don’t have the USB TTY adapter with me, or else that would of told me right away.

1 Like

I got a new benewake tf mini plus, and it doesn’t work at all with 20 benewake serial driver. It does work with 8 lightware serial driver.

If I want the quadcopter to run close to the ground let’s say 3 feet, what is the ideal rngfnd_gain to perform terrain flight with? to not hit the ground.

Thanks,

Aaron

@Aaron_Sims,

Ok, thanks for the feedback. I’ll check with Benewake and maybe ask them to send me a tfmini plus so I can double check myself.

You’ll find actually in the latest beta that the RNGFND_GAIN parameter is missing so one less param to set!

I have just tested TF mini plus on serial 20 on latest beta. It is working fine for me.

This is the one.

RNGFND1_TYPE 20
RNGFND1_MAX_CM 700
RNGFND1_MIN_CM 20
SERIAL3_PROTOCOL 9, GPS1 on a CubeOrange in my case.

1 Like

My test was on Pixhawk1 image. I can confirm similar results on Fmuv3 from when I was previously using that. It’s hard for me to believe that driver worked for anybody but maybe it’s hardware specific and only works with newer flight controllers.

Also, I had same exact results on TFmini as long as I can remember.