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

Misseditor Distance and Gradient #612

Merged
merged 1 commit into from Jun 10, 2019

Conversation

@Akshath-Singhal
Copy link
Contributor

commented Apr 20, 2019

Added Distance and Gradient fields for better mission planning using MAVProxy GCS. Distance is displayed in meters and Gradient in degrees.
misseditor

Future Prospects:

  1. Handling altitude based on reference frame (Relative or Absolute)
  2. Better handling of different waypoints instead of checking LAT=0 & LON = 0

I have tried to include most of the changes suggested by @tridge.

@Akshath-Singhal

This comment has been minimized.

Copy link
Contributor Author

commented Apr 20, 2019

@tridge Changing LAT, LON, and ALT based on user input changes in Dist and Grad would indeed be an interesting feature, however, I am skeptical due to the increased probability of crashes due to changing these values carelessly.

@tridge
Copy link
Contributor

left a comment

looking good! just a few minor points below

@tridge

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

one more thing, I think we should have the function to get the gradient and distance be part of the mavproxy_wp module. I think it will be used by other pieces of code in the future.
Modules can call functions in other modules as long as they are public (wp is public)

@tridge

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2019

it would also be good to implement the handling of frames. That is a bit complex, but quite possible and would be very useful
I'd suggest having a function to convert a wp alt to absolute first, then do everything in absolute. For home height use the height of home location in terrain database (the mission editor already knows home location and displays it). For AGL wps use terrain database.

@Akshath-Singhal

This comment has been minimized.

Copy link
Contributor Author

commented Apr 21, 2019

Thanks. The idea of adding distance and gradient functions to wp module seems like a nice idea.
For reference frame issues, I was planning to save the current home altitude as variable and use it on the go instead of shifting all altitudes to absolute frame.

The changes might take some time due to my university examinations. Sorry for the delay being caused.

@tridge

This comment has been minimized.

Copy link
Contributor

commented Apr 23, 2019

no worries at all, thanks for your nice work on this!

@stephendade

This comment has been minimized.

Copy link
Contributor

commented Apr 23, 2019

I had a quick look at this - you're using tabs instead of spaces for the indents. You'll need to change them to spaces for consistency.

@Akshath-Singhal

This comment has been minimized.

Copy link
Contributor Author

commented May 1, 2019

I had a quick look at this - you're using tabs instead of spaces for the indents. You'll need to change them to spaces for consistency.
@stephendade
Corrected that. Thanks for informing.

@tridge

This comment has been minimized.

Copy link
Contributor

commented May 20, 2019

@Akshath-Singhal any update on this?

@Akshath-Singhal

This comment has been minimized.

Copy link
Contributor Author

commented May 21, 2019

@tridge I have added the frame handling part for gradient calculation. I will shift it to wp module soon.

@tridge
tridge approved these changes May 29, 2019
@tridge
Copy link
Contributor

left a comment

looking good, just need to squash into one commit (do you know how to use interactive rebase?)
We can leave the moving to wp module to a separate PR if you like

@tridge

This comment has been minimized.

Copy link
Contributor

commented May 29, 2019

hmm, minor thing, col width too small by default for me:
image

@Akshath-Singhal Akshath-Singhal force-pushed the Akshath-Singhal:misseditor branch from 3da4b54 to 0f325f3 May 29, 2019

@Akshath-Singhal

This comment has been minimized.

Copy link
Contributor Author

commented May 29, 2019

@tridge Squashed to 1 commit. Increased the default size for columns.

@peterbarker

This comment has been minimized.

Copy link
Contributor

commented May 30, 2019

Small reword on the commit message would be good. We don't fuss too much in mavproxy, but something like "misseditor: Add Dist and Grad columns" would make it a bit clearer what's being changed in the PR.

@Akshath-Singhal Akshath-Singhal force-pushed the Akshath-Singhal:misseditor branch from 0f325f3 to cb19a36 May 30, 2019

Misseditor: Added Dist and Grad
Added distance between waypoints and gradient of path to mission editor with alt ref frame handling

@Akshath-Singhal Akshath-Singhal force-pushed the Akshath-Singhal:misseditor branch from bf95738 to 96feb18 Jun 10, 2019

@tridge tridge merged commit b83a40c into ArduPilot:master Jun 10, 2019

1 check passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
@tridge

This comment has been minimized.

Copy link
Contributor

commented Jun 10, 2019

looks good, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.