If you come across any mistakes or bugs in this tutorial, please let us know by sending emails to dev@dji.com. Please feel free to send us Github pull request and help us fix any issues.
Preparation
Mavic 2 aircraft and remote controller in newest firmware version. Use DJI Go App on mobile phone to check if your devices need updating.
Windows SDK 0.3.1 or later.
Micro-USB cable.
DJI Assistant 2
Make sure that you have installed DJI Assistant 2 and have enabled all the driver intallation while installing DJI Assistant 2.
With DJI Assistant 2 and connected Mavic 2, check Device Manager of your computer. If there is a yellow warning icon in the DJI item inside Ports (COM & LPT) , you need to install or re-install DJI Assistant 2 and make sure you have enabled all the driver intallation while installing.
WinUSB Driver
Install open-source software zadig.exe and open it.
Connect your Mavic 2+ remote controller.
Selete device named libusb-win32 and install its WinUSB driver.
USB Authority Configuration in UWP
Configure serial port authority in order to connect the application to the remote controller. Right-click on Package.appxmanifest, select View Code, add the following code in the Capabilities element.
Make sure that before connecting using your cable, your P4P V2.0 remote controller is off.
Connect the remote controller to your computer using Micro-USB cable.
Turn on your remote controller.
Make sure you have not open the DJI software like DJI Assistant 2. DJI Windows SDK Applications are not able to communicate with the aircrafts at the same time.