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

mavflightview.py: fix instance mapping including GPS[0] etc #1348

Merged
merged 3 commits into from
Apr 3, 2024

Conversation

peterbarker
Copy link
Contributor

No description provided.

this methods returns None rather than a list when there's nothing to plot
…e plotted

"map GPS" will give you all GPSs
"map GPS[0]" will give you just the first instance
"map GPS[1] GPS[2]" will give you just the 2nd and third instances

this should also extend the ability to map instance positions to other messages which have instance fields
the "type" variable was being over-written to include the instance number before we dropped down through the code which specially-treats messages based on the type variable.

So stop overwriting the variable before that switch statement, create a special string for when we need it.

Visible difference with this PR is that the GPS plots on the map no longer have lines starting from 0,0 if the GPS starts with no fix.
@peterbarker peterbarker merged commit ceafe35 into ArduPilot:master Apr 3, 2024
2 checks passed
@peterbarker peterbarker deleted the pr/instance-mapping-fix branch April 11, 2024 10:42
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.

1 participant