maksoltane / DJI-Windows-SDK-UWP-Sample

DJI SDK Sample for Windows 10 and Universal Windows Platform

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DJI SDK Sample for Windows 10 and Universal Windows Platform

Screenshot

This sample is a Universal Windows Platform* app that demostrates DJI Windows SDK capabilities:

  • Aircraft's camera video feed
  • Aircraft control (Joysticks and Takeoff/Home functionality)
  • Camera gimbal control
  • Flight telemetry data events

The app leverages XAML-based UI and Windows ML, running inference (evaluation) on top of aircraft's video feed using a Windows ML model.

Screenshot

Windows ML

This sample uses a WinML model called InkShapes. It's made by Nikola Metulev and trained in Custom Vision on simple black-and-white hand-drawn pictures representing one of 21 categories, such as house, flower, stick figure, bike, and others.

With Custom Vision, you can train an AI model using your own images, then export it to different model formats including ONNX.

The model is not smart enough yet. House, flower, and stick figure are recognized quite well. You may help Nikola traning the model - just by drawing shapes in Draw the shape! app.

Requirements:

  1. Windows 10 April 2018 Update.
  2. Windows 10 SDK 1803 (for April 2018 Update).
  3. Visual Studio 2017 with Universal Windows Platform tools (including C++ tools for UWP), Desktop C++ Development and Desktop .NET development.
  4. DJI SDK for Windows. All BUILD 2018 attendees should have a link to DJI Windows SDK alpha.

How to build

You need DJI Windows SDK.

Prepare the SDK:

DJI Windows SDK is not included in this repo. You need to obtain it from DJI, and copy 2 folders from the SDK to this project's folder.

  1. Copy DJIWindowsSDK folder from the SDK's package to the root of this project.
  2. Copy ThirdParties folder from the SDK's sample (DJIWindowsSDKDemo/ThirdParties) to the root of this project. How to copy SDK folders

Note, these 2 folders are in .gitignore, so if you want to have them in your repo, please remove these 2 lines from .gitignore:

ThirdParties/
DJIWindowsSDK/ 

Build with Visual Studio 2017:

  1. Once you copied all requred dependencies, open WinDrone.sln in Visual Studio 2017
  2. Right-click on DJIUWPDemo, click 'Set as StartUp Project'
  3. Build, debug, deploy, enjoy!

*Platform notes

Current alpha version of DJI SDK only supports x86 architecture on Windows desktop. It has a few "classic" Win32 dependencies, so the app package requres Full Trust capability (using Desktop Bridge), and only runs on Windows 10 Desktop. Video decoding component doesn't leverage hatdware acceleration yet.

The sample C# app uses the SDK via an additional DJIClient DLL and PInvoke calls.

Full Universal Windows Platform support and other improvements are coming later towards the release of DJI Windows SDK.

About

DJI SDK Sample for Windows 10 and Universal Windows Platform


Languages

Language:C++ 56.0%Language:C# 42.6%Language:C 1.5%