12.1 DJI PSDK
The DJI PSDK kit includes a DJI PSDK version of the onboard computer, a DJI PSDK adapter board, and a mounting bracket. The DJI PSDK kit makes it easy to combine AMOVLAB's high…
4 min read · English documentationI. DJI PSDK Kit Introduction
The DJI PSDK kit includes a DJI PSDK version of the onboard computer, a DJI PSDK adapter board, and a mounting bracket. The DJI PSDK kit makes it easy to combine AMOVLAB's high-performance edge onboard computer with DJI's industry-leading flight platforms, providing a simple and complete DJI PSDK hardware development platform. Developers can use basic functions provided by the DJI PSDK API, such as information acquisition, data transmission, and power management, as well as advanced functions such as camera, gimbal, payload coordination, and precision positioning. Various recognition and control algorithms can be deployed on the onboard computer according to industry application requirements to improve the intelligence of the UAV. Typical applications include indoor flight, automated inspection, and intelligent image recognition and tracking.
| Onboard Computer | DJI Aircraft | Aircraft Role | Communication Connection |
|---|---|---|---|
| Allspark2-Orin NX | M300 | Device | USB, serial |
| Allspark2-x86 | M300 | Device | USB, serial |
| Allspark2-Orin NX | M350/M30 | Host | Ethernet (ETH), serial |
| Allspark2-x86 | M350/M30 | Host | Ethernet (ETH), serial |
II. Hardware Installation Instructions
1. The DJI PSDK adapter board interfaces are detailed below:


2. M30/M350 and Allspark2-Orin NX Connection Diagram

3. M300 and Allspark2-Orin NX Connection Diagram

Note
When connecting the serial port, connect TX, RX, and GND as shown below:
4. DJI PSDK Kit Installation Procedure (M30 Example)
Step 1: Confirm that the DJI PSDK package contains the following items

Step 2: Confirm that the DJI PSDK ribbon cable is connected as shown and that the slide switch points in the direction indicated by the red arrow

Step 3: Install the M3*15+4 hex standoffs on the UAV

Note
Use a socket wrench to secure the standoffs firmly to the aircraft.
Step 4: Secure the AMOVLAB DJI PSDK adapter board to the aircraft with M3*8 screws.

Note
Confirm that the orientation of the DJI PSDK adapter board relative to the aircraft and the cable routing direction match the figure.
Step 5: Install the onboard computer on the DJI PSDK adapter board and secure it with M3X8 screws

Note
1. As shown, make sure the onboard computer's cooling air outlet faces the rear of the aircraft. 2. Use pliers to tighten the nut and screw. (Pliers are also required to hold the nut during removal.)
Step 6: Connect the communication cables as shown below

Step 7: Power on and verify. The Allsaprk2-Orin NX starts automatically when power is applied
Note
1. If power is not supplied, refer to Step 2. Check whether the DJI PSDK coaxial cable is inserted in the wrong orientation, confirm that the silkscreen orientation is correct, and confirm that the slide switch is in the Power On position. 2. If the communication connection is incorrect, confirm that all three slide switches are in the correct positions and that the serial cable is connected to UART2.
Video Reference
III. Allspark2-Orin NX DJI PSDK Software Activation and Demo
Preparations:
- Check the runtime environment:
sudo apt install cmake
sudo apt install ffmpeg
sudo apt install build-essential
To receive a video stream, you must also install openCV. You can run openCV-version to check whether openCV is installed in the environment.
- Configure the IP address:
If you use ETH to connect to the DJI PSDK, configure an IP address. For example, the M30 IP address is 192.168.90.2. Follow these steps:
A. Open Settings and locate Network. B. Click the plus sign at the top to add a network. C. M30 IP: 192.168.90.2; M350 IP: 192.168.100.2; The M300 connects via USB.
D. Select manual IP address entry (enter the IP address for the applicable aircraft model).

Note
If video streaming becomes stuck: 1. Connect to Wi-Fi. 2. Switch the network connection.
Software Activation Procedure:
- Download the PSDk source code software (if there is no
Amovlab_Dji_PSDKdirectory under/home/amov). Use the following command to enter root mode:
sudo su
-
Enter
Amovlab_PSDK. -
Run
Amov_LaunchPSDK.sh.
./Amov_LaunchPSDK.sh

- Press 3 to clear the cache.

- Press 2 to compile DJI PSDK.

Demo:
- Press 1 to run DJI PSDK.

- Enter
cto select Camera stream view sample; enter0to select Normal RGB image display.

- Enter
1to select Main camera (the UAV gimbal camera). The onboard computer receives video from the Main camera, indicating that the communication link between the DJI UAV and the onboard computer is operating normally and is ready for use.



The following shows AMOVLAB SpireCV software recognizing a QR code using a DJI aircraft.

Note
For DJI PSDK application development, refer to the following links:
For a DJI UAV PSDK tutorial, refer to the DJI official website
DJI SDK Technical Support Forum DJI PSDK API For the onboard computer (X86) Wiki, refer to the AMOVLAB official website For the onboard computer (ORIN) Wiki, refer to the AMOVLAB official website AMOVLAB Onboard Computer Forum AMOVLAB Official Website
