I had a look at your log. RTL was triggered by Low battery There is an error msg . You could lower this voltage to avoid false failsafe. On low battery, failsafe action should be LAND. You are not sure to have enough battery to climb, return to home then land.
RTL parameters (your RTL altitude is set à 5 meters, quite low as default is 15m)
Thank you for your valuable and prompt investigation! Here some more background information:
Yes, the drone is equipped with a lidar light V3HP. Primary altitude source is set to range finder. As you can see from altitude measurements, I was flying at relative low altitudes (typ. 1m) above ground. The drone altitude follows nicely the terrain with high accuracy at stable altitude, which would be impossible by using the baro as height source.
There is a second range finder pointing upwards. Proximity is activated so that if the drone is close to a ceiling it keeps a distance of 1m, regardless of any throttle increase. The measuring range of this range finder is limited to 12 m. You can see both range finder data in the PRX menu. Strangely, in the new mission planner, the date of both range finder are overlayed in one graph (checking DIST). In the RNG menu I get just data for “Down” but nothing for “Up”. Maybe you can confirm that?
further, I have a Optical Flow installed. But as you can see, in the this flight, it was not activated for PosHold. I used GPS information.
The battery low failsafe parameter has been set intentially to a relative high voltage, triggering RTL, so I could test a failsafe event after about 10 minutes flight. As explained before, reaching the battery failsafe, it triggered some undefined “flightmode”, where the drone stopped to react to my RC-transmitter commands, just drifting slowly away. I had to switch from PosHold to AltHold to gain again control. Actually I do not understand, why a failsafe trigger is labeled as an error?
Also I used channel 7 to switch to RTL manually, which caused the same reaction like discribed above.
Earlier to this experiment with FW4.0.0-rc, I was using the arducopter FW 3.7-dev and RTL and Smart RTL were working well. I tested several RTL-altititudes from 5 to 50 m and all were exactly attained.
I have no experience with Range finder and optical flow…
As RTL could be dependant of baro altitude, it may be interesting to do your test at 5 meters or more. During your flight, baro altitude was below 0 most of the time. So when RTL is triggered, it stay below 0 (consider itself on ground and drift??).
Next flight, I will test smart RTL. Next Friday due to high wind and rain…