Skip to content

Conversation

@breadoven
Copy link
Collaborator

WP mission Landing currently assumes the landing elevation is the same as takeoff elevation which may not be the case for remote landings. If the remote landing elevation is different then landing vertical velocity scaling will be incorrect. This is more of an issue if the landing elevation is higher than takeoff elevation because the ground will appear sooner than INAV is expecting.

This PR provides the ability to define a different landing elevation to the default takeoff home elevation by setting Landing WP P1 as the landing elevation. Uses an elevation in cm which requires P1 to be changed to int32_t. Could maintain the current int16_t if the elevation was set in meters instead. This would be accurate enough for landing elevation but inconsistent with the altitude setting in cm leading to potential confusion with the settings.

@stronnag
Copy link
Collaborator

Changing a legacy API is not considered acceptable.
Using metres would be fine.

@breadoven
Copy link
Collaborator Author

Changing a legacy API is not considered acceptable.
Using metres would be fine.

I'll change it to use meters. If it's set by a mission planner then it can handle the units as required, if set by CLI the user will need to be aware. That will be the 1 user a year who uses remote landings ...

@stronnag
Copy link
Collaborator

Also, P1 as speed is valid for a LAND WP, so P2 for elevation.

@breadoven
Copy link
Collaborator Author

breadoven commented Apr 29, 2021

I guess I should have realised that given how it works. https://github.com/iNavFlight/inav/wiki/MSP-Navigation-Messages could do with updating to include P1 speed for Landing.

@stronnag
Copy link
Collaborator

stronnag commented Apr 29, 2021

I guess I should have realised that given how works. https://github.com/iNavFlight/inav/wiki/MSP-Navigation-Messages could to with updating to include P1 speed for Landing.

Thanks. I'll fix that when the landing elevation PR is done now.

@stronnag stronnag added the Release Notes Add this when a PR needs to be mentioned in the release notes label May 3, 2021
@stronnag stronnag added this to the 3.0 milestone May 3, 2021
Add correction if absolute SL landing elevation used (related PR iNavFlight#6662)
@breadoven
Copy link
Collaborator Author

#6662 related change made so should be good to merge.

Thanks

@stronnag stronnag merged commit 40f2344 into iNavFlight:master May 3, 2021
@breadoven breadoven deleted the abo_WP_mission_landing_elevation branch May 3, 2021 16:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Release Notes Add this when a PR needs to be mentioned in the release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants