NEW: release DJI Payload-SDK version 3.12.1

This commit is contained in:
DJI
2025-08-19 04:28:04 +08:00
parent b7e648a98a
commit 3411ca32e1
16 changed files with 38 additions and 65 deletions

View File

@ -1,8 +1,8 @@
# DJI Payload SDK (PSDK)
![](https://img.shields.io/badge/version-V3.12.0-green.svg)
![](https://img.shields.io/badge/platform-linux_|_rtos-blue.svg)
![](https://img.shields.io/badge/license-MIT-orange.svg)
![](https://img.shields.io/badge/version-V3.12.1-cyan.svg)
![](https://img.shields.io/badge/platform-linux_|_rtos-purple.svg)
![](https://img.shields.io/badge/license-MIT-yellow.svg)
## What is the DJI Payload SDK?
@ -23,48 +23,13 @@ to get the latest version information.
## Latest Release
The latest release version of PSDK is 3.12.0. This version of Payload SDK mainly add some new features support and fixed some
The latest release version of PSDK is 3.12.1. This version of Payload SDK mainly add some new features support and fixed some
bugs. Please refer to the release notes for detailed changes list.
### 1. Matrice 400 Feature Support
- **Added point cloud data subscription for LiDAR/millimeter-wave radar on aircraft.**
- **Added custom widget management.**
- **Added Expanded payload device support.**
Supports up to 7 payload devices simultaneously, compatible with:
- Skyport-V2
- XPort
### 2. Manifold 3 Now Supports:
- **Added AR image drawing function.**
- **Added Enhanced warning functionality.**
- **Added H30 camera image processing capabilities.**
- Together with Matrice 400, Manifold 3 can:
- Obtain decoded images from the H30 camera.
- Encode using a hardware encoder.
- Display AI recognition results in real time.
- **Added PSDK application development**
- Supports developing and packaging applications based on PSDK.
- Supports installing and running applications on Manifold 3.
### 3. Matrice 4TD/4D Series Feature Optimization
- **Added cloud API firmware upgrade**
### 4. E-PORT V2 Hardware Port Support
- **Adapter compatibility:**
- E-Port V2 coaxial cable
- Skyport V3
- **Power management:**
- Supports voltage requests for 13.6V, 17V, and 24V.
- **Link models:**
- Added: ONLY_USB_BULK, ONLY_NETWORK.
- Not supported: UART_AND_NETWORK, UART_AND_USB_BULK.
- **Development support:**
- Released DJI E-Port V2 development kit.
- Documentation: Refer to the Quick Start > E-Port Quick Start section.
### 5. Upgrade and Compatibility
#### SkyPort V2 and X-Port Software Upgrade
The software versions of Skyport V2 and X-Port have been upgraded. Devices need to be mounted on the Matrice 300 or Matrice 350 to be upgraded to the latest software version before they can be used on the Matrice 400 model. Subsequent software upgrades can be performed on the Matrice 400.
* Fixed an issue where the Matrice 400 could not use precise positioning.
* Fixed an issue where the Matrice 400 gimbal payload experienced a timeout when relinquishing control while using absolute angles.
* Fixed an issue where the Matrice 400 could not enable the FTS PWM trigger via the `DjiFlightController_SelectFtsPwmTrigger` API.
* Fixed an issue where the Matrice 400 and Manifold 3 models were unable to perform PSDK-to-MSDK small-data transmission.
## License

View File

@ -292,7 +292,7 @@ typedef struct {
} T_DjiFtsPwmTriggerStatus;
typedef struct {
T_DjiFtsPwmTriggerStatus ESC[2]; /* trigger status of the two ESCs */
T_DjiFtsPwmTriggerStatus ESC[4]; /* trigger tatus of the two ESCs, M4/M4D only ESC[0] and ESC[1], M400 for alls */
} T_DjiFtsPwmEscTriggerStatus;
/* Exported functions --------------------------------------------------------*/
@ -691,13 +691,24 @@ T_DjiReturnCode DjiFlightController_GetElectronicSpeedControllerStatus(E_DjiFlig
/**
* @brief Select Fts pwm trigger.
* @param position: Pwm trigger source position.
* @return Execution result.
* - Notes:Timing requirement: This API must be called while the aircraft is on the ground (not airborne). Calls made during flight will fail or be rejected.
* - Function: This call only selects/enables the PWM trigger port on the flight controller side.
* It does NOT emit PWM signals nor perform the motor-stop action itself. The actual motor-stop must be triggered by sending PWM signals via external PWM hardware pins.
* - Recommended flow:
* 1) Call DjiFlightController_SelectFtsPwmTrigger(position) on ground to enable the port;
* 2) Send the motor-stop PWM from an external PWM controller to that port;
* @param position
* - Supported models/ports:
* - M400: only support DJI_MOUNT_POSITION_EXTENSION_PORT_V2_NO4.
* @return Possible failure reasons include invalid param, aircraft not on ground, hardware unsupported, or module not initialized.
*/
T_DjiReturnCode DjiFlightController_SelectFtsPwmTrigger(E_DjiMountPosition position);
/**
* @brief Get Fts pwm trigger status.
* Notes:This API is deprecated and will be removed in a future release. It is NOT recommended for use. Supported models only: M4 serials.
* Recommended alternative: To confirm motor-stop (FTS) effects, use DJI_FC_SUBSCRIPTION_TOPIC_ESC_DATA fc subscription
* @param trigger_status
* @return Execution result.
*/
T_DjiReturnCode DjiFlightController_GetFtsPwmTriggerStatus(T_DjiFtsPwmEscTriggerStatus* trigger_status);

View File

@ -35,9 +35,9 @@ extern "C" {
/* Exported constants --------------------------------------------------------*/
#define DJI_VERSION_MAJOR 3 /*!< DJI SDK major version num, when have incompatible API changes. Range from 0 to 99. */
#define DJI_VERSION_MINOR 12 /*!< DJI SDK minor version num, when add functionality in a backwards compatible manner changes. Range from 0 to 99. */
#define DJI_VERSION_MODIFY 0 /*!< DJI SDK modify version num, when have backwards compatible bug fixes changes. Range from 0 to 99. */
#define DJI_VERSION_MODIFY 1 /*!< DJI SDK modify version num, when have backwards compatible bug fixes changes. Range from 0 to 99. */
#define DJI_VERSION_BETA 0 /*!< DJI SDK version beta info, release version will be 0, when beta version release changes. Range from 0 to 255. */
#define DJI_VERSION_BUILD 2254 /*!< DJI SDK version build info, when jenkins trigger build changes. Range from 0 to 65535. */
#define DJI_VERSION_BUILD 2262 /*!< DJI SDK version build info, when jenkins trigger build changes. Range from 0 to 65535. */
/* Exported types ------------------------------------------------------------*/

View File

@ -64,7 +64,8 @@ start:
<< "| [9] Interest point sample - run interest point mission by settings (only support on M3E/M3T) |\n"
<< "| [a] EU-C6 FTS trigger sample - receive fts callback to trigger parachute function (only support on M3D/M3DT) |\n"
<< "| [b] Slow rotate blade sample, only support on M400 |\n"
<< "| [c] Select FTS pwm trigger position, only support on M4/M4T/M4D/M4TD |\n"
<< "| [c] Select FTS pwm trigger position, support on M4/M4T/M4D/M4TD |\n"
<< "| [d] Select FTS pwm trigger position, support on M400 |\n"
<< std::endl;
std::cin >> inputSelectSample;
@ -106,7 +107,12 @@ start:
DjiTest_FlightControlRunSample(E_DJI_TEST_FLIGHT_CTRL_SAMPLE_SELECT_SLOW_ROTATE_BLADE);
break;
case 'c':
DjiTest_FlightControlFtsPwmTriggerSample();
DjiTest_FlightControlFtsPwmTriggerSample(DJI_MOUNT_POSITION_EXTENSION_PORT, "DJI_MOUNT_POSITION_EXTENSION_PORT");
// or DJI_MOUNT_POSITION_EXTENSION_LITE_PORT
DjiTest_FlightControlFtsPwmTriggerSample(DJI_MOUNT_POSITION_EXTENSION_LITE_PORT, "DJI_MOUNT_POSITION_EXTENSION_LITE_PORT");
break;
case 'd': // for m400
DjiTest_FlightControlFtsPwmTriggerSample(DJI_MOUNT_POSITION_EXTENSION_PORT_V2_NO4, "DJI_MOUNT_POSITION_EXTENSION_PORT_V2_NO4");
break;
case 'q':
break;

View File

View File

@ -98,8 +98,7 @@ T_DjiReturnCode DjiTest_DataTransmissionStartService(void)
}
if (s_aircraftInfoBaseInfo.aircraftType == DJI_AIRCRAFT_TYPE_M400) {
USER_LOG_INFO("M400 is not support to use data transmition between PSDK device.");
return DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS;
USER_LOG_INFO("Only supports small data transmission between PSDK and MSDK.");
} else if (s_aircraftInfoBaseInfo.mountPosition == DJI_MOUNT_POSITION_PAYLOAD_PORT_NO1 ||
s_aircraftInfoBaseInfo.mountPosition == DJI_MOUNT_POSITION_PAYLOAD_PORT_NO2 ||
s_aircraftInfoBaseInfo.mountPosition == DJI_MOUNT_POSITION_PAYLOAD_PORT_NO3) {

View File

@ -1672,7 +1672,7 @@ DjiTest_FlightControlJoystickCtrlAuthSwitchEventCallback(T_DjiFlightControllerJo
return DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS;
}
static T_DjiReturnCode DjiTest_FlightControlSetFtsTrigger(E_DjiMountPosition position, char* desc)
static T_DjiReturnCode DjiTest_FlightControlSetFtsTrigger(E_DjiMountPosition position, const char* desc)
{
T_DjiReturnCode djiStat;
T_DjiFtsPwmEscTriggerStatus esc_status;
@ -1702,7 +1702,7 @@ static T_DjiReturnCode DjiTest_FlightControlSetFtsTrigger(E_DjiMountPosition pos
return djiStat;
}
T_DjiReturnCode DjiTest_FlightControlFtsPwmTriggerSample(void)
T_DjiReturnCode DjiTest_FlightControlFtsPwmTriggerSample(E_DjiMountPosition position, const char* port_name)
{
T_DjiReturnCode returnCode;
@ -1711,14 +1711,9 @@ T_DjiReturnCode DjiTest_FlightControlFtsPwmTriggerSample(void)
USER_LOG_ERROR("Init flight Control sample failed,error code:0x%08llX", returnCode);
return returnCode;
}
returnCode = DjiTest_FlightControlSetFtsTrigger(DJI_MOUNT_POSITION_EXTENSION_PORT, "DJI_MOUNT_POSITION_EXTENSION_PORT");
returnCode = DjiTest_FlightControlSetFtsTrigger(position, port_name);
if (returnCode != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) {
USER_LOG_ERROR("Test select DJI_MOUNT_POSITION_EXTENSION_PORT fts pwm trigger failed");
return returnCode;
}
returnCode = DjiTest_FlightControlSetFtsTrigger(DJI_MOUNT_POSITION_EXTENSION_LITE_PORT, "DJI_MOUNT_POSITION_EXTENSION_LITE_PORT");
if (returnCode != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) {
USER_LOG_ERROR("Test select DJI_MOUNT_POSITION_EXTENSION_LITE_PORT fts pwm trigger failed");
USER_LOG_ERROR("Test select %s fts pwm trigger failed", port_name);
return returnCode;
}

View File

@ -60,7 +60,7 @@ typedef struct {
T_DjiReturnCode DjiTest_FlightControlRunSample(E_DjiTestFlightCtrlSampleSelect flightCtrlSampleSelect);
void DjiTest_FlightControlVelocityAndYawRateCtrl(const T_DjiTestFlightControlVector3f offsetDesired, float yawRate,
uint32_t timeMs);
T_DjiReturnCode DjiTest_FlightControlFtsPwmTriggerSample(void);
T_DjiReturnCode DjiTest_FlightControlFtsPwmTriggerSample(E_DjiMountPosition position, const char* port_name);
#ifdef __cplusplus
}

View File

@ -286,12 +286,9 @@ void DjiUser_StartTask(void const *argument)
#endif
#ifdef CONFIG_MODULE_SAMPLE_POSITIONING_ON
if (aircraftInfoBaseInfo.mountPositionType == DJI_MOUNT_POSITION_TYPE_EXTENSION_PORT ||
aircraftInfoBaseInfo.mountPositionType == DJI_MOUNT_POSITION_TYPE_EXTENSION_PORT_V2) {
if (DjiTest_PositioningStartService() != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) {
USER_LOG_ERROR("psdk positioning init error");
}
}
#endif
#ifdef CONFIG_MODULE_SAMPLE_UPGRADE_ON

0
tools/file2c/file2c.exe Normal file → Executable file
View File