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

Cannot build 2D Mapping Waypoint Mission #318

Open
tkocik92 opened this issue Apr 19, 2024 · 1 comment
Open

Cannot build 2D Mapping Waypoint Mission #318

tkocik92 opened this issue Apr 19, 2024 · 1 comment

Comments

@tkocik92
Copy link

SDK Version: 5.8.0
WPMZ SDK: 1.0.1.5

I'm not sure this is the relevant place to ask this, but it's an issue within this codebase.

I am attempting to create/upload a 2D Mapping mission (Ortho Collection) while utilizing WPMZManager.getInstance().generateKMZFile(). There are 2 problems with this.

  1. A 2D Mapping mission requires me to implement a WaylineTemplate instead of a Template (from what I can tell looking at the source code at least). A Template does not support the various fields used in a 2D Mapping mission (as seen by looking at the raw XML generated by a mission in the Pilot app)
  2. generateKMZFile() does not take WaylineTemplate as a possible parameter. It takes either a Template or a Wayline (ignoring the other parameters in this case).

I did find a helper method in TemplateTransform defined as fun transFromWaylineTemplate(waylineTemplate: WaylineTemplate): Template? but this just creates a Template with no waypoints.

If this is intended behavior, that's fine. Are there helper functions/classes that can convert a 2D Mapping Polgyon into a real waypoint mission?

If this is not intended behavior, what should I be doing?

@dji-dev
Copy link
Contributor

dji-dev commented Apr 22, 2024

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

The current capability of WPMZSDK does not include the ability to generate 2D Mapping waypoint tasks because it has not been integrated with the WaylineTemplate to create corresponding waylines in the WPML library. The method transFromWaylineTemplate is used to generate a Template from WaylineTemplate, which only supports regular waypoint missions. The transToWaylineTemplate function can convert a Template to WaylineTemplate, but upon reviewing its internal implementation, the templateType is default set to waypoint, and WaylineTemplate cannot be used to generate KMZ files.

If you wish to create a Mapping waypoint mission file, you can generate the corresponding KML file based on the information provided on the official website, and then import this file into Pilot 2 to generate a complete KMZ file.

°°°

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