PX4Flow and Failsafe enabled: no local position

Dear PX4 Experts,

hopefully you can help me, guide me to overcome my issues with the PX4Flow (1.31). First some information about my drone:

  • basically it is a Holybro QAV250
  • GPS is disabled
  • Pixhawk 4 mini is mounted in the center of the drone
  • PXFlow is enabled and mounted downwards in the center of the drone
  • TFmini is enabled and configured for range finder

PX4-Autopilot: 1.12dev
PX4Flow: latest from github
QGroundControl: Daily from June, 13th 2021

For PX4-Autopilot and PX4Flow I tried already latest releases. But no change in behaviour.

If I open the MAVLink Inspector in QGroundControl I get for DISTANCE_SENSOR meaningful values from the TFmini.

If the Drone is on the groubd I get for OPTICAL_FLOW_RAD only zeros except for distance (I guess that is the distance form the Sonar), temperature and the both time values. All other values are zero. I am aware of the quality. From the PX4flow code, quality must be > 0, otherwise you will get only zero.

That leads me to two questiouns:

  • Why do I not get meaningful values if the drone is on the ground? I calibrated the lens to about 2m.

  • If I take the drone and move it by hand up than following I notice:

  1. About 40cm distance from ground suddenly I get values. Quality is not good. Arround 100-130
  2. If I move up heigher quality becomes better and better
  3. Arround 90cm quality becomes a value > 200

Would be great if one of you experts can explain me a bit more why I see taht behaviour and what I can do. Because I think that this behaviour is the reason why I can’t takeoff. If I send the takeoff message the drone starts to takeoff and imediatly lands with the message:

Failsafe enabled: no local position

Which is true, as long my understanding is correct that the local position in my case is calculated from the PX4Flow and TFmini.

Btw: My goal is to use the drone with ROS2 in Offboard mode. I run already the ROS2 example from PX4 (of course I changed the height from 5m to 1.5m, because of my calibration), but still the same behaviour: No local position.

I am aware of some other, similar threads in this forum. Unfortunatly they could not help me to understand my PX4flow issue.

Thanks for your help!

I’m getting the same problem, failsafe enabled: no local position when I try to takeoff with PX4flow

@kolde I think you might be jnterested in studying the Flow sensors and how they work. The docs on Px4 PX4FLOW Smart Camera | PX4 User Guide are quite enought to have an overall idea.

What is your altitude source?