NEW: release DJI Payload-SDK version 3.9.1
This commit is contained in:
@ -46,7 +46,7 @@ typedef struct {
|
||||
} T_DjiMobileAppInfo;
|
||||
|
||||
/**
|
||||
* @brief Some base information of aircraft system, mainly including some constant parameters information of system.
|
||||
* @brief Basic information about the aircraft system, mainly including some constant parameters information.
|
||||
*/
|
||||
typedef struct {
|
||||
E_DjiAircraftSeries aircraftSeries; /*!< Aircraft series. */
|
||||
@ -68,31 +68,31 @@ typedef struct {
|
||||
|
||||
/* Exported functions --------------------------------------------------------*/
|
||||
/**
|
||||
* @brief Get base information of aircraft system, including aircraft type and DJI adapter type.
|
||||
* @param baseInfo: pointer to memory space used to store base information of the aircraft system.
|
||||
* @brief Basic information about the aircraft system, including aircraft type and DJI adapter type.
|
||||
* @param baseInfo: Pointer to a memory space where the aircraft's basic information will be stored.
|
||||
* @return Execution result.
|
||||
*/
|
||||
T_DjiReturnCode DjiAircraftInfo_GetBaseInfo(T_DjiAircraftInfoBaseInfo *baseInfo);
|
||||
|
||||
/**
|
||||
* @brief Get information related to mobile APP.
|
||||
* @note The mobile APP language and screen type is unknown if RC or APP is not connected to the aircraft system.
|
||||
* @param mobileAppInfo: pointer to memory space used to store information related to mobile APP.
|
||||
* @brief Get information related to mobile app.
|
||||
* @note Returns unknown for app language and screen type if the RC or app is not connected to the aircraft system.
|
||||
* @param mobileAppInfo: Pointer to a memory space where the mobile app information will be stored.
|
||||
* @return Execution result.
|
||||
*/
|
||||
T_DjiReturnCode DjiAircraftInfo_GetMobileAppInfo(T_DjiMobileAppInfo *mobileAppInfo);
|
||||
|
||||
/**
|
||||
* @brief Get connection status of payload and aircraft.
|
||||
* @brief Get connection status between the payload and the aircraft.
|
||||
* @note Update period: 1Hz
|
||||
* @param isConnected: pointer to connection status.
|
||||
* @param isConnected: Pointer to connection status.
|
||||
* @return Execution result.
|
||||
*/
|
||||
T_DjiReturnCode DjiAircraftInfo_GetConnectionStatus(bool *isConnected);
|
||||
|
||||
/**
|
||||
* @brief Get version of aircraft.
|
||||
* @param aircraftVersion: pointer to aircraft version.
|
||||
* @brief Get version of the aircraft.
|
||||
* @param aircraftVersion: Pointer to aircraft version.
|
||||
* @return Execution result.
|
||||
*/
|
||||
T_DjiReturnCode DjiAircraftInfo_GetAircraftVersion(T_DjiAircraftVersion *aircraftVersion);
|
||||
|
||||
@ -132,7 +132,13 @@ typedef T_DjiReturnCode (*JoystickCtrlAuthorityEventCbFunc)(
|
||||
T_DjiFlightControllerJoystickCtrlAuthorityEventInfo eventData);
|
||||
|
||||
/**
|
||||
* @brief Horizon control mode enum in joystick mode
|
||||
* @brief Prototype of callback function used to get the trigger FTS event.
|
||||
* @return Execution result.
|
||||
*/
|
||||
typedef T_DjiReturnCode (*TriggerFtsEventCallback)(void);
|
||||
|
||||
/**
|
||||
* @brief Horizon control mode in joystick mode enum
|
||||
* @note Only when the GPS signal is good (health_flag >=3),horizontal position control (DJI_FLIGHT_CONTROLLER_HORIZONTAL_POSITION_CONTROL_MODE)
|
||||
* related control modes can be used. Only when GPS signal is good (health_flag >=3),or advanced sensing system is working properly with Autopilot,
|
||||
* horizontal velocity control(DJI_FLIGHT_CONTROLLER_HORIZONTAL_VELOCITY_CONTROL_MODE) related control modes can be used.
|
||||
@ -633,6 +639,16 @@ DjiFlightController_SetRCLostActionEnableStatus(E_DjiFlightControllerRCLostActio
|
||||
T_DjiReturnCode
|
||||
DjiFlightController_GetEnableRCLostActionStatus(E_DjiFlightControllerRCLostActionEnableStatus *command);
|
||||
|
||||
/**
|
||||
* @brief Register callback function for the trigger FTS event.
|
||||
* @note The timing of the trigger of the callback function of the FTS is determined by the aircraft, and the trigger
|
||||
* execution action of the FTS needs to be implemented in the callback function and the correct return value
|
||||
* must be returned, otherwise the aircraft will always be triggered.
|
||||
* @param callback: the callback for the trigger FTS event.
|
||||
* @return Execution result.
|
||||
*/
|
||||
T_DjiReturnCode DjiFlightController_RegTriggerFtsEventCallback(TriggerFtsEventCallback callback);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@ -52,7 +52,7 @@ typedef struct {
|
||||
/* Exported functions --------------------------------------------------------*/
|
||||
/**
|
||||
* @brief Initialize the gimbal manager module.
|
||||
* @note This interface must be initialized after DjiCore_Init..
|
||||
* @note This interface must be initialized after DjiCore_Init.
|
||||
* @return Execution result.
|
||||
*/
|
||||
T_DjiReturnCode DjiGimbalManager_Init(void);
|
||||
|
||||
@ -215,10 +215,8 @@ typedef enum {
|
||||
*/
|
||||
typedef enum {
|
||||
DJI_MOBILE_APP_SCREEN_TYPE_UNKNOWN = 255, /*!< Mobile APP screen type is unknown. */
|
||||
DJI_MOBILE_APP_SCREEN_TYPE_BIG_SCREEN = 0, /*!< The big screen of mobile device refers to a screen
|
||||
* size greater than or equal to 6 inches. */
|
||||
DJI_MOBILE_APP_SCREEN_TYPE_LITTLE_SCREEN = 1, /*!< The little screen of mobile device refers to a
|
||||
* screen size less than 6 inches. */
|
||||
DJI_MOBILE_APP_SCREEN_TYPE_BIG_SCREEN = 0, /*!< Screen size is 6 inches or larger. */
|
||||
DJI_MOBILE_APP_SCREEN_TYPE_LITTLE_SCREEN = 1, /*!< Screen size is less than 6 inches. */
|
||||
} E_DjiMobileAppScreenType;
|
||||
|
||||
/**
|
||||
@ -250,7 +248,7 @@ typedef enum {
|
||||
DJI_SDK_ADAPTER_TYPE_UNKNOWN = 0, /*!< SDK adapter type is unknown. */
|
||||
DJI_SDK_ADAPTER_TYPE_SKYPORT_V2 = 1, /*!< SDK adapter type is Skyport V2. */
|
||||
DJI_SDK_ADAPTER_TYPE_XPORT = 2, /*!< SDK adapter type is X-Port. */
|
||||
DJI_SDK_ADAPTER_TYPE_NONE = 3, /*!< don't have any adapter outside */
|
||||
DJI_SDK_ADAPTER_TYPE_NONE = 3, /*!< No external adapter is connected. */
|
||||
} E_DjiSdkAdapterType;
|
||||
|
||||
typedef enum {
|
||||
@ -268,56 +266,47 @@ typedef enum {
|
||||
* @brief Camera focus target point when in focus mode.
|
||||
*/
|
||||
typedef struct {
|
||||
dji_f32_t focusX; /*!< Specifies horizontal zone coordinate. This parameter is between 0 and 1.
|
||||
The point [0.0, 0.0] represents the top-left angle of the screen.*/
|
||||
dji_f32_t focusY; /*!< Specifies vertical zone coordinate. This parameter is between 0 and 1. */
|
||||
dji_f32_t focusX; /*!< Specifies the horizontal coordinate within the zone. Range: 0 to 1.
|
||||
The point [0.0, 0.0] represents the top-left corner of the screen.*/
|
||||
dji_f32_t focusY; /*!< Specifies vertical zone coordinate. Range: 0 to 1. */
|
||||
} T_DjiCameraPointInScreen;
|
||||
|
||||
/**
|
||||
* @brief Camera time interval settings when in interval shootPhoto mode.
|
||||
* @brief Camera time interval settings for interval shoot-photo mode.
|
||||
*/
|
||||
typedef struct {
|
||||
uint8_t captureCount; /*!< Specifies the total capture count of interval settings.
|
||||
* 0:reserve 1~254:number 255:keep capturing till stop */
|
||||
* 0: reserved, 1-254: specific number, 255: continuous capture until stopped. */
|
||||
uint16_t timeIntervalSeconds; /*!< Specifies the interval time between two captures, unit: s*/
|
||||
} T_DjiCameraPhotoTimeIntervalSettings;
|
||||
|
||||
/**
|
||||
* @brief Camera zoom speed.
|
||||
* @brief Camera zoom speeds.
|
||||
*/
|
||||
typedef enum {
|
||||
DJI_CAMERA_ZOOM_SPEED_SLOWEST = 72, /*!< Lens zooms in slowest speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_SLOW = 73, /*!< Lens zooms in slow speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_MODERATELY_SLOW = 74, /*!< Lens zooms in speed slightly slower than normal speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_NORMAL = 75, /*!< Lens zooms in normal speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_MODERATELY_FAST = 76, /*!< Lens zooms very in speed slightly faster than normal speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_FAST = 77, /*!< Lens zooms very in fast speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_FASTEST = 78, /*!< Lens zooms very in fastest speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_SLOWEST = 72, /*!< Slowest zoom speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_SLOW = 73, /*!< Slow zoom speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_MODERATELY_SLOW = 74, /*!< Slightly slower than normal zoom speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_NORMAL = 75, /*!< Normal zoom speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_MODERATELY_FAST = 76, /*!< Slightly faster than normal zoom speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_FAST = 77, /*!< Fast zoom speed. */
|
||||
DJI_CAMERA_ZOOM_SPEED_FASTEST = 78, /*!< Fastest zoom speed. */
|
||||
} E_DjiCameraZoomSpeed;
|
||||
|
||||
typedef enum {
|
||||
/*! The number of pictures to continuously take each time in BURST mode is 2
|
||||
*/
|
||||
/*! The burst mode can capture 2 pictures per trigger. */
|
||||
DJI_CAMERA_BURST_COUNT_2 = 2,
|
||||
/*! The number of pictures to continuously take each time in BURST mode is 3
|
||||
*/
|
||||
/*! The burst mode can capture 3 pictures per trigger. */
|
||||
DJI_CAMERA_BURST_COUNT_3 = 3,
|
||||
/*! The number of pictures to continuously take each time in BURST mode is 5
|
||||
*/
|
||||
/*! The burst mode can capture 5 pictures per trigger. */
|
||||
DJI_CAMERA_BURST_COUNT_5 = 5,
|
||||
/*! The number of pictures to continuously take each time in BURST mode is 7
|
||||
*/
|
||||
/*! The burst mode can capture 7 pictures per trigger. */
|
||||
DJI_CAMERA_BURST_COUNT_7 = 7,
|
||||
/*! The number of pictures to continuously take at one time in BURST mode is
|
||||
* 10, Only supported by X4S camera, X5S camera and Phantom 4 Pro camera.
|
||||
*/
|
||||
/*! Supports capturing 10 pictures per trigger, only supported by X4S, X5S cameras, and Phantom 4 Pro. */
|
||||
DJI_CAMERA_BURST_COUNT_10 = 10,
|
||||
/*! The number of pictures to continuously take at one time in BURST mode is
|
||||
* 14, Only supported by X4S camera, X5S camera and Phantom 4 Pro camera.
|
||||
*/
|
||||
/*! Supports capturing 14 pictures per trigger, only supported by X4S, X5S cameras, and Phantom 4 Pro. */
|
||||
DJI_CAMERA_BURST_COUNT_14 = 14,
|
||||
/*! The camera burst shoot count value is unknown.
|
||||
*/
|
||||
/*! Unknown burst count. */
|
||||
DJI_CAMERA_BURST_COUNT_KNOWN = 0xFF,
|
||||
} E_DjiCameraBurstCount;
|
||||
|
||||
@ -325,8 +314,8 @@ typedef enum {
|
||||
* @brief Camera zoom direction.
|
||||
*/
|
||||
typedef enum {
|
||||
DJI_CAMERA_ZOOM_DIRECTION_OUT = 0, /*!< The lens moves in the far direction, the zoom factor becomes smaller. */
|
||||
DJI_CAMERA_ZOOM_DIRECTION_IN = 1, /*!< The lens moves in the near direction, the zoom factor becomes larger. */
|
||||
DJI_CAMERA_ZOOM_DIRECTION_OUT = 0, /*!< Zooms out, reducing the zoom factor. */
|
||||
DJI_CAMERA_ZOOM_DIRECTION_IN = 1, /*!< Zooms in, increasing the zoom factor. */
|
||||
} E_DjiCameraZoomDirection;
|
||||
#pragma pack (1)
|
||||
|
||||
@ -354,55 +343,70 @@ typedef struct {
|
||||
bool busyState;
|
||||
} T_DjiDataChannelState;
|
||||
|
||||
typedef struct Vector3d {
|
||||
int32_t x; /*!< Specifies int32 value of x for vector. */
|
||||
int32_t y; /*!< Specifies int32 value of y for vector. */
|
||||
int32_t z; /*!< Specifies int32 value of z for vector. */
|
||||
/**
|
||||
* @brief Represents a vector using int32 coordinates.
|
||||
*/
|
||||
typedef struct Vector3d{
|
||||
int32_t x; /*!< X-coordinate of the vector. */
|
||||
int32_t y; /*!< Y-coordinate of the vector. */
|
||||
int32_t z; /*!< Z-coordinate of the vector. */
|
||||
} T_DjiVector3d;
|
||||
|
||||
typedef struct Vector3f {
|
||||
dji_f32_t x; /*!< Specifies float value of x for vector. */
|
||||
dji_f32_t y; /*!< Specifies float value of y for vector. */
|
||||
dji_f32_t z; /*!< Specifies float value of z for vector. */
|
||||
/**
|
||||
* @brief Represents a vector using floating-point coordinates.
|
||||
*/
|
||||
typedef struct Vector3f{
|
||||
dji_f32_t x; /*!< X-coordinate of the vector. */
|
||||
dji_f32_t y; /*!< Y-coordinate of the vector. */
|
||||
dji_f32_t z; /*!< Z-coordinate of the vector. */
|
||||
} T_DjiVector3f;
|
||||
|
||||
/**
|
||||
* @brief Represents an attitude using int32 values for pitch, roll, and yaw.
|
||||
*/
|
||||
typedef struct {
|
||||
int32_t pitch; /*!< Specifies int32 value of pitch for attitude. */
|
||||
int32_t roll; /*!< Specifies int32 value of roll for attitude */
|
||||
int32_t yaw; /*!< Specifies int32 value of yaw for attitude */
|
||||
int32_t pitch; /*!< Pitch angle in degrees. */
|
||||
int32_t roll; /*!< Roll angle in degrees. */
|
||||
int32_t yaw; /*!< Yaw angle in degrees. */
|
||||
} T_DjiAttitude3d;
|
||||
|
||||
/**
|
||||
* @brief Represents an attitude using floating-point values for pitch, roll, and yaw.
|
||||
*/
|
||||
typedef struct {
|
||||
dji_f32_t pitch; /*!< Specifies float value of pitch for attitude. */
|
||||
dji_f32_t roll; /*!< Specifies float value of roll for attitude */
|
||||
dji_f32_t yaw; /*!< Specifies float value of yaw for attitude */
|
||||
dji_f32_t pitch; /*!< Pitch angle in degrees. */
|
||||
dji_f32_t roll; /*!< Roll angle in degrees. */
|
||||
dji_f32_t yaw; /*!< Yaw angle in degrees. */
|
||||
} T_DjiAttitude3f;
|
||||
|
||||
/**
|
||||
* @brief Represents a quaternion, when converted to a rotation matrix or Euler angles.
|
||||
*/
|
||||
typedef struct {
|
||||
dji_f32_t q0; /*!< w, when converted to a rotation matrix or Euler angles. */
|
||||
dji_f32_t q1; /*!< x, when converted to a rotation matrix or Euler angles. */
|
||||
dji_f32_t q2; /*!< y, when converted to a rotation matrix or Euler angles. */
|
||||
dji_f32_t q3; /*!< z, when converted to a rotation matrix or Euler angles. */
|
||||
dji_f32_t q0; /*!< Quaternion component w. */
|
||||
dji_f32_t q1; /*!< Quaternion component x. */
|
||||
dji_f32_t q2; /*!< Quaternion component y. */
|
||||
dji_f32_t q3; /*!< Quaternion component z. */
|
||||
} T_DjiQuaternion4f;
|
||||
|
||||
/**
|
||||
* @brief Timestamp data structure.
|
||||
*/
|
||||
typedef struct {
|
||||
uint32_t millisecond; /*!< Millisecond. */
|
||||
uint32_t microsecond; /*!< Microsecond. */
|
||||
uint32_t millisecond;
|
||||
uint32_t microsecond;
|
||||
} T_DjiDataTimestamp;
|
||||
|
||||
/**
|
||||
* @brief The firmware version of payload.
|
||||
* @note If majorVersion = AA, minorVersion = BB, modifyVersion = CC, debugVersion = DD, The version show in
|
||||
* terminal APP is AA.BB.CC.DD
|
||||
* @note The firmware version is displayed as AA.BB.CC.DD where AA is majorVersion,
|
||||
* BB is minorVersion, CC is modifyVersion, and DD is debugVersion.
|
||||
*/
|
||||
typedef struct {
|
||||
uint8_t majorVersion; /*!< The major version of firmware, the range is 0 ~ 99. */
|
||||
uint8_t minorVersion; /*!< The minor version of firmware, the range is 0 ~ 99. */
|
||||
uint8_t modifyVersion; /*!< The modify version of firmware, the range is 0 ~ 99. */
|
||||
uint8_t debugVersion; /*!< The debug version of firmware, the range is 0 ~ 99. */
|
||||
uint8_t majorVersion; /*!< Major version number, ranging from 0 to 99. */
|
||||
uint8_t minorVersion; /*!< Minor version number, ranging from 0 to 99. */
|
||||
uint8_t modifyVersion; /*!< Modification version number, ranging from 0 to 99. */
|
||||
uint8_t debugVersion; /*!< Debug version number, ranging from 0 to 99. */
|
||||
} T_DjiFirmwareVersion;
|
||||
|
||||
#pragma pack ()
|
||||
|
||||
@ -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 9 /*!< 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 2044 /*!< DJI SDK version build info, when jenkins trigger build changes. Range from 0 to 65535. */
|
||||
#define DJI_VERSION_BUILD 2090 /*!< DJI SDK version build info, when jenkins trigger build changes. Range from 0 to 65535. */
|
||||
|
||||
/* Exported types ------------------------------------------------------------*/
|
||||
|
||||
|
||||
Reference in New Issue
Block a user