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

Align OSD waypoint number display with geospatial waypoints #6429

Merged
merged 9 commits into from
Jun 7, 2021

Conversation

breadoven
Copy link
Collaborator

@breadoven breadoven commented Dec 17, 2020

Waypoint missions that include nongeospatial waypoints, JUMP, HEADING, POI, display WP numbers in the OSD that follow the numeric sequence of all WPs in the mission rather than just the geospatial WPs which would seem a more intuitive expectation from a user point of view. This means the displayed WP numbers can appear inconsistent and increment by more than 1 when nongeo WPs are passed.

This PR fixes this by realigning the WP numbers displayed in the OSD with just the geospatial WPs and also adds a geospatial WP total count.

Tested in flight and works as expected for fixed wing and multirotor.

@breadoven
Copy link
Collaborator Author

Added WP distance counter to OSD "TO WP" message.

src/main/io/osd.c Outdated Show resolved Hide resolved
@breadoven breadoven changed the title Align OSD waypoint number display with geospatial waypoints Align OSD waypoint number display with geospatial waypoints [wip] Apr 19, 2021
@breadoven breadoven changed the title Align OSD waypoint number display with geospatial waypoints [wip] Align OSD waypoint number display with geospatial waypoints Apr 19, 2021
@breadoven
Copy link
Collaborator Author

Means of determining realigned geospatial WP numbering changed to iterative method removing the need for an array to store values.

@breadoven
Copy link
Collaborator Author

Any chance of getting this merged given it is intended to fix a recently reported issue, see #6997. @stronnag , @DzikuVx

@avsaase
Copy link
Member

avsaase commented Jun 7, 2021

@breadoven Can you rebase on the release_3.0.0 branch and change the base branch?

Fix to ensure only geospatial WPs are displayed on OSD with sequential numbering maintained around nongeo WPs.
Change from using WP.flag to WP.p3
Change from using WP .P3 to dedicated geospatial WP list list array
Change to remove array for storing geospatial WP indices. Uses iterative method to determine geospatial WP numbering instead.
@breadoven breadoven changed the base branch from master to release_3.0.0 June 7, 2021 09:56
@breadoven
Copy link
Collaborator Author

@avsaase OK that seems to have worked. The final diff looks correct.

@avsaase avsaase added this to the 3.0 milestone Jun 7, 2021
@avsaase avsaase merged commit ecdc55b into iNavFlight:release_3.0.0 Jun 7, 2021
@breadoven breadoven deleted the abo_fix_OSD_WP_message branch June 22, 2021 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants