Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] alt_ref is NAN without GPS #24078

Open
dakejahl opened this issue Dec 6, 2024 · 2 comments
Open

[Bug] alt_ref is NAN without GPS #24078

dakejahl opened this issue Dec 6, 2024 · 2 comments

Comments

@dakejahl
Copy link
Contributor

dakejahl commented Dec 6, 2024

Describe the bug

If you takeoff with QGC (MAV_CMD_NAV_TAKEOFF) without a GPS and using an ARK Flow for position mode, the vehicle will ascend to an extreme altitude. This is because local_position.ref_alt is NAN and will not be initialized without GPS.
https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/ekf2/EKF2.cpp#L1575

To Reproduce

Issue a takeoff command from QGC to a vehicle with Flow only

Expected behavior

No response

Screenshot / Media

No response

Flight Log

https://review.px4.io/plot_app?log=055705b6-ba7b-43eb-95a0-62576b195f7e

Software Version

ARK Flow, no GPS, flying indoors, takeoff with QGC

Flight controller

arkpi6x flow

Vehicle type

None

How are the different components wired up (including port information)

No response

Additional context

This also explains a fly away we had a few months ago when we took off using QGC without realizing GPS wasn't ready. The Flow allowed the takeoff and the vehicle climbed very high, flow then failed, and the vehicle then lost connection and flew away never to be seen again.

@bresch
Copy link
Member

bresch commented Dec 6, 2024

The reference of the local plane frame were always reported as nan without GNSS fix. Did something change in Navigator/Commander?

@AlexKlimaj
Copy link
Member

Takeoff without a global position should be referenced in local coordinates instead. So takeoff to X meters above the current local Z.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants