diff --git a/LICENSE.txt b/LICENSE.txt index c7c40de..4da8180 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -19,6 +19,7 @@ The following portions of the DJI’s Payload SDK (“Software” referred to in │   ├── M30T.stp │   ├── M3E.stp │   ├── PSDK Mounting Bracket(Payload).stp +│   ├── Readme.txt │   ├── Skyport_Adapter_2.stp │   └── X-Port 80mm.stp ├── EULA.txt @@ -670,6 +671,7 @@ The following portions of the DJI’s Payload SDK (“Software” referred to in │   │   │   │   ├── STM32F407VGTX_FLASH.ld │   │   │   │   └── stm32f4discovery.cfg │   │   │   ├── mdk +│   │   │   │   ├── mdk_app.sct │   │   │   │   └── mdk_app.uvprojx │   │   │   └── mdk_bootloader │   │   │   └── mdk_bootloader.uvprojx diff --git a/README.md b/README.md index da7280b..a31f112 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # DJI Payload SDK (PSDK) -![](https://img.shields.io/badge/version-V3.8.1-purple.svg) -![](https://img.shields.io/badge/platform-linux_|_rtos-green.svg) +![](https://img.shields.io/badge/version-V3.9.0-pink.svg) +![](https://img.shields.io/badge/platform-linux_|_rtos-cyan.svg) ![](https://img.shields.io/badge/license-MIT-blue.svg) ## What is the DJI Payload SDK? @@ -23,22 +23,23 @@ to get the latest version information. ## Latest Release -The latest release version of PSDK is 3.8.1. This version of Payload SDK mainly add some new features support and fixed some +The latest release version of PSDK is 3.9.0. 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. -* Removed the camera management module interface DjiCameraManager_GetPhotoBurstCount. -* Removed the AEB photography function in the camera management module. -* Fixed the issue where subscribing to real-time point cloud data was not byte-aligned on some platforms. -* Fixed the discrepancy between flight speed units and annotations in the motion planning WP 2.0 feature. -* Fixed issues with obtaining the camera shooting mode and zoom magnification on the Mavic 3 series drones. -* Optimized the startup time for PSDK initialization. -* Complemented the flight control topic CONTROL_DEVICE data structure definition and added related enumeration ranges. -* Fixed the incorrect zoom multiplier retrieval for the H20N camera. -* Fixed the issue where custom media file suffix names were not taking effect. -* Fixed the occasional subscription errors for single battery data in the M300 RTK and M350 RTK. -* Fixed anomalous Pilot widget values for the M30 series, M300 RTK, and M350 RTK remote controllers. -* Note: Streamlined the toolchain for compiling PSDK, removing low-usage toolchain libraries. -> We have stopped offering some toolchains on GitHub. If you have trouble building your project, reach out to the SDK Support Team for help. +* Supports the payload camera Zenmuse H30 series. +* FlyCart 30 aircraft supports the time synchronization function. +* FlyCart 30 aircraft supports HMS functions. +* FlyCart 30 aircraft supports the data subscription function. +* Fixed the issue with inaccurate zoom multiplier retrieval for the Mavic 3 Enterprise series cameras. +* Fixed data errors on the receiving end of small data transfers from MSDK to PSDK. +* Fixed the inability of devices at payload ports 2 and 3 of the M300 RTK aircraft to perform small data transmission to devices connected to the OSDK port. +* Fixed the issue where MSDK V5 and PSDK devices could not perform small data transmission when using M300 RTK and M350 RTK aircraft. +* Fixed occasional payload negotiation failures between PSDK and the M350 RTK aircraft. +* Fixed screen flickering and glitching issues with the H20T payload camera's video stream. +* Fixed issues with retrieving the visible light camera video stream from the M3TD camera. +* Optimized the C++ camera management sample. +* Optimized memory usage strategy for STM32 platform sample by introducing CCMRAM. +> Note: For M300 RTK and M350 RTK, the camera management module now checks the payload port device's status at startup. This may occasionally result in log errors. Normal function is not affected, and this will be optimized in a future release. ## License diff --git a/psdk_lib/include/dji_camera_manager.h b/psdk_lib/include/dji_camera_manager.h index 99dfde5..9e0c182 100644 --- a/psdk_lib/include/dji_camera_manager.h +++ b/psdk_lib/include/dji_camera_manager.h @@ -133,7 +133,7 @@ typedef enum { DJI_CAMERA_MANAGER_EXPOSURE_MODE_EXPOSURE_UNKNOWN = 0xFF /*!< The camera exposure mode is unknown. */ } E_DjiCameraManagerExposureMode; -/*! @breif CameraModule focus mode. If the physical AF switch on the camera is +/*! @brief CameraModule focus mode. If the physical AF switch on the camera is * set to auto. */ typedef enum { @@ -160,7 +160,7 @@ typedef enum { DJI_CAMERA_MANAGER_FOCUS_MODE_UNKNOWN = 0xFF, } E_DjiCameraManagerFocusMode; -/*! @breif CameraModule shutter mode. +/*! @brief CameraModule shutter mode. */ typedef enum { /*! The shutter mode of camera is automatical */ @@ -251,21 +251,21 @@ typedef enum { DJI_CAMERA_MANAGER_ISO_AUTO = 0x00, /*! The ISO value is set to 100. */ DJI_CAMERA_MANAGER_ISO_100 = 0x03, - /*! The ISO value is set to 100. */ + /*! The ISO value is set to 200. */ DJI_CAMERA_MANAGER_ISO_200 = 0x04, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 400.*/ DJI_CAMERA_MANAGER_ISO_400 = 0x05, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 800.*/ DJI_CAMERA_MANAGER_ISO_800 = 0x06, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 1600.*/ DJI_CAMERA_MANAGER_ISO_1600 = 0x07, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 3200.*/ DJI_CAMERA_MANAGER_ISO_3200 = 0x08, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 6400.*/ DJI_CAMERA_MANAGER_ISO_6400 = 0x09, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 12800.*/ DJI_CAMERA_MANAGER_ISO_12800 = 0x0A, - /*! The ISO value is set to 100.*/ + /*! The ISO value is set to 25600.*/ DJI_CAMERA_MANAGER_ISO_25600 = 0x0B, /*! ISO value is fixed by the camera firmware. When the camera color is set to D_LOG, camera will fix the ISO to a specific value in order to optimize @@ -563,7 +563,7 @@ typedef enum { DJI_CAMERA_MANAGER_PHOTO_STORAGE_FORMAT_RAW = 0, DJI_CAMERA_MANAGER_PHOTO_STORAGE_FORMAT_JPEG = 1, DJI_CAMERA_MANAGER_PHOTO_STORAGE_FORMAT_RAW_JPEG = 2, - DJI_CAMERA_MANAGER_PHOTO_STORAGE_FORMAT_YUV = 3, // 保存为YUV格式的图片 + DJI_CAMERA_MANAGER_PHOTO_STORAGE_FORMAT_YUV = 3, // Save as YUV format image DJI_CAMERA_MANAGER_PHOTO_STORAGE_FORMAT_RJPEG = 7, // Radiometric JPEG } E_DjiCameraManagerPhotoStorageFormat; @@ -590,13 +590,13 @@ typedef enum { } E_DjiCameraManagerIrGainMode; typedef enum { - /* not capturing*/ + /* Camera is not capturing photos*/ DJI_CAMERA_MANAGER_CAPTURING_STATE_IDLE = 0, - /* doing single capture */ + /* Camera is capturing a single photo */ DJI_CAMERA_MANAGER_CAPTURING_STATE_SINGLE = 1, - /* doing multi capture */ + /* Camera is capturing multiple photos */ DJI_CAMERA_MANAGER_CAPTURING_STATE_MULTI = 2, } E_DjiCameraManagerCapturingState; @@ -607,24 +607,24 @@ typedef enum { DJI_CAMERA_MANAGER_RECORDING_STATE_STOPPING = 3, } E_DjiCameraManagerRecordingState; -/*!< Attention: when the remote control is in split-screen mode, the coordinate range of the x-axis is 0 ~ 0.5 -* */ +/*! @brief: when the remote control is in split-screen mode, the coordinate range of the x-axis is 0-0.5. + */ typedef struct { - dji_f32_t pointX; /*! x-coordinate of point thermometry, range: 0 ~ 1 */ - dji_f32_t pointY; /*! y-coordinate of point thermometry, range: 0 ~ 1 */ + dji_f32_t pointX; /*! x-coordinate of point thermometry, range: 0-1 */ + dji_f32_t pointY; /*! y-coordinate of point thermometry, range: 0-1 */ } T_DjiCameraManagerPointThermometryCoordinate; typedef struct { - dji_f32_t areaTempLtX; /*! x-coordinate of the upper left corner of the area thermometry, range: 0 ~ 1 */ - dji_f32_t areaTempLtY; /*! y-coordinate of the upper left corner of the area thermometry, range: 0 ~ 1 */ - dji_f32_t areaTempRbX; /*! x-coordinate of the lower right corner of the area thermometry, range: 0 ~ 1 */ - dji_f32_t areaTempRbY; /*! y-coordinate of the lower right corner of the area thermometry, range: 0 ~ 1 */ + dji_f32_t areaTempLtX; /*! x-coordinate of the upper left corner of the area thermometry, range: 0-1 */ + dji_f32_t areaTempLtY; /*! y-coordinate of the upper left corner of the area thermometry, range: 0-1 */ + dji_f32_t areaTempRbX; /*! x-coordinate of the lower right corner of the area thermometry, range: 0-1 */ + dji_f32_t areaTempRbY; /*! y-coordinate of the lower right corner of the area thermometry, range: 0-1 */ } T_DjiCameraManagerAreaThermometryCoordinate; //result of point thermometry typedef struct { - dji_f32_t pointX; /*! x-coordinate of point thermometry, range: 0 ~ 1 */ - dji_f32_t pointY; /*! y-coordinate of point thermometry, range: 0 ~ 1 */ + dji_f32_t pointX; /*! x-coordinate of point thermometry, range: 0-1 */ + dji_f32_t pointY; /*! y-coordinate of point thermometry, range: 0-1 */ dji_f32_t pointTemperature; /*! The temperature of the current point */ } T_DjiCameraManagerPointThermometryData; @@ -744,7 +744,7 @@ T_DjiReturnCode DjiCameraManager_DeInit(void); /** * @brief Get camera type of the selected camera mounted position. * @param position: camera mounted position - * @param cameraType: see references of E_DjiCameraType. + * @param cameraType: refer to E_DjiCameraType. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetCameraType(E_DjiMountPosition position, E_DjiCameraType *cameraType); @@ -752,16 +752,16 @@ T_DjiReturnCode DjiCameraManager_GetCameraType(E_DjiMountPosition position, E_Dj /** * @brief Get camera firmware version of the selected camera mounted position. * @param position: camera mounted position - * @param firmwareVersion: see references of T_DjiCameraManagerFirmwareVersion. + * @param firmwareVersion: refer to T_DjiCameraManagerFirmwareVersion. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetFirmwareVersion(E_DjiMountPosition position, T_DjiCameraManagerFirmwareVersion *firmwareVersion); /** - * @brief Get camera connect status. + * @brief Get camera connection status. * @param position: camera mounted position - * @param connectStatus: returned value of connect status + * @param connectStatus: returned value of connection status * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetCameraConnectStatus(E_DjiMountPosition position, @@ -769,11 +769,11 @@ T_DjiReturnCode DjiCameraManager_GetCameraConnectStatus(E_DjiMountPosition posit /** * @brief Set camera working mode of the selected camera mounted position. - * @note Set the camera's work mode to taking pictures, video, playback or - * download and so on. Please note that you cannot change the mode when a certain task - * is executing.This action will cost about 1~2s. + * @note Set the camera's work mode to options such as taking pictures, recording video, + * playback, or downloading. Please note that you cannot change the mode when a certain + * task is executing. This action takes about 1-2 s. * @param position: camera mounted position - * @param workMode: see reference of E_DjiCameraManagerWorkMode. + * @param workMode: refer to E_DjiCameraManagerWorkMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetMode(E_DjiMountPosition position, @@ -782,7 +782,7 @@ T_DjiReturnCode DjiCameraManager_SetMode(E_DjiMountPosition position, /** * @brief Get camera working mode of the selected camera mounted position. * @param position: camera mounted position - * @param workMode: see reference of E_DjiCameraManagerWorkMode. + * @param workMode: refer to E_DjiCameraManagerWorkMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetMode(E_DjiMountPosition position, @@ -791,7 +791,7 @@ T_DjiReturnCode DjiCameraManager_GetMode(E_DjiMountPosition position, /** * @brief Set camera shoot mode of the selected camera mounted position. * @param position: camera mounted position -* @param mode: see reference of E_DjiCameraManagerShootPhotoMode. +* @param mode: refer to E_DjiCameraManagerShootPhotoMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetShootPhotoMode(E_DjiMountPosition position, @@ -800,30 +800,29 @@ T_DjiReturnCode DjiCameraManager_SetShootPhotoMode(E_DjiMountPosition position, /** * @brief Get camera shoot mode of the selected camera mounted position. * @param position: camera mounted position -* @param mode: see reference of E_DjiCameraManagerShootPhotoMode. +* @param mode: refer to E_DjiCameraManagerShootPhotoMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetShootPhotoMode(E_DjiMountPosition position, E_DjiCameraManagerShootPhotoMode *takePhotoMode); /** - * @brief Start to shoot photo. - * @note Camera must be in ShootPhoto mode. For thermal imaging camera, - * Single photo can be taken while recording video. The SD card state should - * be checked before this method is used to ensure sufficient space exists. + * @brief Start shooting photo. + * @note Camera must be in ShootPhoto mode. For thermal imaging cameras, + * it is allowed to take a single photo while recording video. Check the SD + * card's capacity before using this method to ensure there is enough space. * @param position: camera mounted position - * @param mode: see reference of E_DjiCameraManagerShootPhotoMode. + * @param mode: refer to E_DjiCameraManagerShootPhotoMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_StartShootPhoto(E_DjiMountPosition position, E_DjiCameraManagerShootPhotoMode mode); /** - * @brief Stop to shoot photo when you are in taking photo. - * @note StartShootPhoto has been invoked and the shoot mode is either - * Interval or Time-lapse. If the shoot mode is set to single, the camera - * will automatically stop taking the photo once the individual photo is - * taken. + * @brief Stop shooting photo. + * @note Camera must be in ShootPhoto mode and the shoot mode is either + * Interval or Time-lapse. If set to single shot mode, the camera will + * automatically stop after taking the photo. * @param position: camera mounted position * @return Execution result. */ @@ -831,7 +830,7 @@ T_DjiReturnCode DjiCameraManager_StopShootPhoto(E_DjiMountPosition position); /** * @brief Get camera capturing state. - * @note L1/P1 do not support this API. + * @note This API is not supported by L1/P1/M3D/M3TD models. * @param position: camera mounted position * @param capturingState: result of getting, see E_DjiCameraManagerCapturingState. * @return Execution result. @@ -840,39 +839,38 @@ T_DjiReturnCode DjiCameraManager_GetCapturingState(E_DjiMountPosition position, E_DjiCameraManagerCapturingState *capturingState); /** - * @brief Set the burst count in the burst take-photo mode. + * @brief Set the burst count for burst shooting mode. * @param position: camera mounted position - * @param count: see reference of E_DjiCameraBurstCount. + * @param count: refer to E_DjiCameraBurstCount. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetPhotoBurstCount(E_DjiMountPosition position, E_DjiCameraBurstCount count); /** - * @brief Set the parameters in the INTERVAL take-photo mode. - * @note When in this shoot-photo mode, The camera will capture a photo, wait - * a specified interval of time, take another photo, and continue in this - * manner until it has taken the required number of photos. Also supported by - * thermal imaging camera. + * @brief Set the parameters for INTERVAL shooting mode. + * @note In this mode, the camera captures a photo, waits a specified interval + * of time, then captures another photo, continuing until the set number of + * photos is reached. Supported by thermal imaging cameras, too. * @param position: camera mounted position - * @param intervalSetting: see reference of T_DjiCameraPhotoTimeIntervalSettings. + * @param intervalSetting: refer to T_DjiCameraPhotoTimeIntervalSettings. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetPhotoTimeIntervalSettings(E_DjiMountPosition position, T_DjiCameraPhotoTimeIntervalSettings intervalSetting); /** - * @brief Get the parameters in the INTERVAL take-photo mode. + * @brief Get the parameters for INTERVAL shooting mode. * @param position: camera mounted position - * @param intervalSetting: see reference of T_DjiCameraPhotoTimeIntervalSettings. + * @param intervalSetting: refer to T_DjiCameraPhotoTimeIntervalSettings. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetPhotoTimeIntervalSettings(E_DjiMountPosition position, T_DjiCameraPhotoTimeIntervalSettings *intervalSetting); /** - * @brief Get remain time of interval shooting. - * @note L1/P1 do not support this API. + * @brief Get the remaining time of interval shooting. + * @note Not supported by L1/P1/M3D/M3TD models. * @param position: camera mounted position * @param remainTime: time in seconds. * @return Execution result. @@ -882,12 +880,11 @@ T_DjiReturnCode DjiCameraManager_GetIntervalShootingRemainTime(E_DjiMountPositio /** * @brief Set camera focus mode of the selected camera mounted position. - * @note Set the lens focus mode. When the focus mode is auto, the target - * point is the focal point. When the focus mode is manual, the target point - * is the zoom out area if the focus assistant is enabled for the manual - * mode. + * @note Set the lens focus mode. In auto focus mode, the target + * point is the focal point. In manual focus mode, if focus assist is + * enabled, it adjusts focus in the zoomed-out area. * @param position: camera mounted position - * @param focusMode: see reference of E_DjiCameraManagerFocusMode. + * @param focusMode: refer to E_DjiCameraManagerFocusMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetFocusMode(E_DjiMountPosition position, @@ -895,29 +892,27 @@ T_DjiReturnCode DjiCameraManager_SetFocusMode(E_DjiMountPosition position, /** * @brief Get camera focus mode of the selected camera mounted position. * @param position: camera mounted position - * @param focusMode: see reference of E_DjiCameraManagerFocusMode. + * @param focusMode: refer to E_DjiCameraManagerFocusMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetFocusMode(E_DjiMountPosition position, E_DjiCameraManagerFocusMode *focusMode); /** - * @brief Set amera focus point of the selected camera mounted position. - * @note Sets the lens focus target point. When the focus mode is auto, the - * target point is the focal point. When the focus mode is manual, the target - * point is the zoom out area if the focus assistant is enabled for the manual - * mode. + * @brief Set camera focus point of the selected camera mounted position. + * @note Sets the target point for focusing. In auto mode, this is the focal + * point. In manual mode with focus assist enabled, it's the zoomed-out area. * @param position: camera mounted position - * @param focusPosData: see reference of T_DjiCameraManagerFocusPosData. + * @param focusPosData: refer to T_DjiCameraManagerFocusPosData. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetFocusTarget(E_DjiMountPosition position, T_DjiCameraManagerFocusPosData focusPosData); /** - * @brief Get amera focus point of the selected camera mounted position. + * @brief Get camera focus point of the selected camera mounted position. * @param position: camera mounted position - * @param focusPosData: see reference of T_DjiCameraManagerFocusPosData. + * @param focusPosData: refer to T_DjiCameraManagerFocusPosData. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetFocusTarget(E_DjiMountPosition position, @@ -925,13 +920,12 @@ T_DjiReturnCode DjiCameraManager_GetFocusTarget(E_DjiMountPosition position, /** * @brief Start camera optical zooming of the selected camera mounted position. - * @note Start changing the focal length of the lens in specified direction - * with specified speed. Focal length change (zooming) will halt when maximum - * or minimum focal lengths are reached, or DjiCameraManager_StopContinuousOpticalZoom* - * is called. + * @note Changes the lens's focal length in the specified direction at a specified + * speed. Zooming stops at the lens's max or min focal length or when + * StopContinuousOpticalZoom is called. * @param position: camera mounted position - * @param zoomDirection: optical zoom direction, see reference of E_DjiCameraZoomDirection. - * @param zoomSpeed: optical zoom direction, see reference of E_DjiCameraZoomSpeed. + * @param zoomDirection: optical zoom direction, refer to E_DjiCameraZoomDirection. + * @param zoomSpeed: optical zoom direction, refer to E_DjiCameraZoomSpeed. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_StartContinuousOpticalZoom(E_DjiMountPosition position, @@ -939,20 +933,19 @@ T_DjiReturnCode DjiCameraManager_StartContinuousOpticalZoom(E_DjiMountPosition p E_DjiCameraZoomSpeed zoomSpeed); /** - * @brief Stop camera optical zooming of the selected camera mounted position. - * @note Called to stop focal length changing, when it currently is from - * calling DjiCameraManager_StartContinuousOpticalZoom*. + * @brief Stop the ongoing optical zoom operation of the selected camera mounted position. + * @note Should be called to halt the focal length change initiated by + * DjiCameraManager_StartContinuousOpticalZoom. * @param position: camera mounted position * @return Execution result. */ T_DjiReturnCode DjiCameraManager_StopContinuousOpticalZoom(E_DjiMountPosition position); /** - * @brief Set parameters for camera optical zooming of the selected camera mounted position. - * @note In this interface, the zoom will set the zoom factor as the your - * target value. + * @brief Set target zoom factor for optical zooming of the selected camera mounted position. + * @note This interface sets the zoom to the specified target value. * @param position: camera mounted position - * @param zoomDirection: optical zoom direction, see reference of E_DjiCameraZoomDirection. + * @param zoomDirection: optical zoom direction, refer to E_DjiCameraZoomDirection. * @param factor: target zoom factor. * @return Execution result. */ @@ -963,14 +956,14 @@ T_DjiReturnCode DjiCameraManager_SetOpticalZoomParam(E_DjiMountPosition position /** * @brief Get parameters for camera optical zooming of the selected camera mounted position. * @param position: camera mounted position - * @param opticalZoomParam: see reference of T_DjiCameraManagerOpticalZoomParam. + * @param opticalZoomParam: refer to T_DjiCameraManagerOpticalZoomParam. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetOpticalZoomParam(E_DjiMountPosition position, T_DjiCameraManagerOpticalZoomParam *opticalZoomParam); /** - * @brief Set parameters for camera infrared zooming of the selected camera mounted position. + * @brief Set target zoom factor for infrared zooming of the selected camera mounted position. * @param position: camera mounted position * @param factor: target zoom factor. * @return Execution result. @@ -979,7 +972,7 @@ T_DjiReturnCode DjiCameraManager_SetInfraredZoomParam(E_DjiMountPosition positio dji_f32_t factor); /** - * @brief Enable/Disable camera's tap-zoom function of the selected camera mounted position. + * @brief Enable/Disable the tap-zoom function for the selected camera mounted position. * @note TapZoomAtTarget can only be called when tap-zoom is enabled. * @param position: camera mounted position * @param param: enable/disable @@ -998,8 +991,8 @@ T_DjiReturnCode DjiCameraManager_GetTapZoomEnabled(E_DjiMountPosition position, /** * @brief Set camera's tap-zoom multiplier of the selected camera mounted position. - * @note Tap-zoom uses a multiplier to change the zoom scale when called. The - * inal zoom scale for a TapZoom will be: Current Zoom Scale x Multiplier. + * @note The final zoom scale during a tap-zoom action will be: + * Current Zoom Scale x Multiplier. * @param position: camera mounted position * @param tapZoomMultiplier: The multiplier range is [1,5]. A multiplier of 1 will not change the zoom. * hen the multiplier is 1, the zoom scale will not change during TapZoom. @@ -1018,12 +1011,11 @@ T_DjiReturnCode DjiCameraManager_GetTapZoomMultiplier(E_DjiMountPosition positio /** * @brief Set camera's tap-zoom point of the selected camera mounted position. - * @note Tap-zoom at the target. It can be called only when TapZoom is - * enabled. When a new target is set, the gimbal will rotate and locate the - * target in the center of the screen. At the same time, the camera will zoom - * by multiplying the TapZoom multiplier + * @note Only available when tap-zoom is enabled. Sets a new target, + * reorienting the gimbal to locate the target on the screen center and + * applying the tap-zoom multiplier. * @param position: camera mounted position - * @param tapZoomPos: see reference of T_DjiCameraManagerTapZoomPosData. + * @param tapZoomPos: refer to T_DjiCameraManagerTapZoomPosData. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_TapZoomAtTarget(E_DjiMountPosition position, @@ -1058,11 +1050,11 @@ T_DjiReturnCode DjiCameraManager_GetFocusRingValue(E_DjiMountPosition position, /** * @brief Set camera's exposure mode of the selected camera mounted position. - * @note The different exposure modes define whether aperture, shutter speed, - * ISO can be set automatically or manually. Exposure compensation can be - * changed in all modes except manual mode where it is not settable. + * @note Different exposure modes define whether settings like aperture, shutter + * speed, and ISO are set automatically or manually. Exposure compensation is + * adjustable in all modes except the manual mode. * @param position: camera mounted position - * @param mode: see reference of E_DjiCameraManagerExposureMode. + * @param mode: refer to E_DjiCameraManagerExposureMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetExposureMode(E_DjiMountPosition position, @@ -1070,11 +1062,11 @@ T_DjiReturnCode DjiCameraManager_SetExposureMode(E_DjiMountPosition position, /** * @brief Get camera's exposure mode of the selected camera mounted position. - * @note The different exposure modes define whether aperture, shutter speed, - * ISO can be set automatically or manually. Exposure compensation can be - * changed in all modes except manual mode where it is not settable. + * @note Different exposure modes define whether settings like aperture, shutter + * speed, and ISO are set automatically or manually. Exposure compensation is + * adjustable in all modes except the manual mode. * @param position: camera mounted position - * @param mode: see reference of E_DjiCameraManagerExposureMode. + * @param mode: refer to E_DjiCameraManagerExposureMode. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetExposureMode(E_DjiMountPosition position, @@ -1085,7 +1077,7 @@ T_DjiReturnCode DjiCameraManager_GetExposureMode(E_DjiMountPosition position, * @note ISO value can only be set when the camera exposure mode is in * manual mode. * @param position: camera mounted position - * @param iso: see reference of E_DjiCameraManagerISO. + * @param iso: refer to E_DjiCameraManagerISO. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetISO(E_DjiMountPosition position, @@ -1094,7 +1086,7 @@ T_DjiReturnCode DjiCameraManager_SetISO(E_DjiMountPosition position, /** * @brief Get camera's iso value of the selected camera mounted position. * @param position: camera mounted position - * @param iso: see reference of E_DjiCameraManagerISO. + * @param iso: refer to E_DjiCameraManagerISO. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetISO(E_DjiMountPosition position, @@ -1102,10 +1094,10 @@ T_DjiReturnCode DjiCameraManager_GetISO(E_DjiMountPosition position, /** * @brief Set camera's aperture size value of the selected camera mounted position. - * @note The exposure mode must be in DJI_CAMERA_MANAGER_EXPOSURE_MODE_EXPOSURE_MANUAL or + * @note The exposure mode must be on DJI_CAMERA_MANAGER_EXPOSURE_MODE_EXPOSURE_MANUAL or * DJI_CAMERA_MANAGER_EXPOSURE_MODE_APERTURE_PRIORITY. * @param position: camera mounted position - * @param aperture: see reference of E_DjiCameraManagerAperture. + * @param aperture: refer to E_DjiCameraManagerAperture. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetAperture(E_DjiMountPosition position, @@ -1114,22 +1106,22 @@ T_DjiReturnCode DjiCameraManager_SetAperture(E_DjiMountPosition position, /** * @brief Get camera's aperture size value of the selected camera mounted position. * @param position: camera mounted position - * @param aperture: see reference of E_DjiCameraManagerAperture. + * @param aperture: refer to E_DjiCameraManagerAperture. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetAperture(E_DjiMountPosition position, E_DjiCameraManagerAperture *aperture); /** - * @brief Set camera's shutter value of the selected camera mounted position. - * @note Set the camera shutter speed. The shutter speed should not be set + * @brief Set camera's shutter speed value of the selected camera mounted position. + * @note Set the camera shutter speed. Ensure the shutter speed is not set * slower than the video frame rate when the camera's mode is RECORD_VIDEO. * For example, if the video frame rate is 30fps, the shutterSpeed must be <= * 1/30. Precondition: The shutter speed can be set only when the camera * exposure mode is DJI_CAMERA_MANAGER_EXPOSURE_MODE_EXPOSURE_MANUAL mode or * DJI_CAMERA_MANAGER_EXPOSURE_MODE_SHUTTER_PRIORITY * @param position: camera mounted position - * @param shutterSpeed: see reference of E_DjiCameraManagerShutterSpeed. + * @param shutterSpeed: refer to E_DjiCameraManagerShutterSpeed. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetShutterSpeed(E_DjiMountPosition position, @@ -1138,7 +1130,7 @@ T_DjiReturnCode DjiCameraManager_SetShutterSpeed(E_DjiMountPosition position, /** * @brief Get camera's shutter value of the selected camera mounted position. * @param position: camera mounted position - * @param shutterSpeed: see reference of E_DjiCameraManagerShutterSpeed. + * @param shutterSpeed: refer to E_DjiCameraManagerShutterSpeed. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetShutterSpeed(E_DjiMountPosition position, @@ -1146,13 +1138,12 @@ T_DjiReturnCode DjiCameraManager_GetShutterSpeed(E_DjiMountPosition position, /** * @brief Set camera's EV value of the selected camera mounted position. - * @note Set the camera's exposure compensation. In order to use this - * function, set the camera exposure mode to shutter, program or aperture. - * exposure mode is DJI_CAMERA_MANAGER_EXPOSURE_MODE_EXPOSURE_MANUAL mode or - * DJI_CAMERA_MANAGER_EXPOSURE_MODE_SHUTTER_PRIORITY or + * @note This function is available in program, shutter, or aperture + * exposure modes. Enums are DJI_CAMERA_MANAGER_EXPOSURE_MODE_EXPOSURE_MANUAL, + * DJI_CAMERA_MANAGER_EXPOSURE_MODE_SHUTTER_PRIORITY, and * DJI_CAMERA_MANAGER_EXPOSURE_APERTURE_PRIORITY * @param position: camera mounted position - * @param ev: see reference of E_DjiCameraManagerExposureCompensation. + * @param ev: refer to E_DjiCameraManagerExposureCompensation. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetExposureCompensation(E_DjiMountPosition position, @@ -1161,7 +1152,7 @@ T_DjiReturnCode DjiCameraManager_SetExposureCompensation(E_DjiMountPosition posi /** * @brief Get camera's EV value of the selected camera mounted position. * @param position: camera mounted position - * @param ev: see reference of E_DjiCameraManagerExposureCompensation. + * @param ev: refer to E_DjiCameraManagerExposureCompensation. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetExposureCompensation(E_DjiMountPosition position, @@ -1170,7 +1161,7 @@ T_DjiReturnCode DjiCameraManager_GetExposureCompensation(E_DjiMountPosition posi /** * @brief Set AE lock mode. * @param position: camera mounted position - * @param enable: ture to enable, false to diasble. + * @param enable: true to enable, false to disable AE lock. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_SetAELockEnabled(E_DjiMountPosition position, @@ -1178,7 +1169,7 @@ T_DjiReturnCode DjiCameraManager_SetAELockEnabled(E_DjiMountPosition position, /** * @brief Get AE lock mode. - * @note Camera L1/P1 don't support this API. + * @note This API is not supported by L1/P1/M3D/M3TD models. * @param position: camera mounted position * @param enable: result of AE lock mode. * @return Execution result. @@ -1196,7 +1187,7 @@ T_DjiReturnCode DjiCameraManager_ResetCameraSettings(E_DjiMountPosition position /** * @brief Start to take video of the selected camera mounted position. * @note Camera must be in RECORD_VIDEO mode. For thermal imaging camera, - * user can take Single photo when recording video. + * user can take a single photo when recording video. * @param position: camera mounted position * @return Execution result. */ @@ -1221,7 +1212,7 @@ T_DjiReturnCode DjiCameraManager_GetRecordingState(E_DjiMountPosition position, /** * @brief Get camera recording time. - * @note L1/P1 don not support this API. + * @note This API is not supported by L1/P1/M3D/M3TD models. * @param position: camera mounted position * @param recordingTime: result of getting, unit is seconds. * @return Execution result. @@ -1365,7 +1356,7 @@ T_DjiReturnCode DjiCameraManager_GetNightSceneMode(E_DjiMountPosition position, E_DjiCameraManagerNightSceneMode *nightSceneMode); /** - * @brief Get range of stream source(s) can be storaged when capturing or recording. + * @brief Get range of stream source(s) can be stored when capturing or recording. * @param position: camera mounted position. * @param rangeList: returned value of range, in member streamStorage. * @return Execution result. @@ -1386,7 +1377,7 @@ T_DjiReturnCode DjiCameraManager_SetCaptureRecordingStreams(E_DjiMountPosition p T_DjiCameraManagerStreamList *streamStorageList); /** - * @brief Get the stream(s) of capture or recording mode to be storaged. + * @brief Get the stream(s) of capture or recording mode to be stored. * @param position: camera mounted position. * @param streamType: capture mode or recording mode. * @param streamSourceList: the real return value. @@ -1407,10 +1398,10 @@ T_DjiReturnCode DjiCameraManager_SetSynchronizedSplitScreenZoomEnabled(E_DjiMoun /** * @brief Set suffix name of directory or file. - * @note For file name, the setting is only valid once. + * @note This setting applies only once for file names. * @param position: camera mounted position. * @param nameType: see E_DjiCameraManagerExpandNameType, select to set name of directory or file. - * @param nameSize: size of name string, must be in rang of 1 ~ 239. + * @param nameSize: Length of the name string, between 1 and 239 characters. * @param nameStr: Content of custom suffix name. * @return Execution result. */ @@ -1420,12 +1411,12 @@ T_DjiReturnCode DjiCameraManager_SetCustomExpandName(E_DjiMountPosition position uint32_t nameSize); /** - * @brief Get custom past of lastest directory or file name + * @brief Get the custom suffix of the most recent directory or file name. * @param position: camera mounted position * @param nameType: to choose directory or file to get custom name * @param nameStr: name string buffer - * @param nameSize: its tell the max size of nameStr and changed to to the actually size of - * name string when function finished. + * @param nameSize: On input, indicates the maximum size of nameStr; on output, + * the actual size of the name string. * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetCustomExpandName(E_DjiMountPosition position, @@ -1435,9 +1426,9 @@ T_DjiReturnCode DjiCameraManager_GetCustomExpandName(E_DjiMountPosition position /** - * @brief Download selected camera media file list. - * @note The interface is a synchronous interface, which occupies more CPU resources when using it. - * If the download file fails, the timeout time is 3S. + * @brief Downloads a list of media files from the selected camera. + * @note This synchronous interface may lead to higher CPU usage. + * Times out after 3 seconds if the download fails. * @param position: the mount position of the camera * @param fileList: the pointer to the downloaded camera file list * @return Execution result. @@ -1446,8 +1437,8 @@ T_DjiReturnCode DjiCameraManager_DownloadFileList(E_DjiMountPosition position, T /** * @brief Download selected camera media file list by slices. - * @note The interface is a synchronous interface, which occupies more CPU resources when using it. - * If the download file fails, the timeout time is 3S. + * @note This synchronous interface may lead to higher CPU usage. + * Times out after 3 seconds if the download fails. * @param position: the mount position of the camera * @param sliceConfig: the slices config for downloading file list * @param fileList: the pointer to the downloaded camera file list @@ -1457,7 +1448,7 @@ T_DjiReturnCode DjiCameraManager_DownloadFileListBySlices(E_DjiMountPosition pos T_DjiCameraManagerSliceConfig sliceConfig, T_DjiCameraManagerFileList *fileList); /** - * @brief Regsiter selected camera download file data callback, + * @brief Registers a callback for downloading file data. * @param position: the mount position of the camera * @param callback: the download file data callback * @return Execution result. @@ -1466,10 +1457,10 @@ T_DjiReturnCode DjiCameraManager_RegDownloadFileDataCallback(E_DjiMountPosition DjiCameraManagerDownloadFileDataCallback callback); /** - * @brief Download selected camera media file by file index. - * @note Only support download one file at the same time, the new file download need wait for the previous file - * download finished.The interface is a synchronous interface, which occupies more CPU resources when using it. - * If the download file fails, the timeout time is 3S. + * @brief Downloads a media file specified by its index. + * @note Supports downloading one file at a time. Wait for a download to finish before starting another. + * This synchronous interface may lead to higher CPU usage. + * Times out after 3 seconds if the download fails. * @param position: the mount position of the camera * @param fileIndex: the index of the camera media file * @return Execution result. @@ -1479,9 +1470,9 @@ T_DjiReturnCode DjiCameraManager_DownloadFileByIndex(E_DjiMountPosition position /** * @brief Download selected camera media file by file index and file type. * @note This API only supports L2 camera. - * Only support download one file at the same time, the new file download need wait for the previous file - * download finished.The interface is a synchronous interface, which occupies more CPU resources when using it. - * If the download file fails, the timeout time is 3S. + * Supports downloading one file at a time. Wait for a download to finish before starting another. + * This synchronous interface may lead to higher CPU usage. + * Times out after 3 seconds if the download fails. * @param position: the mount position of the camera * @param fileIndex: the index of the camera media file * @param fileType: the sub type of the camera media file @@ -1489,15 +1480,16 @@ T_DjiReturnCode DjiCameraManager_DownloadFileByIndex(E_DjiMountPosition position */ T_DjiReturnCode DjiCameraManager_DownloadSubFileByIndexAndSubType(E_DjiMountPosition position, uint32_t index, E_DjiCameraMediaFileSubType fileType); /** - * @brief Before downloading media file(s), downloader rights should be obtained. + * @brief Obtains the rights to download media files before downloading media files * @param position: the mount position of the camera * @return Execution result. */ T_DjiReturnCode DjiCameraManager_ObtainDownloaderRights(E_DjiMountPosition position); /** - * @brief After downloading media file(s), downloader rights should be released - * @note If not release rights, the pilot app is probably can't access album of camera. + * @brief Releases the rights to download media files after downloading media files + * @note Failure to release downloader rights may restrict access to the camera album + * by the pilot app. * @param position: the mount position of the camera * @return Execution result. */ @@ -1512,9 +1504,9 @@ T_DjiReturnCode DjiCameraManager_FormatStorage(E_DjiMountPosition position); /** * @brief Get storage info of SD card. - * @note Camera L1/P1 don't support this API. + * @note This API doesn't support L1/P1/M3D/M3TD models. * @param position: the mount position of the camera - * @param storageInfo: result of getting, storage info of SD card. + * @param storageInfo: Result of SD Card storage information * @return Execution result. */ T_DjiReturnCode DjiCameraManager_GetStorageInfo(E_DjiMountPosition position, @@ -1594,7 +1586,7 @@ T_DjiReturnCode DjiCameraManager_SetFfcMode(E_DjiMountPosition position, E_DjiCa T_DjiReturnCode DjiCameraManager_TriggerFfc(E_DjiMountPosition position); /** - * @brief Set infrared camera gaim mode. + * @brief Set infrared camera gain mode. * @param position: camera mounted position. * @param gainMode: gain mode to set. * @return Execution result. @@ -1603,7 +1595,7 @@ T_DjiReturnCode DjiCameraManager_SetInfraredCameraGainMode(E_DjiMountPosition po E_DjiCameraManagerIrGainMode gainMode); /** - * @brief Get temprature range of infrared camera. + * @brief Get temperature range of infrared camera. * @param position: camera mounted position. * @param tempRange: returned valued of temperature range. * @return Execution result. @@ -1639,7 +1631,7 @@ T_DjiReturnCode DjiCameraManager_GetMeteringMode(E_DjiMountPosition position, T_DjiReturnCode DjiCameraManager_GetMeteringPointRegionRange(E_DjiMountPosition position, uint8_t *hrzNum, uint8_t *vtcNum); /** - * @brief Set metrting point. + * @brief Set metering point. * @param position: camera mounted position * @param x: Horizontal coordinate value, should be no greater than hrzNum - 1. * @param y: Horizontal coordinate value, should be no greater than vtcNum - 1. diff --git a/psdk_lib/include/dji_core.h b/psdk_lib/include/dji_core.h index 0d9de53..7f23e10 100644 --- a/psdk_lib/include/dji_core.h +++ b/psdk_lib/include/dji_core.h @@ -56,27 +56,26 @@ typedef struct { /* Exported functions --------------------------------------------------------*/ /** * @brief Initialize the Payload SDK core in blocking mode. - * @note The call location of this interface requires special attention, The call needs to be completed after the - * registration of console/OSAL handler functions/HAL handler functions are completed. At the same time, it must be - * initialized at the beginning of calling other functional module interfaces. You need to fill in the developer - * information correctly to ensure the initialization is successful. For additional instructions, please refer to the - * tutorial“PSDK Initialization”. - * @note This function does not return until the correct aircraft type and PSDK adapter type is obtained. The logic ensures + * @note The order of calling this call is crucial. It must be done after registering console/OSAL/HAL handler functions + * It must be done after registering console/OSAL/HAL handler functions and before using other functional module + * interfaces. Correctly fill in the developer information to ensure successful initialization. See the + * See the "PSDK Initialization" tutorial for more. + * This function does not return until the correct aircraft type and PSDK adapter type is obtained. The logic ensures * that aircraft and PSDK adapter have been started up normally before PSDK functional module and user's program run. - * General execution time of this function is 2~4 seconds. + * General execution time of this function is 2-4 seconds. * @param userInfo: pointer to the PSDK application information. * @return Execution result. */ T_DjiReturnCode DjiCore_Init(const T_DjiUserInfo *userInfo); /** - * @brief Set an alias that satisfies the condition for DJI application or product. - * @details Alias will display in DJI Pilot, if exist. + * @brief Sets an alias for a DJI application or product that meets the condition for DJI application or product. + * If an alias exists, it will be displayed in DJI Pilot. * @note Still need to pass in correct DJI APP name that is obtained from DJI SDK developer website to DjiCore_Init() - * interface. The DJI APP name will be used to bind or verification. - * @note Alias will be effective after a while, and the max value is 1s. - * @param productAlias: pointer to product alias string, and alias end with '\0'. The max length of the string is 31. If - * length of alias string is greater than 31, alias string will be truncated and passed in. + * interface. The DJI APP name will be used to bind and verification. + * The alias will take effect after a short delay, up to a maximum of 1 second. + * @param productAlias: A pointer to the product alias string, which must end with '\0'. The maximum length of the string is 31 characters. + * If the alias string exceeds 31 characters, it will be truncated before being passed in. * @return Execution result. */ T_DjiReturnCode DjiCore_SetAlias(const char *productAlias); @@ -99,7 +98,7 @@ T_DjiReturnCode DjiCore_SetSerialNumber(const char *productSerialNumber); /** * @brief Notify that the Payload SDK core application starts. - * @note The call location of this interface requires special attention, The call needs to be completed after all the + * @note The order of calling this interface requires special attention, The call needs to be completed after all the * module initialize and register interfaces. * @return Execution result. */ diff --git a/psdk_lib/include/dji_flight_controller.h b/psdk_lib/include/dji_flight_controller.h index 31767b8..7a60e94 100644 --- a/psdk_lib/include/dji_flight_controller.h +++ b/psdk_lib/include/dji_flight_controller.h @@ -41,100 +41,100 @@ extern "C" { typedef uint16_t E_DjiFlightControllerGoHomeAltitude; /*!< Unit:meter, range 20~500 */ /** - * @brief The UAV's actions when rc is lost. + * @brief The aircraft's actions when RC is lost. */ typedef enum { - DJI_FLIGHT_CONTROLLER_RC_LOST_ACTION_HOVER = 0, /*!< Aircraft will execute hover cation when rc is lost. */ - DJI_FLIGHT_CONTROLLER_RC_LOST_ACTION_LANDING = 1, /*!< Aircraft will execute land cation when rc is lost. */ - DJI_FLIGHT_CONTROLLER_RC_LOST_ACTION_GOHOME = 2, /*!< Aircraft will execute go-home cation when rc is lost. */ + DJI_FLIGHT_CONTROLLER_RC_LOST_ACTION_HOVER = 0, /*!< Aircraft will execute hover action when RC is lost. */ + DJI_FLIGHT_CONTROLLER_RC_LOST_ACTION_LANDING = 1, /*!< Aircraft will execute land action when RC is lost. */ + DJI_FLIGHT_CONTROLLER_RC_LOST_ACTION_GOHOME = 2, /*!< Aircraft will execute go-home action when RC is lost. */ } E_DjiFlightControllerRCLostAction; /** * @brief Enable/Disable RTK position enum */ typedef enum { - DJI_FLIGHT_CONTROLLER_DISABLE_RTK_POSITION = 0, /*!< 0: The UAV will use GPS data instead of RTK data to execute - * actions which require location information(waypoint、go home...) + DJI_FLIGHT_CONTROLLER_DISABLE_RTK_POSITION = 0, /*!< 0: The aircraft will use GPS data instead of RTK data to execute + * actions which requires location information(waypoint, go home...) */ - DJI_FLIGHT_CONTROLLER_ENABLE_RTK_POSITION = 1, /*!< 1:The UAV will use RTK data instead of GPS data to execute - * actions which require location information(waypoint、go home...)*/ + DJI_FLIGHT_CONTROLLER_ENABLE_RTK_POSITION = 1, /*!< 1:The aircraft will use RTK data instead of GPS data to execute + * actions which requires location information(waypoint, go home...)*/ } E_DjiFlightControllerRtkPositionEnableStatus; /** - * @brief Enable/Disable obstacle avoidance enum + * @brief Enable/Disable obstacle sensing enum */ typedef enum { - DJI_FLIGHT_CONTROLLER_DISABLE_OBSTACLE_AVOIDANCE = 0, /*!< 0: The UAV will not perform obstacle avoidance in + DJI_FLIGHT_CONTROLLER_DISABLE_OBSTACLE_AVOIDANCE = 0, /*!< 0: The aircraft will not perform obstacle sensing in * the specified direction */ - DJI_FLIGHT_CONTROLLER_ENABLE_OBSTACLE_AVOIDANCE = 1, /*!< 0: The UAV will perform obstacle avoidance in the + DJI_FLIGHT_CONTROLLER_ENABLE_OBSTACLE_AVOIDANCE = 1, /*!< 0: The aircraft will perform obstacle sensing in the * specified direction */ } E_DjiFlightControllerObstacleAvoidanceEnableStatus; /** * @brief Enable/Disable emergency stop motor function enum - * @note Attention:Enable emergency-stop-motor function is very dangerous in the air.it will make the aircraft crash!!! + * @note Enable emergency-stop-motor function is very dangerous in the air. It will make the aircraft crash!!! */ typedef enum { DJI_FLIGHT_CONTROLLER_ENABLE_EMERGENCY_STOP_MOTOR = 0x01, /*!< Execute emergency-stop-motor action */ } E_DjiFlightControllerEmergencyStopMotor; /** - * @brief Obtain/Release joystick control authority command enum - * @note You have obtain joystick control authority successfully before using joystick. + * @brief Obtain/Release joystick control permission command enum + * @note You have obtained joystick control permission successfully before using joystick. */ typedef enum { - DJI_FLIGHT_CONTROLLER_RELEASE_JOYSTICK_CTRL_AUTHORITY = 0, /*!< Obtain joystick authority */ - DJI_FLIGHT_CONTROLLER_OBTAIN_JOYSTICK_CTRL_AUTHORITY = 1, /*!< Release joystick authority */ + DJI_FLIGHT_CONTROLLER_RELEASE_JOYSTICK_CTRL_AUTHORITY = 0, /*!< Obtain joystick permission */ + DJI_FLIGHT_CONTROLLER_OBTAIN_JOYSTICK_CTRL_AUTHORITY = 1, /*!< Release joystick permission */ } E_DjiFlightControllerJoystickCtrlAuthorityAction; /** - * @brief The UAV's joystick control authority owner enum + * @brief The aircraft's joystick control permission owner enum */ typedef enum { - DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_RC = 0, /*!< Rc could control UAV with joystick. */ - DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_MSDK = 1, /*!< MSDK could control UAV with joystick. */ - DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_INTERNAL = 2, /*!< Special Internal modules could control UAV + DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_RC = 0, /*!< RC could control aircraft with joystick. */ + DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_MSDK = 1, /*!< MSDK could control aircraft with joystick. */ + DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_INTERNAL = 2, /*!< Special Internal modules could control aircraft * with joystick. */ - DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_OSDK = 4, /*!< OSDK could control UAV with joystick. */ + DJI_FLIGHT_CONTROLLER_JOYSTICK_CTRL_AUTHORITY_OSDK = 4, /*!< PSDK could control aircraft with joystick. */ } E_DjiFlightControllerJoystickCtrlAuthority; /** - * @brief The UAV's joystick control authority switch reason enum + * @brief The aircraft's joystick control permission switch reason enum */ typedef enum { - DJI_FLIGHT_CONTROLLER_MSDK_GET_JOYSTICK_CTRL_AUTH_EVENT = 1, /*!< MSDK get joystick control authority. */ - DJI_FLIGHT_CONTROLLER_INTERNAL_GET_JOYSTICK_CTRL_AUTH_EVENT = 2, /*!< Special Internal modules get joystick control authority. */ - DJI_FLIGHT_CONTROLLER_OSDK_GET_JOYSTICK_CTRL_AUTH_EVENT = 3, /*!< OSDK get joystick control authority. */ - DJI_FLIGHT_CONTROLLER_RC_LOST_GET_JOYSTICK_CTRL_AUTH_EVENT = 4, /*!< Reset joystick control authority to rc when executing rc lost action */ - DJI_FLIGHT_CONTROLLER_RC_NOT_P_MODE_RESET_JOYSTICK_CTRL_AUTH_EVENT = 5, /*!< Reset joystick control authority to rc when rc is not in P mode */ - DJI_FLIGHT_CONTROLLER_RC_SWITCH_MODE_GET_JOYSTICK_CTRL_AUTH_EVENT = 6, /*!< Set joystick control authority to rc when rc switch control mode(T/APS) */ - DJI_FLIGHT_CONTROLLER_RC_PAUSE_GET_JOYSTICK_CTRL_AUTH_EVENT = 7, /*!< Reset joystick control authority to rc when rc pausing */ - DJI_FLIGHT_CONTROLLER_RC_REQUEST_GO_HOME_GET_JOYSTICK_CTRL_AUTH_EVENT = 8, /*!< Reset joystick control authority to rc when rc requesting go home*/ - DJI_FLIGHT_CONTROLLER_LOW_BATTERY_GO_HOME_RESET_JOYSTICK_CTRL_AUTH_EVENT = 9, /*!< Reset joystick control authority to rc when aircraft is executing low-battery-go-home*/ - DJI_FLIGHT_CONTROLLER_LOW_BATTERY_LANDING_RESET_JOYSTICK_CTRL_AUTH_EVENT = 10, /*!< Reset joystick control authority to rc when aircraft is executing low-battery-landing*/ - DJI_FLIGHT_CONTROLLER_OSDK_LOST_GET_JOYSTICK_CTRL_AUTH_EVENT = 11, /*!< Reset joystick control authority to rc when osdk is lost*/ - DJI_FLIGHT_CONTROLLER_NERA_FLIGHT_BOUNDARY_RESET_JOYSTICK_CTRL_AUTH_EVENT = 12, /*!< Reset joystick control authority to rc when aircraft is near boundary.*/ + DJI_FLIGHT_CONTROLLER_MSDK_GET_JOYSTICK_CTRL_AUTH_EVENT = 1, /*!< MSDK gets the joystick control permission. */ + DJI_FLIGHT_CONTROLLER_INTERNAL_GET_JOYSTICK_CTRL_AUTH_EVENT = 2, /*!< A specific internal modules gets the joystick control permission. */ + DJI_FLIGHT_CONTROLLER_OSDK_GET_JOYSTICK_CTRL_AUTH_EVENT = 3, /*!< PSDK gets the joystick control permission. */ + DJI_FLIGHT_CONTROLLER_RC_LOST_GET_JOYSTICK_CTRL_AUTH_EVENT = 4, /*!< Reset the joystick control permission to RC when executing RC lost action */ + DJI_FLIGHT_CONTROLLER_RC_NOT_P_MODE_RESET_JOYSTICK_CTRL_AUTH_EVENT = 5, /*!< Reset the joystick control permission to RC when RC is not in P mode */ + DJI_FLIGHT_CONTROLLER_RC_SWITCH_MODE_GET_JOYSTICK_CTRL_AUTH_EVENT = 6, /*!< Set the joystick control permission to RC when RC switches control mode(T/APS) */ + DJI_FLIGHT_CONTROLLER_RC_PAUSE_GET_JOYSTICK_CTRL_AUTH_EVENT = 7, /*!< Reset the joystick control permission to RC when RC pauses */ + DJI_FLIGHT_CONTROLLER_RC_REQUEST_GO_HOME_GET_JOYSTICK_CTRL_AUTH_EVENT = 8, /*!< Reset the joystick control permission to RC when RC requests to go home*/ + DJI_FLIGHT_CONTROLLER_LOW_BATTERY_GO_HOME_RESET_JOYSTICK_CTRL_AUTH_EVENT = 9, /*!< Reset the joystick control permission to RC when aircraft is executing low-battery-go-home*/ + DJI_FLIGHT_CONTROLLER_LOW_BATTERY_LANDING_RESET_JOYSTICK_CTRL_AUTH_EVENT = 10, /*!< Reset the joystick control permission to RC when aircraft is executing low-battery-landing*/ + DJI_FLIGHT_CONTROLLER_OSDK_LOST_GET_JOYSTICK_CTRL_AUTH_EVENT = 11, /*!< Reset the joystick control permission to RC when PSDK is lost*/ + DJI_FLIGHT_CONTROLLER_NERA_FLIGHT_BOUNDARY_RESET_JOYSTICK_CTRL_AUTH_EVENT = 12, /*!< Reset the joystick control permission to RC when aircraft is near boundary.*/ } E_DjiFlightControllerJoystickCtrlAuthoritySwitchEvent; /** - * @brief The UAV's joystick control authority switch event info enum + * @brief The aircraft's joystick control permission switch event info enum */ typedef struct { - E_DjiFlightControllerJoystickCtrlAuthority curJoystickCtrlAuthority; /*!< The UAV's joystick control authority owner */ - E_DjiFlightControllerJoystickCtrlAuthoritySwitchEvent joystickCtrlAuthoritySwitchEvent; /*!< The UAV's joystick control authority switch reason */ + E_DjiFlightControllerJoystickCtrlAuthority curJoystickCtrlAuthority; /*!< The aircraft's joystick control permission owner */ + E_DjiFlightControllerJoystickCtrlAuthoritySwitchEvent joystickCtrlAuthoritySwitchEvent; /*!< The aircraft's joystick control permission switch reason */ } T_DjiFlightControllerJoystickCtrlAuthorityEventInfo; /** - * @brief Prototype of callback function used to get joystick control authority switch event info. + * @brief Prototype of callback function used to get joystick control permission switch event info. * @return Execution result. */ typedef T_DjiReturnCode (*JoystickCtrlAuthorityEventCbFunc)( T_DjiFlightControllerJoystickCtrlAuthorityEventInfo eventData); /** - * @brief Horizon control mode in joystick mode enum + * @brief Horizon control mode enum in joystick mode * @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 when advanced sensing system is working properly with Autopilot, + * 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. */ typedef enum { @@ -145,19 +145,19 @@ typedef enum { */ DJI_FLIGHT_CONTROLLER_HORIZONTAL_ANGLE_CONTROL_MODE = 0, /** - * @brief Set the control-mode to control horizontal vehicle velocities. + * @brief Set the control mode to control horizontal vehicle velocities. * @note Need to be referenced to either the ground or body frame by E_DjiFlightControllerHorizontalCoordinate setting * Limit: -30m/s to 30 m/s */ DJI_FLIGHT_CONTROLLER_HORIZONTAL_VELOCITY_CONTROL_MODE = 1, /** - * @brief Set the control-mode to control position offsets of pitch & roll directions. + * @brief Set the control mode to control position offsets of pitch & roll directions. * @note Need to be referenced to either the ground or body frame by E_DjiFlightControllerHorizontalCoordinate setting * Limit: N/A */ DJI_FLIGHT_CONTROLLER_HORIZONTAL_POSITION_CONTROL_MODE = 2, /** - * @brief Set the control-mode to control rate of change of the vehicle's attitude. + * @brief Set the control mode to control rate of change of the vehicle's attitude. * @note Need to be referenced to either the ground or body frame by E_DjiFlightControllerHorizontalCoordinate setting * Limit: -150deg/s to 150.0 deg/s */ @@ -165,51 +165,50 @@ typedef enum { } E_DjiFlightControllerHorizontalControlMode; /** - * @brief Vertical control mode in joystick mode enum - * @note We suggest developers do not use VERTICAL_POSITION control mode indoor when your UAV flight height is larger than 3 meters. - * This is because in indoor environments, barometer can be inaccurate, and the vertical controller may fail to keep - * the height of the UAV. + * @brief Vertical control mode enum in joystick mode + * @note We don not recommend using VERTICAL_POSITION control mode indoors when the aircraft's flying height exceeds 3 meters. + * This is because barometer can be inaccurate indoors, and the vertical controller may fail to keep the height of the aircraft. */ typedef enum { /** - * @brief Set the control-mode to control the vertical speed of UAV, upward is positive/ - * @note Limit: -5m/s to 5 m/s + * @brief Set the control mode to control the vertical speed of aircraft, setting the upward as positive/ + * @note Limit: -5 m/s to 5 m/s */ DJI_FLIGHT_CONTROLLER_VERTICAL_VELOCITY_CONTROL_MODE = 0, /** - * @brief Set the control-mode to control the height of UAV - * @note Limit: 0m to 120 m + * @brief Set the control mode to control the height of aircraft + * @note Limit: 0 m to 120 m */ DJI_FLIGHT_CONTROLLER_VERTICAL_POSITION_CONTROL_MODE = 1, /** - * @brief Set the control-mode to directly control the thrust - * @note Range: 0% to 100% + * @brief Set the control mode to directly control the thrust + * @note Range: 0 % to 100 % */ DJI_FLIGHT_CONTROLLER_VERTICAL_THRUST_CONTROL_MODE = 2, } E_DjiFlightControllerVerticalControlMode; /** - * @brief Yaw control mode in joystick mode enum + * @brief Yaw control mode enum in joystick mode */ typedef enum { /** - * @brief Set the control-mode to control yaw angle. - * @note Yaw angle is referenced to the ground frame.In this control mode, Ground frame is enforced in Autopilot. + * @brief Set the control mode to control yaw angle. + * @note Yaw angle is referenced to the ground frame. In this control mode, Ground frame is enforced in Autopilot. */ DJI_FLIGHT_CONTROLLER_YAW_ANGLE_CONTROL_MODE = 0x00, /** * @brief Set the control-mode to control yaw angular velocity * @note Same reference frame as YAW_ANGLE. - * Limit: -150deg/s to 150 deg/s + * Limit: -150 deg/s to 150 deg/s */ DJI_FLIGHT_CONTROLLER_YAW_ANGLE_RATE_CONTROL_MODE = 1 } E_DjiFlightControllerYawControlMode; /** - * @brief Horizontal coordinate in joystick mode enum + * @brief Horizontal coordinate enum in joystick mode */ typedef enum { DJI_FLIGHT_CONTROLLER_HORIZONTAL_GROUND_COORDINATE = 0, /*!< Set the x-y of ground frame as the horizontal frame (NEU) */ @@ -217,10 +216,10 @@ typedef enum { } E_DjiFlightControllerHorizontalCoordinate; /*! - * @brief Stable mode in joystick mode enum. - * @note Only works in Horizontal velocity control mode.In velocity stable mode, drone will brake and hover at one position once - * the input command is zero.In velocity non-stable mode, drone will follow the velocity command and not hover when the command is zero. - * That means drone will drift with the wind. + * @brief Stable mode enum in joystick mode + * @note Only works in horizontal velocity control mode. In velocity stable mode, aircraft will brake and hover at one position once + * the input command is zero. In velocity non-stable mode, aircraft will follow the velocity command and not hover when the command is zero. + * That means aircraft will drift with the wind. */ typedef enum { DJI_FLIGHT_CONTROLLER_STABLE_CONTROL_MODE_DISABLE = 0, /*!< Disable the stable mode */ @@ -246,9 +245,9 @@ typedef struct { #pragma pack(1) typedef struct { - dji_f32_t x; /*!< Control with respect to the x axis.*/ - dji_f32_t y; /*!< Control with respect to the y axis.*/ - dji_f32_t z; /*!< Control with respect to the z axis, up is positive. */ + dji_f32_t x; /*!< Controls the x axis.*/ + dji_f32_t y; /*!< Controls the y axis.*/ + dji_f32_t z; /*!< Controls the z axis, setting upward as positive. */ dji_f32_t yaw; /*!< Yaw position/velocity control w.r.t. the ground frame.*/ } T_DjiFlightControllerJoystickCommand;// pack(1) @@ -271,9 +270,8 @@ typedef struct { /* Exported functions --------------------------------------------------------*/ /** - * @brief Initialise flight controller module, and user should call this function - * before using flight controller features. - * @param ridInfo: Use PSDK to control the aircraft, must report the correct RID information. + * @brief Initialise flight controller module + * @param ridInfo: Must report the correct RID information before using PSDK to control the aircraft. * @return Execution result. */ T_DjiReturnCode DjiFlightController_Init(T_DjiFlightControllerRidInfo ridInfo); @@ -287,8 +285,7 @@ T_DjiReturnCode DjiFlightController_DeInit(void); /** * @brief Enable/Disable RTK position function. * @details Enabling RTK means that RTK data will be used instead of GPS during flight. - * @param rtkEnableStatus: see reference of "E_DjiFlightControllerRtkPositionEnableStatus". - * It keeps in sync with pilot's param. + * @param rtkEnableStatus: refer to "E_DjiFlightControllerRtkPositionEnableStatus", inheriting from Pilot. * @return Execution result. */ T_DjiReturnCode @@ -297,164 +294,163 @@ DjiFlightController_SetRtkPositionEnableStatus(E_DjiFlightControllerRtkPositionE /** * @brief Get RTK enable status. * @note Enabling RTK means that RTK data will be used during intelligent flight. - * @param rtkEnableStatus: see reference of "E_DjiFlightControllerRtkPositionEnableStatus". - * It keeps in sync with pilot's param. + * @param rtkEnableStatus: refer to "E_DjiFlightControllerRtkPositionEnableStatus", inheriting from Pilot. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetRtkPositionEnableStatus(E_DjiFlightControllerRtkPositionEnableStatus *rtkEnableStatus); /** - * @brief Set rc lost action. - * @note It will be valid when rc and osdk is both lost.It only support M30. - * @param rcLostAction: actions when rc is lost.(hover/landing/go home).It keeps in sync with pilot's param. + * @brief Set RC lost action. + * @note Valid when RC and PSDK are both lost. It only supports M30. + * @param rcLostAction: actions when RC is lost.(hover/landing/go home).It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_SetRCLostAction(E_DjiFlightControllerRCLostAction rcLostAction); /** - * @brief Get rc lost action(hover/landing/gohome). - * @note It will be valid when rc and osdk is both lost.It only support M30. - * @param rcLostAction: see reference of E_DjiFlightControllerRCLostAction.It keeps in sync with pilot's param. + * @brief Get RC lost action(hover/landing/gohome). + * @note Valid when RC and PSDK are both lost. It only supports M30. + * @param rcLostAction: see reference of E_DjiFlightControllerRCLostAction.It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetRCLostAction(E_DjiFlightControllerRCLostAction *rcLostAction); /** - * @brief Enable/Disable horizontal visual(forwards,backwards,left,right) obstacle avoidance. - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Enable/Disable horizontal visual(forwards,backwards,left,right) obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param horizontalObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_SetHorizontalVisualObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus horizontalObstacleAvoidanceEnableStatus); /** - * @brief Get status of horizontal visual(forwards,backwards,left,right) obstacle avoidance switch. - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Get the switch status of horizontal visual(forwards,backwards,left,right) obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param horizontalObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetHorizontalVisualObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus *horizontalObstacleAvoidanceEnableStatus); /** - * @brief Enable/Disable horizontal radar obstacle avoidance. - * @note It will be valid only if you install CSM radar successfully.For detailed parameters of obstacle avoidance, - * it is recommended to read the official user manual in https://www.dji.com/uk/matrice-300/downloads. + * @brief Enable/Disable horizontal radar obstacle sensing. + * @note It will be valid only if you install CSM radar successfully.For detailed parameters of obstacle sensing, + * it is recommended to read the official user manual in https://www.dji.com. * @param horizontalObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_SetHorizontalRadarObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus horizontalObstacleAvoidanceEnableStatus); /** - * @brief Get status of horizontal radar obstacle avoidance switch. - * @note It will be valid only if you install CSM radar successfully.For detailed parameters of obstacle avoidance, + * @brief Get the switch status of horizontal radar obstacle sensing. + * @note It will be valid only if you install CSM radar successfully.For detailed parameters of obstacle sensing, * it is recommended to read the official user manual in https://www.dji.com/uk/matrice-300/downloads. * @param horizontalObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetHorizontalRadarObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus *horizontalObstacleAvoidanceEnableStatus); /** - * @brief Enable/Disable upwards visual obstacle avoidance. - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Enable/Disable upwards visual obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param upwardsObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_SetUpwardsVisualObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus upwardsObstacleAvoidanceEnableStatus); /** - * @brief Get status of upwards visual obstacle avoidance switch. - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Get the switch status of upwards visual obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param upwardsObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetUpwardsVisualObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus *upwardsObstacleAvoidanceEnableStatus); /** - * @brief Enable/Disable upwards radar obstacle avoidance. - * @note It will be valid only if you install CSM radar successfully.For detailed parameters of obstacle avoidance, + * @brief Enable/Disable upwards radar obstacle sensing. + * @note It will be valid only if you install CSM radar successfully.For detailed parameters of obstacle sensing, * it is recommended to read the official user manual in https://www.dji.com. * @param upwardsObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_SetUpwardsRadarObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus upwardsObstacleAvoidanceEnableStatus); /** - * @brief Get status of upwards radar obstacle avoidance switch - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Get the switch status of upwards radar obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param upwardsObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetUpwardsRadarObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus *upwardsObstacleAvoidanceEnableStatus); /** - * @brief Enable/Disable downwards visual obstacle avoidance - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Enable/Disable downwards visual obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param downwardsObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_SetDownwardsVisualObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus downwardsObstacleAvoidanceEnableStatus); /** - * @brief Get status of downwards visual obstacle avoidance switch - * @note For detailed parameters of obstacle avoidance, it is recommended to read the official user manual in + * @brief Get the switch status of downwards visual obstacle sensing. + * @note For detailed parameters of obstacle sensing, it is recommended to read the official user manual in * https://www.dji.com. * @param downwardsObstacleAvoidanceEnableStatus: see reference of E_DjiFlightControllerObstacleAvoidanceEnableStatus. - * It keeps in sync with pilot's param. + * It inherits from Pilot's param. * @return Execution result. */ T_DjiReturnCode DjiFlightController_GetDownwardsVisualObstacleAvoidanceEnableStatus( E_DjiFlightControllerObstacleAvoidanceEnableStatus *downwardsObstacleAvoidanceEnableStatus); /** - * @brief Arrest flying. - * @note when the UAV is on the ground ,it will stop motors and display "hms description" on APP. when the UAV is - * in the air, it will continue flying and display "hms description" on APP only. + * @brief Arrest flying means emergency braking + * @note When the aircraft is on the ground, it will stop motors and display "hms description" on App. when the aircraft is + * in the air, it will continue flying and display "hms description" on App only. * If you use this interface, you need to use "DjiFlightController_CancelArrestFlying" to quit arrest-flying status, then - * then the UAV can fly again. + * then the aircraft can fly again. * @return Execution result. */ T_DjiReturnCode DjiFlightController_ArrestFlying(void); /** * @brief Quit status of arrest-flying. - * @note The UAV need to quit status of arrest-flying to continue flying after arresting flying. + * @note The aircraft need to quit status of arrest-flying to continue flying after arresting flying. * @return Execution result. */ T_DjiReturnCode DjiFlightController_CancelArrestFlying(void); /** - * @brief Turn on motors when the UAV is on the ground. + * @brief Turn on motors when the aircraft is on the ground. * @return Execution result. */ T_DjiReturnCode DjiFlightController_TurnOnMotors(void); /** - * @brief Turn off motors when the UAV is on the ground. + * @brief Turn off motors when the aircraft is on the ground. * @return Execution result. */ T_DjiReturnCode DjiFlightController_TurnOffMotors(void); @@ -470,36 +466,36 @@ T_DjiReturnCode DjiFlightController_TurnOffMotors(void); T_DjiReturnCode DjiFlightController_EmergencyStopMotor(E_DjiFlightControllerEmergencyStopMotor cmd, char debugMsg[EMERGENCY_STOP_MOTOR_MSG_MAX_LENGTH]); /** - * @brief Request take off action when the UAV is on the ground. + * @brief Request taking off action when the aircraft is on the ground. * @return Execution result. */ T_DjiReturnCode DjiFlightController_StartTakeoff(void); /** - * @brief Request landing action when the UAV is in the air. + * @brief Request landing action when the aircraft is in the air. * @return Execution result. */ T_DjiReturnCode DjiFlightController_StartLanding(void); /** - * @brief Request cancel landing action when the UAV is landing + * @brief Request cancelling landing action when the aircraft is landing * @return Execution result. */ T_DjiReturnCode DjiFlightController_CancelLanding(void); /** - * @brief Confirm the landing when the UAV is 0.7m above the ground. + * @brief Confirm the landing when the aircraft is 0.7 m above the ground. * @note When the clearance between the aircraft and the ground is less than 0.7m, the aircraft will pause landing and - * wait for user's confirmation.This api use for confirm landing. If the ground is not suitable for landing ,user must - * use RC to control it landing manually or force landing. + * wait for user's confirmation. This API is for confirm landing. If the ground is not suitable for landing, user + * must use RC to control it landing manually or force landing. * @return Execution result. */ T_DjiReturnCode DjiFlightController_StartConfirmLanding(void); /** * @brief Force landing in any case. - * @note This api will ignore the smart landing function,.When using this pi, it will landing directly (would not stop - * at 0.7m and wait user's command). Attention:it may make the aircraft crash!!! + * @note This API will ignore the smart landing function. When using this API, it will landing directly (would not stop + * at 0.7m and wait user's command). Attention: it may make the aircraft crash!!! * @return Execution result. */ T_DjiReturnCode DjiFlightController_StartForceLanding(void); @@ -507,7 +503,7 @@ T_DjiReturnCode DjiFlightController_StartForceLanding(void); /** * @brief Set customized GPS(not RTK) home location. * @note Set customized home location failed reason may as follows: - * 1. The distance between new home location and last home location is larger than MAX_FLY_RADIUS(20km). + * 1. The distance between new home location and last home location is larger than MAX_FLY_RADIUS(20 km). * 2. Record initial home location failed after start aircraft. * @param homeLocation: homeLocation include latitude and longitude * @return Execution result. @@ -515,7 +511,7 @@ T_DjiReturnCode DjiFlightController_StartForceLanding(void); T_DjiReturnCode DjiFlightController_SetHomeLocationUsingGPSCoordinates(T_DjiFlightControllerHomeLocation homeLocation); /** - * @brief Set home location using current aircraft GPS(not RTK) location. + * @brief Set home location using current aircraft GPS (not RTK) location. * @note Set home location failed reasons may as follows: * 1. Aircraft's gps level can't reach the condition of recording home location. * 2. Record initial home location failed after start aircraft. @@ -527,7 +523,7 @@ T_DjiReturnCode DjiFlightController_SetHomeLocationUsingCurrentAircraftLocation( * @brief Set go home altitude. * @note If aircraft's current altitude is higher than the setting value of go home altitude, aircraft will go home * using current altitude. Otherwise, it will climb to setting of go home altitude ,and then execute go home action. - * Go home altitude setting is 20m ~ 1500m. + * Go home altitude setting is 20-1500 m. * @param altitude: go home altitude, unit: meter * @return Execution result. */ @@ -550,35 +546,35 @@ T_DjiReturnCode DjiFlightController_GetGoHomeAltitude(E_DjiFlightControllerGoHom T_DjiReturnCode DjiFlightController_GetCountryCode(uint16_t *countryCode); /** - * @brief Request go home action when the UAV is in the air + * @brief Request go home action when the aircraft is in the air * @return Execution result. */ T_DjiReturnCode DjiFlightController_StartGoHome(void); /** - * @brief Request cancel go home action when the UAV is going home + * @brief Request cancel go home action when the aircraft is going home * @return Execution result. */ T_DjiReturnCode DjiFlightController_CancelGoHome(void); /** - * @brief Obtain UAV's joystick control authority. - * @note 1.You have to obtain joystick control authority successfully before you using joystick to control UAV. + * @brief Obtain aircraft's joystick control permission. + * @note 1.You have to obtain joystick control permission successfully before you using joystick to control aircraft. * 2. RC must be in p-mode. * @return Execution result. */ T_DjiReturnCode DjiFlightController_ObtainJoystickCtrlAuthority(void); /** - * @brief Release UAV's joystick control authority. + * @brief Release aircraft's joystick control permission. * @note RC must be in p-mode. * @return Execution result. */ T_DjiReturnCode DjiFlightController_ReleaseJoystickCtrlAuthority(void); /** - * @brief Subscribe to joystick control authority switch event with a callback function. - * @note it will be triggered once the joystick control authority switch event occurs. + * @brief Subscribe to joystick control permission switch event with a callback function. + * @note it will be triggered once the joystick control permission switch event occurs. * @return Execution result. */ T_DjiReturnCode DjiFlightController_RegJoystickCtrlAuthorityEventCallback(JoystickCtrlAuthorityEventCbFunc callback); @@ -605,7 +601,7 @@ T_DjiReturnCode DjiFlightController_ExecuteEmergencyBrakeAction(void); /** * @brief Request cancel emergency brake action. * @note It is only support on M30.If you use DjiFlightController_ExecuteEmergencyBrakeAction(), you need to use - * "DjiFlightController_CancelEmergencyBrakeAction()" to allow aircraft to execute drone action again. + * "DjiFlightController_CancelEmergencyBrakeAction()" to allow aircraft to execute aircraft action again. * @return Execution result. */ T_DjiReturnCode DjiFlightController_CancelEmergencyBrakeAction(void); @@ -618,11 +614,11 @@ T_DjiReturnCode DjiFlightController_CancelEmergencyBrakeAction(void); */ T_DjiReturnCode DjiFlightController_GetGeneralInfo(T_DjiFlightControllerGeneralInfo *generalInfo); -/*! @brief The command decides whether execute RC lost action or not when osdk is running - * @note This setting only affects the behavior of the drone when the RC lost and the OSDK is connected. - * if the command is enable, the drone will not execute rc lost action when rc is lost but OSDK is running; - * if the command is disable, the drone will execute rc lost action when rc is lost but OSDK is running - * the drone will execute rc lost action when rc is lost and OSDK is lost whatever the command is. +/*! @brief The command decides whether execute RC lost action or not when PSDK is running + * @note This setting only affects the behavior of the aircraft when the RC lost and the PSDK is connected. + * if the command is enable, the aircraft will not execute RC lost action when RC is lost but PSDK is running; + * if the command is disable, the aircraft will execute RC lost action when RC is lost but PSDK is running + * the aircraft will execute RC lost action when RC is lost and PSDK is lost whatever the command is. * default command is disable. * @param executeRCLostActionOrNotWhenOnboardOn enable:1;disable:0 * @return T_DjiReturnCode error code @@ -630,7 +626,7 @@ T_DjiReturnCode DjiFlightController_GetGeneralInfo(T_DjiFlightControllerGeneralI T_DjiReturnCode DjiFlightController_SetRCLostActionEnableStatus(E_DjiFlightControllerRCLostActionEnableStatus command); -/*! @brief get rc lost action enable status(enable or disable) +/*! @brief get RC lost action enable status(enable or disable) * @param command executeRCLostActionOrNotWhenOnboardOn, enable:1;disable:0 * @return T_DjiReturnCode error code */ diff --git a/psdk_lib/include/dji_gimbal_manager.h b/psdk_lib/include/dji_gimbal_manager.h index 6289e32..82e1802 100644 --- a/psdk_lib/include/dji_gimbal_manager.h +++ b/psdk_lib/include/dji_gimbal_manager.h @@ -46,13 +46,13 @@ typedef struct { dji_f32_t pitch; /*!< Pitch angle in degree, unit: deg */ dji_f32_t roll; /*!< Roll angle in degree, unit: deg */ dji_f32_t yaw; /*!< Yaw angle in degree, unit: deg */ - dji_f64_t time; /*!< Expect execution time of gimbal rotation, unit: second. */ + dji_f64_t time; /*!< Expected execution time for gimbal rotation, in seconds. */ } T_DjiGimbalManagerRotation; /* Exported functions --------------------------------------------------------*/ /** * @brief Initialize the gimbal manager module. - * @note The interface initialization needs to be after DjiCore_Init. + * @note This interface must be initialized after DjiCore_Init.. * @return Execution result. */ T_DjiReturnCode DjiGimbalManager_Init(void); @@ -74,7 +74,7 @@ T_DjiReturnCode DjiGimbalManager_SetMode(E_DjiMountPosition mountPosition, E_Dji /** * @brief Reset the pitch and yaw of the gimbal. * @param mountPosition: gimbal mount position, input limit see enum E_DjiMountPosition - * @param mode: Reset mode, input limit see enum E_DjiGimbalResetMode + * @param mode: reset mode, input limit see enum E_DjiGimbalResetMode * @return Execution result. */ T_DjiReturnCode DjiGimbalManager_Reset(E_DjiMountPosition mountPosition, E_DjiGimbalResetMode resetMode); @@ -83,17 +83,17 @@ T_DjiReturnCode DjiGimbalManager_Reset(E_DjiMountPosition mountPosition, E_DjiGi * @brief Rotate the angle of the gimbal. * @param mountPosition: gimbal mount position, input limit see enum E_DjiMountPosition * @param rotation: the rotation parameters to be executed on the target gimbal, including the rotation mode, target - * angle value and executed time, ref to T_DjiGimbalManagerRotation + * angle value and executed time, refer to T_DjiGimbalManagerRotation * @return Execution result. */ T_DjiReturnCode DjiGimbalManager_Rotate(E_DjiMountPosition mountPosition, T_DjiGimbalManagerRotation rotation); /*! * @brief Prototype of callback function used to enable or disable extended pitch axis angle range. - * @details Switching the gimbal limit euler angle of pitch axis to the extended limit angle or the default limit + * @note Switching the gimbal limit euler angle of pitch axis to the extended limit angle or the default limit * angle. * @param mountPosition: gimbal mount position, input limit see enum E_DjiMountPosition - * @param enabledFlag: flag specified whether enable or disable extended pitch axis angle range. + * @param enabledFlag: flag specifying whether to enable or disable the extended pitch axis angle range.. * @return Execution result. */ T_DjiReturnCode DjiGimbalManager_SetPitchRangeExtensionEnabled(E_DjiMountPosition mountPosition, bool enabledFlag); @@ -103,17 +103,17 @@ T_DjiReturnCode DjiGimbalManager_SetPitchRangeExtensionEnabled(E_DjiMountPositio * @param mountPosition: gimbal mount position, input limit see enum E_DjiMountPosition * @param axis: axis to be set. * @param maxSpeedPercentage: max speed value. Recommended calculation formula is "spd = default_max_spd * x / 100", - * x is default max speed value. Range from 1 to 100. + * where 'x' is the default maximum speed value. Range from 1 to 100. * @return Execution result. */ T_DjiReturnCode DjiGimbalManager_SetControllerMaxSpeedPercentage(E_DjiMountPosition mountPosition, E_DjiGimbalAxis axis, uint8_t maxSpeedPercentage); /** - * @brief Set smooth factor for gimbal controller, using to smooth control. + * @brief Set smooth factor for gimbal controller, using for smooth control. * @param mountPosition: gimbal mount position, input limit see enum E_DjiMountPosition * @param axis: axis to be set. - * @param smoothingFactor: smooth factor. The larger the value, the smaller the acceleration of gimbal. Recommended + * @param smoothingFactor: smooth factor. A larger value results in slower gimbal acceleration. Recommended * calculation formula is "acc = 10000 * (0.8 ^ (1 + x)) deg/s^2", x is smooth factor. Range from 0 to 30. * @return Execution result. */ diff --git a/psdk_lib/include/dji_liveview.h b/psdk_lib/include/dji_liveview.h index a141463..d4ec109 100644 --- a/psdk_lib/include/dji_liveview.h +++ b/psdk_lib/include/dji_liveview.h @@ -81,7 +81,7 @@ typedef void (*DjiLiveview_H264Callback)(E_DjiLiveViewCameraPosition position, c /* Exported functions --------------------------------------------------------*/ /** * @brief Initialize the liveview module. - * @note The interface initialization needs to be after DjiCore_Init. + * @note Must be called after DjiCore_Init. * @return Execution result. */ T_DjiReturnCode DjiLiveview_Init(void); @@ -93,27 +93,27 @@ T_DjiReturnCode DjiLiveview_Init(void); T_DjiReturnCode DjiLiveview_Deinit(void); /** - * @brief Start the FPV or Camera H264 Stream by selected position. - * @param position: point out which camera to output the H264 stream - * @param source: point out which sub camera to output the H264 stream - * @param callback: callback function that is called in a callback thread when a new h264 frame is received + * @brief Start the FPV or camera H264 stream from the specified position. + * @param position: Camera position for the H264 stream output. + * @param source: sub-camera source for the H264 stream output. + * @param callback: Callback function in a callback thread when a new h264 frame is received * @return Execution result. */ T_DjiReturnCode DjiLiveview_StartH264Stream(E_DjiLiveViewCameraPosition position, E_DjiLiveViewCameraSource source, DjiLiveview_H264Callback callback); /** - * @brief Stop the FPV or Camera H264 Stream by selected position. - * @param position: point out which camera to output the H264 stream - * @param source: point out which sub camera to output the H264 stream + * @brief Stop the FPV or Camera H264 Stream from the specified position. + * @param position: Camera position for the H264 stream output. + * @param source: sub-camera source for the H264 stream output. * @return Execution result. */ T_DjiReturnCode DjiLiveview_StopH264Stream(E_DjiLiveViewCameraPosition position, E_DjiLiveViewCameraSource source); /** - * @brief Request the intraframe Frame of Camera H264 Stream by selected position. - * @param position: point out which camera to output the H264 stream - * @param source: point out which sub camera to output the H264 stream + * @brief Request the intraframe Frame of camera H264 stream from the specified position. + * @param position: Camera position for the H264 stream output. + * @param source: sub-camera source for the H264 stream output. * @return Execution result. */ T_DjiReturnCode DjiLiveview_RequestIntraframeFrameData(E_DjiLiveViewCameraPosition position, diff --git a/psdk_lib/include/dji_typedef.h b/psdk_lib/include/dji_typedef.h index 77c443b..d9762fd 100644 --- a/psdk_lib/include/dji_typedef.h +++ b/psdk_lib/include/dji_typedef.h @@ -136,6 +136,8 @@ typedef enum { DJI_CAMERA_TYPE_M3T = 67, /*!< Camera type is M3T. */ DJI_CAMERA_TYPE_M3D = 80, /*!< Camera type is Matrice 3D. */ DJI_CAMERA_TYPE_M3TD = 81, /*!< Camera type is Matrice 3TD. */ + DJI_CAMERA_TYPE_H30 = 82, /*!< Camera type is H30. */ + DJI_CAMERA_TYPE_H30T = 83, /*!< Camera type is H30T. */ } E_DjiCameraType; /** diff --git a/psdk_lib/include/dji_version.h b/psdk_lib/include/dji_version.h index a855c24..5efc47b 100644 --- a/psdk_lib/include/dji_version.h +++ b/psdk_lib/include/dji_version.h @@ -34,10 +34,10 @@ 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 8 /*!< DJI SDK minor version num, when add functionality in a backwards compatible manner 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_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_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 2006 /*!< DJI SDK version build info, when jenkins trigger build changes. Range from 0 to 65535. */ +#define DJI_VERSION_BUILD 2044 /*!< DJI SDK version build info, when jenkins trigger build changes. Range from 0 to 65535. */ /* Exported types ------------------------------------------------------------*/ diff --git a/psdk_lib/lib/aarch64-linux-gnu-gcc/libpayloadsdk.a b/psdk_lib/lib/aarch64-linux-gnu-gcc/libpayloadsdk.a index 85f4427..bbadcf5 100644 Binary files a/psdk_lib/lib/aarch64-linux-gnu-gcc/libpayloadsdk.a and b/psdk_lib/lib/aarch64-linux-gnu-gcc/libpayloadsdk.a differ diff --git a/psdk_lib/lib/arm-linux-gnueabi-gcc/libpayloadsdk.a b/psdk_lib/lib/arm-linux-gnueabi-gcc/libpayloadsdk.a index 609d335..390bf87 100644 Binary files a/psdk_lib/lib/arm-linux-gnueabi-gcc/libpayloadsdk.a and b/psdk_lib/lib/arm-linux-gnueabi-gcc/libpayloadsdk.a differ diff --git a/psdk_lib/lib/arm-linux-gnueabihf-gcc/libpayloadsdk.a b/psdk_lib/lib/arm-linux-gnueabihf-gcc/libpayloadsdk.a index d501976..f2714be 100644 Binary files a/psdk_lib/lib/arm-linux-gnueabihf-gcc/libpayloadsdk.a and b/psdk_lib/lib/arm-linux-gnueabihf-gcc/libpayloadsdk.a differ diff --git a/psdk_lib/lib/armcc_cortex-m4/libpayload.lib b/psdk_lib/lib/armcc_cortex-m4/libpayload.lib index 0586242..0d718a0 100644 Binary files a/psdk_lib/lib/armcc_cortex-m4/libpayload.lib and b/psdk_lib/lib/armcc_cortex-m4/libpayload.lib differ diff --git a/psdk_lib/lib/x86_64-linux-gnu-gcc/libpayloadsdk.a b/psdk_lib/lib/x86_64-linux-gnu-gcc/libpayloadsdk.a index 663ba51..cb341c7 100644 Binary files a/psdk_lib/lib/x86_64-linux-gnu-gcc/libpayloadsdk.a and b/psdk_lib/lib/x86_64-linux-gnu-gcc/libpayloadsdk.a differ diff --git a/samples/sample_c/module_sample/camera_manager/test_camera_manager.c b/samples/sample_c/module_sample/camera_manager/test_camera_manager.c index d5de03a..8edfddf 100644 --- a/samples/sample_c/module_sample/camera_manager/test_camera_manager.c +++ b/samples/sample_c/module_sample/camera_manager/test_camera_manager.c @@ -72,6 +72,8 @@ static const T_DjiTestCameraTypeStr s_cameraTypeStrList[] = { {DJI_CAMERA_TYPE_M3T, "M3T Camera"}, {DJI_CAMERA_TYPE_M3D, "M3D Camera"}, {DJI_CAMERA_TYPE_M3TD, "M3TD Camera"}, + {DJI_CAMERA_TYPE_H30, "H30 Camera"}, + {DJI_CAMERA_TYPE_H30T, "H30T Camera"}, }; static FILE *s_downloadMediaFile = NULL; @@ -848,7 +850,8 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, cameraType == DJI_CAMERA_TYPE_H20N || cameraType == DJI_CAMERA_TYPE_M30 || cameraType == DJI_CAMERA_TYPE_M30T || cameraType == DJI_CAMERA_TYPE_M3E || cameraType == DJI_CAMERA_TYPE_M3T || cameraType == DJI_CAMERA_TYPE_M3D || - cameraType == DJI_CAMERA_TYPE_M3TD) { + cameraType == DJI_CAMERA_TYPE_M3TD || cameraType == DJI_CAMERA_TYPE_H30 || + cameraType == DJI_CAMERA_TYPE_H30T) { USER_LOG_INFO("Set mounted position %d camera's exposure mode to manual mode.", mountPosition); returnCode = DjiTest_CameraManagerSetExposureMode(mountPosition, @@ -888,7 +891,8 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, || cameraType == DJI_CAMERA_TYPE_H20T || cameraType == DJI_CAMERA_TYPE_M30 || cameraType == DJI_CAMERA_TYPE_M30T || cameraType == DJI_CAMERA_TYPE_M3E || cameraType == DJI_CAMERA_TYPE_M3T || cameraType == DJI_CAMERA_TYPE_M3D - || cameraType == DJI_CAMERA_TYPE_M3TD) { + || cameraType == DJI_CAMERA_TYPE_M3TD || cameraType == DJI_CAMERA_TYPE_H30 + || cameraType == DJI_CAMERA_TYPE_H30T) { USER_LOG_INFO("Set mounted position %d camera's exposure mode to manual mode.", mountPosition); returnCode = DjiTest_CameraManagerSetExposureMode(mountPosition, @@ -1456,7 +1460,7 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, osalHandler->TaskSleepMs(5); printf("Input expand directory name: "); scanf("%s", dirName); - dirNameSize = strlen(dirName); + dirNameSize = strlen((const char *)dirName); returnCode = DjiCameraManager_SetCustomExpandName(mountPosition, DJI_CAMERA_MANAGER_EXPAND_NAME_TYPE_DIR, @@ -1471,7 +1475,7 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, osalHandler->TaskSleepMs(5); printf("Input expand file name: "); scanf("%s", fileName); - fileNameSize = strlen(fileName); + fileNameSize = strlen((const char *)fileName); returnCode = DjiCameraManager_SetCustomExpandName(mountPosition, DJI_CAMERA_MANAGER_EXPAND_NAME_TYPE_FILE, @@ -1529,7 +1533,8 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, if (cameraType == DJI_CAMERA_TYPE_H20 || cameraType == DJI_CAMERA_TYPE_H20T || cameraType == DJI_CAMERA_TYPE_H20N || cameraType == DJI_CAMERA_TYPE_M30 || cameraType == DJI_CAMERA_TYPE_M30T || cameraType == DJI_CAMERA_TYPE_M3E || - cameraType == DJI_CAMERA_TYPE_M3T) { + cameraType == DJI_CAMERA_TYPE_M3T || cameraType == DJI_CAMERA_TYPE_H30 || + cameraType == DJI_CAMERA_TYPE_H30T) { returnCode = DjiCameraManager_SetStreamSource(mountPosition, DJI_CAMERA_MANAGER_SOURCE_ZOOM_CAM); if (returnCode != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) { USER_LOG_WARN("Change camera stream source to zoom camera failed at position %d, error code: 0x%08X\r\n", @@ -1589,7 +1594,8 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, if (cameraType == DJI_CAMERA_TYPE_H20 || cameraType == DJI_CAMERA_TYPE_H20N || cameraType == DJI_CAMERA_TYPE_H20T || cameraType == DJI_CAMERA_TYPE_M30 || cameraType == DJI_CAMERA_TYPE_M30T || cameraType == DJI_CAMERA_TYPE_M3E || - cameraType == DJI_CAMERA_TYPE_M3T) { + cameraType == DJI_CAMERA_TYPE_M3T || cameraType == DJI_CAMERA_TYPE_H30 || + cameraType == DJI_CAMERA_TYPE_H30T) { USER_LOG_INFO("Set camera stream source to zoom camera."); returnCode = DjiCameraManager_SetStreamSource(mountPosition, DJI_CAMERA_MANAGER_SOURCE_ZOOM_CAM); if (returnCode != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) { @@ -1917,7 +1923,7 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, cameraType == DJI_CAMERA_TYPE_H20 || cameraType == DJI_CAMERA_TYPE_P1 || cameraType == DJI_CAMERA_TYPE_L1 || cameraType == DJI_CAMERA_TYPE_M30 || cameraType == DJI_CAMERA_TYPE_M3E || cameraType == DJI_CAMERA_TYPE_M3D || - cameraType == DJI_CAMERA_TYPE_L2) { + cameraType == DJI_CAMERA_TYPE_L2 || cameraType == DJI_CAMERA_TYPE_H30) { USER_LOG_WARN("Camera type %s don't support FFC function.", s_cameraTypeStrList[DjiTest_CameraManagerGetCameraTypeIndex(cameraType)].cameraTypeStr); goto exitCameraModule; @@ -1963,7 +1969,7 @@ T_DjiReturnCode DjiTest_CameraManagerRunSample(E_DjiMountPosition mountPosition, cameraType == DJI_CAMERA_TYPE_H20 || cameraType == DJI_CAMERA_TYPE_P1 || cameraType == DJI_CAMERA_TYPE_L1 || cameraType == DJI_CAMERA_TYPE_M30 || cameraType == DJI_CAMERA_TYPE_M3E || cameraType == DJI_CAMERA_TYPE_M3D || - cameraType == DJI_CAMERA_TYPE_L2) { + cameraType == DJI_CAMERA_TYPE_L2 || cameraType == DJI_CAMERA_TYPE_H30) { USER_LOG_WARN("Camera type %s don't support infrared function.", s_cameraTypeStrList[DjiTest_CameraManagerGetCameraTypeIndex(cameraType)].cameraTypeStr); goto exitCameraModule; @@ -2299,7 +2305,7 @@ static T_DjiReturnCode DjiTest_CameraManagerDownloadFileDataCallback(T_DjiDownlo { int32_t i =0, j = 0; float downloadSpeed = 0.0f; - uint32_t mediaFileIndex = 0, mediaSubFileIndex = -1; + int32_t mediaFileIndex = 0, mediaSubFileIndex = -1; T_DjiOsalHandler *osalHandler = DjiPlatform_GetOsalHandler(); if (packetInfo.downloadFileEvent == DJI_DOWNLOAD_FILE_EVENT_START) { @@ -2409,7 +2415,7 @@ static T_DjiReturnCode DjiTest_CameraManagerDownloadFileDataCallback(T_DjiDownlo packetInfo.progressInPercent, downloadFileName, packetInfo.fileSize, packetInfo.fileIndex); printf("\033[1A"); - downloadSpeed = (float) packetInfo.fileSize / 1.0; + downloadSpeed = (float) packetInfo.fileSize / 1.0F; printf("\033[1;32;40m ### [Complete rate : %0.1f%%] (%s), size: %u, mediaFileIndex: %d\033[0m\r\n", packetInfo.progressInPercent, downloadFileName, packetInfo.fileSize, packetInfo.fileIndex); printf("\033[1A"); diff --git a/samples/sample_c/module_sample/data_transmission/test_data_transmission.c b/samples/sample_c/module_sample/data_transmission/test_data_transmission.c index 762f995..2fc3465 100644 --- a/samples/sample_c/module_sample/data_transmission/test_data_transmission.c +++ b/samples/sample_c/module_sample/data_transmission/test_data_transmission.c @@ -45,6 +45,9 @@ static T_DjiReturnCode ReceiveDataFromMobile(const uint8_t *data, uint16_t len); static T_DjiReturnCode ReceiveDataFromCloud(const uint8_t *data, uint16_t len); static T_DjiReturnCode ReceiveDataFromExtensionPort(const uint8_t *data, uint16_t len); static T_DjiReturnCode ReceiveDataFromPayload(const uint8_t *data, uint16_t len); +static T_DjiReturnCode ReceiveDataFromPayload1(const uint8_t *data, uint16_t len); +static T_DjiReturnCode ReceiveDataFromPayload2(const uint8_t *data, uint16_t len); +static T_DjiReturnCode ReceiveDataFromPayload3(const uint8_t *data, uint16_t len); /* Private variables ---------------------------------------------------------*/ static T_DjiTaskHandle s_userDataTransmissionThread; @@ -116,7 +119,21 @@ T_DjiReturnCode DjiTest_DataTransmissionStartService(void) } else if (s_aircraftInfoBaseInfo.mountPosition == DJI_MOUNT_POSITION_EXTENSION_PORT || DJI_MOUNT_POSITION_EXTENSION_LITE_PORT == s_aircraftInfoBaseInfo.mountPosition) { channelAddress = DJI_CHANNEL_ADDRESS_PAYLOAD_PORT_NO1; - djiStat = DjiLowSpeedDataChannel_RegRecvDataCallback(channelAddress, ReceiveDataFromPayload); + djiStat = DjiLowSpeedDataChannel_RegRecvDataCallback(channelAddress, ReceiveDataFromPayload1); + if (djiStat != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) { + USER_LOG_ERROR("register receive data from payload NO1 error."); + return DJI_ERROR_SYSTEM_MODULE_CODE_UNKNOWN; + } + + channelAddress = DJI_CHANNEL_ADDRESS_PAYLOAD_PORT_NO2; + djiStat = DjiLowSpeedDataChannel_RegRecvDataCallback(channelAddress, ReceiveDataFromPayload2); + if (djiStat != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) { + USER_LOG_ERROR("register receive data from payload NO1 error."); + return DJI_ERROR_SYSTEM_MODULE_CODE_UNKNOWN; + } + + channelAddress = DJI_CHANNEL_ADDRESS_PAYLOAD_PORT_NO3; + djiStat = DjiLowSpeedDataChannel_RegRecvDataCallback(channelAddress, ReceiveDataFromPayload3); if (djiStat != DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS) { USER_LOG_ERROR("register receive data from payload NO1 error."); return DJI_ERROR_SYSTEM_MODULE_CODE_UNKNOWN; @@ -349,4 +366,22 @@ static T_DjiReturnCode ReceiveDataFromPayload(const uint8_t *data, uint16_t len) return DJI_ERROR_SYSTEM_MODULE_CODE_SUCCESS; } +static T_DjiReturnCode ReceiveDataFromPayload1(const uint8_t *data, uint16_t len) +{ + USER_LOG_INFO("Receive from payload on port 1"); + return ReceiveDataFromPayload(data, len); +} + +static T_DjiReturnCode ReceiveDataFromPayload2(const uint8_t *data, uint16_t len) +{ + USER_LOG_INFO("Receive from payload on port 2"); + return ReceiveDataFromPayload(data, len); +} + +static T_DjiReturnCode ReceiveDataFromPayload3(const uint8_t *data, uint16_t len) +{ + USER_LOG_INFO("Receive from payload on port 3"); + return ReceiveDataFromPayload(data, len); +} + /****************** (C) COPYRIGHT DJI Innovations *****END OF FILE****/ diff --git a/samples/sample_c/module_sample/widget_interaction_test/widget_file_c/en_big_screen/widget_config_json.h b/samples/sample_c/module_sample/widget_interaction_test/widget_file_c/en_big_screen/widget_config_json.h index d731904..db6e5fc 100644 --- a/samples/sample_c/module_sample/widget_interaction_test/widget_file_c/en_big_screen/widget_config_json.h +++ b/samples/sample_c/module_sample/widget_interaction_test/widget_file_c/en_big_screen/widget_config_json.h @@ -6,9 +6,9 @@ /* Contents of file widget_config.json */ #define widget_config_json_fileName "widget_config.json" -#define widget_config_json_fileSize 7255 +#define widget_config_json_fileSize sizeof(widget_config_json_fileBinaryArray) -static const uint8_t widget_config_json_fileBinaryArray[7255] = { +static const uint8_t widget_config_json_fileBinaryArray[] = { 0x7B, 0x0A, 0x20, 0x20, 0x22, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6F, 0x6E, 0x22, 0x3A, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x22, 0x6D, 0x61, 0x6A, 0x6F, 0x72, 0x22, 0x3A, 0x20, 0x31, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x22, 0x6D, 0x69, 0x6E, 0x6F, 0x72, 0x22, 0x3A, 0x20, 0x30, 0x0A, @@ -353,116 +353,111 @@ static const uint8_t widget_config_json_fileBinaryArray[7255] = { 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x34, 0x5F, 0x74, - 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x41, 0x45, 0x42, 0x5F, 0x70, - 0x68, 0x6F, 0x74, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, - 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x35, 0x5F, 0x74, 0x65, 0x73, 0x74, - 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x62, 0x75, 0x72, 0x73, 0x74, 0x5F, 0x70, 0x68, - 0x6F, 0x74, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, - 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, - 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x36, 0x5F, 0x74, 0x65, 0x73, 0x74, 0x5F, - 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x69, 0x6E, 0x74, 0x65, 0x72, 0x76, 0x61, 0x6C, 0x5F, - 0x70, 0x68, 0x6F, 0x74, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, - 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x37, 0x5F, 0x74, 0x65, 0x73, - 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x72, 0x65, 0x63, 0x6F, 0x72, 0x64, 0x65, - 0x72, 0x5F, 0x76, 0x69, 0x64, 0x65, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, - 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x38, 0x5F, 0x74, - 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x6D, 0x65, 0x64, 0x69, 0x61, - 0x5F, 0x64, 0x6F, 0x77, 0x6E, 0x6C, 0x6F, 0x61, 0x64, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x39, - 0x5F, 0x74, 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x74, 0x68, 0x65, - 0x72, 0x6D, 0x6F, 0x6D, 0x65, 0x74, 0x72, 0x79, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x5D, 0x0A, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, - 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, - 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x30, 0x2C, 0x0A, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x74, 0x79, 0x70, - 0x65, 0x22, 0x3A, 0x20, 0x22, 0x62, 0x75, 0x74, 0x74, 0x6F, 0x6E, 0x22, 0x2C, 0x0A, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x6E, 0x61, - 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x52, 0x75, 0x6E, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, - 0x78, 0x22, 0x3A, 0x20, 0x31, 0x31, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x74, 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, - 0x6C, 0x69, 0x73, 0x74, 0x22, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, - 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x50, - 0x6C, 0x65, 0x61, 0x73, 0x65, 0x20, 0x53, 0x65, 0x6C, 0x65, 0x63, 0x74, 0x20, 0x45, 0x72, 0x72, - 0x63, 0x6F, 0x64, 0x65, 0x22, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, - 0x6C, 0x69, 0x73, 0x74, 0x5F, 0x69, 0x74, 0x65, 0x6D, 0x22, 0x3A, 0x20, 0x5B, 0x0A, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, - 0x22, 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x30, 0x22, 0x0A, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, - 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x31, 0x22, 0x0A, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, - 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x32, 0x22, 0x0A, 0x20, 0x20, + 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x62, 0x75, 0x72, 0x73, 0x74, + 0x5F, 0x70, 0x68, 0x6F, 0x74, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, + 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, + 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x35, 0x5F, 0x74, 0x65, + 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x69, 0x6E, 0x74, 0x65, 0x72, 0x76, + 0x61, 0x6C, 0x5F, 0x70, 0x68, 0x6F, 0x74, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, + 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, 0x36, 0x5F, + 0x74, 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x72, 0x65, 0x63, 0x6F, + 0x72, 0x64, 0x65, 0x72, 0x5F, 0x76, 0x69, 0x64, 0x65, 0x6F, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x32, + 0x37, 0x5F, 0x74, 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, 0x6D, 0x65, + 0x64, 0x69, 0x61, 0x5F, 0x64, 0x6F, 0x77, 0x6E, 0x6C, 0x6F, 0x61, 0x64, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, - 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x33, 0x22, 0x0A, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, - 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x34, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x5D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, - 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x32, 0x2C, 0x0A, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x74, - 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x6C, 0x69, 0x73, 0x74, 0x22, 0x2C, 0x0A, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x6E, 0x61, - 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x50, 0x6C, 0x65, 0x61, 0x73, 0x65, 0x20, 0x53, 0x65, 0x6C, - 0x65, 0x63, 0x74, 0x20, 0x45, 0x72, 0x72, 0x4C, 0x65, 0x76, 0x65, 0x6C, 0x22, 0x2C, 0x0A, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x6C, 0x69, 0x73, 0x74, 0x5F, 0x69, 0x74, 0x65, - 0x6D, 0x22, 0x3A, 0x20, 0x5B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, - 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x45, 0x72, 0x72, 0x6F, - 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x30, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, - 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x45, 0x72, 0x72, - 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x31, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x45, 0x72, - 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x32, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x22, 0x32, 0x38, 0x5F, 0x74, 0x65, 0x73, 0x74, 0x5F, 0x63, 0x61, 0x6D, 0x6D, 0x67, 0x72, 0x2D, + 0x74, 0x68, 0x65, 0x72, 0x6D, 0x6F, 0x6D, 0x65, 0x74, 0x72, 0x79, 0x22, 0x0A, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x5D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, + 0x67, 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x30, 0x2C, 0x0A, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, + 0x74, 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x62, 0x75, 0x74, 0x74, 0x6F, 0x6E, 0x22, 0x2C, + 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, + 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x52, 0x75, 0x6E, 0x22, 0x0A, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x69, + 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x31, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x74, 0x79, 0x70, 0x65, 0x22, + 0x3A, 0x20, 0x22, 0x6C, 0x69, 0x73, 0x74, 0x22, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, + 0x20, 0x22, 0x50, 0x6C, 0x65, 0x61, 0x73, 0x65, 0x20, 0x53, 0x65, 0x6C, 0x65, 0x63, 0x74, 0x20, + 0x45, 0x72, 0x72, 0x63, 0x6F, 0x64, 0x65, 0x22, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x22, 0x6C, 0x69, 0x73, 0x74, 0x5F, 0x69, 0x74, 0x65, 0x6D, 0x22, 0x3A, 0x20, 0x5B, + 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, + 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, + 0x30, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, + 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x31, + 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, + 0x65, 0x22, 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x32, 0x22, + 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, + 0x22, 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x33, 0x22, 0x0A, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, + 0x3A, 0x20, 0x22, 0x30, 0x78, 0x31, 0x45, 0x30, 0x32, 0x30, 0x30, 0x30, 0x34, 0x22, 0x0A, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x5D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, + 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x32, + 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, + 0x74, 0x5F, 0x74, 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x6C, 0x69, 0x73, 0x74, 0x22, 0x2C, + 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, + 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x50, 0x6C, 0x65, 0x61, 0x73, 0x65, 0x20, + 0x53, 0x65, 0x6C, 0x65, 0x63, 0x74, 0x20, 0x45, 0x72, 0x72, 0x4C, 0x65, 0x76, 0x65, 0x6C, 0x22, + 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x6C, 0x69, 0x73, 0x74, 0x5F, + 0x69, 0x74, 0x65, 0x6D, 0x22, 0x3A, 0x20, 0x5B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x45, - 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x33, 0x22, 0x0A, 0x20, 0x20, 0x20, + 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x30, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, - 0x45, 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x34, 0x22, 0x0A, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x5D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, - 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, - 0x64, 0x67, 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x33, 0x2C, - 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, - 0x5F, 0x74, 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x62, 0x75, 0x74, 0x74, 0x6F, 0x6E, 0x22, + 0x45, 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x31, 0x22, 0x0A, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, + 0x22, 0x45, 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x32, 0x22, 0x0A, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, + 0x20, 0x22, 0x45, 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x33, 0x22, 0x0A, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x69, 0x74, 0x65, 0x6D, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, + 0x3A, 0x20, 0x22, 0x45, 0x72, 0x72, 0x6F, 0x72, 0x20, 0x6C, 0x65, 0x76, 0x65, 0x6C, 0x34, 0x22, + 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x5D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, + 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, + 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, + 0x31, 0x33, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, + 0x67, 0x65, 0x74, 0x5F, 0x74, 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x62, 0x75, 0x74, 0x74, + 0x6F, 0x6E, 0x22, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, + 0x64, 0x67, 0x65, 0x74, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x49, 0x6E, 0x6A, + 0x65, 0x63, 0x74, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, + 0x20, 0x20, 0x20, 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, + 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x34, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, - 0x74, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x49, 0x6E, 0x6A, 0x65, 0x63, 0x74, - 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, - 0x20, 0x7B, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, - 0x65, 0x74, 0x5F, 0x69, 0x6E, 0x64, 0x65, 0x78, 0x22, 0x3A, 0x20, 0x31, 0x34, 0x2C, 0x0A, 0x20, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, 0x74, - 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x62, 0x75, 0x74, 0x74, 0x6F, 0x6E, 0x22, 0x2C, 0x0A, - 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, 0x65, 0x74, 0x5F, - 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x45, 0x6C, 0x69, 0x6D, 0x69, 0x6E, 0x61, 0x74, - 0x65, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x5D, - 0x0A, 0x20, 0x20, 0x7D, 0x0A, 0x7D, 0x0A + 0x74, 0x5F, 0x74, 0x79, 0x70, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x62, 0x75, 0x74, 0x74, 0x6F, 0x6E, + 0x22, 0x2C, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x77, 0x69, 0x64, 0x67, + 0x65, 0x74, 0x5F, 0x6E, 0x61, 0x6D, 0x65, 0x22, 0x3A, 0x20, 0x22, 0x45, 0x6C, 0x69, 0x6D, 0x69, + 0x6E, 0x61, 0x74, 0x65, 0x22, 0x0A, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7D, 0x0A, 0x20, 0x20, + 0x20, 0x20, 0x5D, 0x0A, 0x20, 0x20, 0x7D, 0x0A, 0x7D, }; #endif /* __widget_config_json_h_included */ diff --git a/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/application/dji_sdk_config.h b/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/application/dji_sdk_config.h index 4beed11..cebf81a 100644 --- a/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/application/dji_sdk_config.h +++ b/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/application/dji_sdk_config.h @@ -44,7 +44,7 @@ extern "C" { #define CONFIG_MODULE_SAMPLE_FC_SUBSCRIPTION_ON -// #define CONFIG_MODULE_SAMPLE_GIMBAL_EMU_ON +#define CONFIG_MODULE_SAMPLE_GIMBAL_EMU_ON // #define CONFIG_MODULE_SAMPLE_CAMERA_ON diff --git a/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.sct b/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.sct new file mode 100644 index 0000000..14519bf --- /dev/null +++ b/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.sct @@ -0,0 +1,14 @@ +LR_IROM1 0x08010000 0x00070000 { + ER_IROM1 0x08010000 0x00070000 { + *.o (RESET, +First) + *(InRoot$$Sections) + .ANY (+RO) + .ANY (+XO) + } + CCMRAM 0x10000000 0x00400000 { + .ANY (.ccmram) + } + RW_IRAM1 0x20000000 0x00020000 { + .ANY (+RW +ZI) + } +} diff --git a/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.uvprojx b/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.uvprojx index b0e5339..b7faa0d 100644 --- a/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.uvprojx +++ b/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/mdk/mdk_app.uvprojx @@ -382,7 +382,7 @@ -1 +0mdk_app.sct 0 0 0