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

WP "user actions" breaks waypoint navigation #1721

Closed
ABLomas opened this issue Feb 13, 2023 · 9 comments
Closed

WP "user actions" breaks waypoint navigation #1721

ABLomas opened this issue Feb 13, 2023 · 9 comments

Comments

@ABLomas
Copy link

ABLomas commented Feb 13, 2023

Short video demonstrating issue:
https://user-images.githubusercontent.com/8989151/218552591-65620b35-67e2-451c-ae52-334931ab7444.mp4
Text version - mission waypoint with user action set has it's altitude set to MSL+preset altitude, while AGL setting is selected.
This was registered as issue on another branch but it looks like firmware has nothing to do with it:
iNavFlight/inav#8798

In short - looks like INAV-configurator incorrectly parses bit0 in P3 field and and this is reason why alt is set to wrong value.

@breadoven
Copy link
Collaborator

Configurator needs updating to read the WP P3 parameter as a Bitfield rather than a boolean as it does at the moment.

@MrD-RC
Copy link
Collaborator

MrD-RC commented Feb 13, 2023

Configurator has been updated to read P3 as a bitfield. I thought I had tested that everything was toggled correctly. But something must have slipped through.

@breadoven
Copy link
Collaborator

OK missed that change. I was going to do it but seems you've saved me the trouble.

So just updated Configurator and checked this and it appears that the Bit is being set but not unset, so once it's been set it gets stuck true.

@breadoven
Copy link
Collaborator

The other problem is P3 is used as a boolean in various places which affects the altitude calculation depending on whether SL or relative altitude datum is used. Bit 0 needs checking rather than just the boolean state of the P3 value. I've made some changes that have fixed the obvious things, need to check other stuff isn't affected.

@breadoven
Copy link
Collaborator

Do you want me to fix this @MrD-RC given it's related to the MSL Altitude stuff I did originally ?

@MrD-RC
Copy link
Collaborator

MrD-RC commented Feb 14, 2023

@breadoven I found somewhere that was using P3 as a Boolean. So I've sorted that and fixed some other things too. The Elevation (m) and Grd Dist (m) seem to be working correctly to me. But, the elevation profile doesn't seem right. I couldn't see any references to P3 in there. Your thoughts? It may be fine though. It looks the same in 5.1 Configurator.

WP1
image

WP2
image

WP3
image

WP4
image

WP5
image

WP6
image

test mission.mission.txt

@MrD-RC
Copy link
Collaborator

MrD-RC commented Feb 14, 2023

Added a PR #1722

@MrD-RC
Copy link
Collaborator

MrD-RC commented Feb 14, 2023

There is something causing issues in the elevation profile. If I disable the user actions, it looks as I would expect.

@MrD-RC
Copy link
Collaborator

MrD-RC commented Feb 14, 2023

Got it. It was hidden in WaypointCollection.

WP2 now for comparison
image

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