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

Distance between drone and home point #1280

Open
danilofariadutra opened this issue Apr 3, 2024 · 3 comments
Open

Distance between drone and home point #1280

danilofariadutra opened this issue Apr 3, 2024 · 3 comments

Comments

@danilofariadutra
Copy link

What method should I use to acquire the value of the distance already traveled between the homepoint and the current location of the drone, just like in the DJI app?

@dji-dev
Copy link
Contributor

dji-dev commented Apr 7, 2024

Agent comment from yating.liao in Zendesk ticket #104243:

Could you clarify if the distance you are referring to is the flying distance after the aircraft takes off, or the straight-line distance between the current position of the aircraft and the return point?

Thank you.

°°°

@danilofariadutra
Copy link
Author

the straight-line distance between the current position of the aircraft and the return point

@dji-dev
Copy link
Contributor

dji-dev commented Apr 8, 2024

Agent comment from yating.liao in Zendesk ticket #104243:

You can calculate the distance between the current location of the aircraft and the return point after obtaining their positions. The current location of the aircraft can be obtained using FlightController.getState.getAircraftLocation. The return point location can be obtained using FlightController.getState.getHomeLocation. The latitude and longitude coordinates obtained are all based on the WGS84 coordinate system.

°°°

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

No branches or pull requests

2 participants