DJI Mobile SDK Documentation

      class DJIFlightControllerKey

      class DJIFlightControllerKey
      包:dji.sdk.keyvalue.key
      描述:

      DJIFlightControllerKey提供了一组方法来获取飞控数据、设置飞控参数和设置飞控行为。飞行控制器是一台机载计算机,它将来自飞手的控制信息与传感器信息相结合,用于调节每桨叶的动力,并根据需要进行飞行。此类可以获取飞行姿态、飞行器状态、飞行模式,可进行飞行控制设置、参数获取、指南针和IMU校准等功能。

      此类从MSDK 5.0开始支持

      类成员:

      基础信息

      连接状态
      final KeyConnection
      static final DJIKeyInfo<Boolean> KeyConnection = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"Connection", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示飞控已连接。

      MSDK 5.0开始支持

      飞行状态
      final KeyIsFlying
      static final DJIKeyInfo<Boolean> KeyIsFlying = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsFlying", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      true表示飞行器在飞行中。

      MSDK 5.0开始支持

      final KeyFlightTimeInSeconds
      static final DJIKeyInfo<Integer> KeyFlightTimeInSeconds = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"FlightTimeInSeconds", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      自飞行器电机起转以来累计的飞行时间,单位:0.1秒。重新上电后清零。

      MSDK 5.0开始支持

      飞行器位置
      final KeyAircraftLocation3D
      static final DJIKeyInfo<LocationCoordinate3D> KeyAircraftLocation3D = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"AircraftLocation3D", new DJIValueConverter<>(LocationCoordinate3D.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      TODO: 有问题,需要确认KeyAircraftLocation,KeyAircraftLocation3D ,KeyAltitude上面三个key之间的关系?

      MSDK 5.0开始支持

      飞行器姿态数据
      final KeyAircraftAttitude
      static final DJIKeyInfo<Attitude> KeyAircraftAttitude = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"AircraftAttitude", new DJIValueConverter<>(Attitude.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false).setInnerIdentifier("Attitude")
      包:dji.sdk.keyvalue.key
      描述:

      参数: Attitude

      飞行器当前姿态数据。俯仰、横滚和偏航值的范围:[-180,180]。如果其俯仰、横滚和偏航值为0,则表示飞行器将以正北方向水平悬停。

      MSDK 5.0开始支持

      飞行器速度
      final KeyAircraftVelocity
      static final DJIKeyInfo<Velocity3D> KeyAircraftVelocity = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"AircraftVelocity", new DJIValueConverter<>(Velocity3D.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false).setInnerIdentifier("Velocity")
      包:dji.sdk.keyvalue.key
      描述:

      参数: Velocity3D

      飞行器当前飞行速度,使用北东地(NED)坐标系。

      MSDK 5.0开始支持

      起飞海拔高度
      final KeyTakeoffLocationAltitude
      static final DJIKeyInfo<Double> KeyTakeoffLocationAltitude = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"TakeoffLocationAltitude", SingleValueConverter.DoubleConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Double

      飞行器起飞时的海拔高度,单位为米。

      MSDK 5.0开始支持

      final KeyIsLandingConfirmationNeeded
      static final DJIKeyInfo<Boolean> KeyIsLandingConfirmationNeeded = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsLandingConfirmationNeeded", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示飞行器降落到离地0.5米的时候,需要发送强制降落指令KeyConfirmLanding才能继续降落着陆。

      MSDK 5.0开始支持

      飞行日志
      final KeyFlightLogIndex
      static final DJIKeyInfo<Integer> KeyFlightLogIndex = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"FlightLogIndex", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取当前飞行日志的索引,当需要查找相应的飞行日志时非常有用。

      MSDK 5.0开始支持

      序列号
      final KeySerialNumber
      static final DJIKeyInfo<String> KeySerialNumber = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"SerialNumber", SingleValueConverter.StringConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: String

      获取飞控序列号。

      MSDK 5.0开始支持

      固件版本号
      final KeyFirmwareVersion
      static final DJIKeyInfo<String> KeyFirmwareVersion = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"FirmwareVersion", SingleValueConverter.StringConverter).canGet(true).canSet(false).canListen(false).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: String

      获取飞控固件版本。

      MSDK 5.0开始支持


      传感器

      final KeyGPSSatelliteCount
      static final DJIKeyInfo<Integer> KeyGPSSatelliteCount = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"GPSSatelliteCount", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false).setInnerIdentifier("SatelliteCount")
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取GPS卫星个数。通常在高空飞行能达到12颗星以上,时段良好时能达到18~19颗。

      MSDK 5.0开始支持

      final KeyGPSSignalLevel
      static final DJIKeyInfo<GPSSignalLevel> KeyGPSSignalLevel = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"GPSSignalLevel", new SingleValueConverter<>(GPSSignalLevel.class,FCGPSSignalLevelMsg.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: GPSSignalLevel

      获取GPS信号等级。

      MSDK 5.0开始支持

      指南针
      final KeyCompassCount
      static final DJIKeyInfo<Integer> KeyCompassCount = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"CompassCount", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取指南针个数。

      MSDK 5.0开始支持

      final KeyCompassHeading
      static final DJIKeyInfo<Double> KeyCompassHeading = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"CompassHeading", SingleValueConverter.DoubleConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Double

      获取指南针朝向,单位:度。正北为0度,正东为90度,范围:[-180,180]。

      MSDK 5.0开始支持

      final KeyCompassHasError
      static final DJIKeyInfo<Boolean> KeyCompassHasError = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"CompassHasError", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示指南针数据错误。当飞行器在强干扰或磁场区域使用时,可能出现指南针数据错误。你需要调用KeyStartCompassCalibration进行指南针校准。

      MSDK 5.0开始支持

      final KeyStartCompassCalibration
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStartCompassCalibration = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StartCompassCalibration", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      启动指南针校准。确保飞行器附近没有磁铁或金属物体。你可以通过KeyCompassCalibrationStatus获取校准状态。

      MSDK 5.0开始支持

      final KeyStopCompassCalibration
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStopCompassCalibration = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StopCompassCalibration", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      停止指南针校准。

      MSDK 5.0开始支持

      final KeyIsCompassCalibrating
      static final DJIKeyInfo<Boolean> KeyIsCompassCalibrating = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsCompassCalibrating", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示正在进行指南针校准。

      MSDK 5.0开始支持

      final KeyCompassCalibrationStatus
      static final DJIKeyInfo<CompassCalibrationState> KeyCompassCalibrationStatus = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"CompassCalibrationStatus", new SingleValueConverter<>(CompassCalibrationState.class,FCCompassCalibrationStateMsg.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false).setInnerIdentifier("CompassCalibrationState")
      包:dji.sdk.keyvalue.key
      描述:

      参数: CompassCalibrationState

      获取指南针校准状态。

      MSDK 5.0开始支持

      final KeyIMUCount
      static final DJIKeyInfo<Integer> KeyIMUCount = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IMUCount", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取IMU个数。

      MSDK 5.0开始支持

      final KeyStartIMUCalibration
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStartIMUCalibration = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StartIMUCalibration", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      启动IMU校准。对于具有多个IMU的飞行器,此方法将进行所有IMU的校准。在校准过程中保持飞行器静止和水平,这将需要5到10分钟。通过Key_FlightController_IMUState获取IMU校准的执行状态。建议在IMU校准后调用KeyRebootDevice重启设备。

      MSDK 5.0开始支持

      final KeyIsUltrasonicUsed
      static final DJIKeyInfo<Boolean> KeyIsUltrasonicUsed = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsUltrasonicUsed", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示正在使用超声波测距。通常当飞行器离地高度低于8米时,超声波传感器会开始工作。 TODO:外测:起浆,离地后返回true,一直是true。是否有bug?

      MSDK 5.0开始支持

      final KeyUltrasonicHasError
      static final DJIKeyInfo<Boolean> KeyUltrasonicHasError = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"UltrasonicHasError", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      false表示超声波正常使用中,没有错误。 TODO:什么情况下会true?

      MSDK 5.0开始支持

      final KeyUltrasonicHeight
      static final DJIKeyInfo<Integer> KeyUltrasonicHeight = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"UltrasonicHeight", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取超声波测距高度。高度的精度为0.1米,最大可测距离为25.5米,仅当KeyIsUltrasonicUsed返回true,并且KeyUltrasonicHasError返回false时,数据才可用。 TODO:当高度低于5米时,该值具有参考意义。 外测发现离地就有数据返回,直到255, 是否可以改成单位:秒

      MSDK 5.0开始支持

      final KeyIsVisionSensorUsed
      static final DJIKeyInfo<Boolean> KeyIsVisionSensorUsed = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsVisionSensorUsed", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示正在使用视觉传感器测距。通常当飞行器离地高度小于3米时,并且地面具有足够丰富的纹理时,视觉传感器会开始工作。 TODO:外测结果,一直是false

      MSDK 5.0开始支持

      final KeyWindWarning
      static final DJIKeyInfo<WindWarning> KeyWindWarning = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"WindWarning", new SingleValueConverter<>(WindWarning.class,FCWindWarningMsg.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: WindWarning

      获取当前风速等级。 TODO:外测ok,是否有风速传感器?如果没有的话,不适合放在传感器中。

      MSDK 5.0开始支持

      final KeyWindSpeed
      static final DJIKeyInfo<Integer> KeyWindSpeed = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"WindSpeed", SingleValueConverter.IntegerConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取当前风速,单位:dm/s。 TODO:外测ok,是否有风速传感器?如果没有的话,不适合放在传感器中。

      MSDK 5.0开始支持

      final KeyWindDirection
      static final DJIKeyInfo<WindDirection> KeyWindDirection = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"WindDirection", new SingleValueConverter<>(WindDirection.class,FCWindDirectionStatusMsg.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: WindDirection

      获取当前风向,采用世界坐标系。 TODO:外测ok,是否有风速传感器?如果没有的话,不适合放在传感器中。

      MSDK 5.0开始支持


      基本设置

      final KeyMultipleFlightModeEnabled
      static final DJIKeyInfo<Boolean> KeyMultipleFlightModeEnabled = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"MultipleFlightModeEnabled", SingleValueConverter.BooleanConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示允许切换飞行模式。用户可以通过拨动遥控器上的三段选择开关将飞行模式设置为T三脚架、A姿态、P定位、S运动模式。如果设置为false,飞行器将一直处于P定位模式,不可被更改。可通过KeyCurrentRCFlightMode获取飞行器当前飞行模式。

      MSDK 5.0开始支持

      final KeyCurrentRCFlightMode
      static final DJIKeyInfo<RemoteControllerFlightModeMsg> KeyCurrentRCFlightMode = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"CurrentRCFlightMode", new DJIValueConverter<>(RemoteControllerFlightModeMsg.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: RemoteControllerFlightMode

      获取飞行器当前飞行模式。TODO,需要重新msdk key,修改入参。

      MSDK 5.0开始支持

      final KeyIsFailSafe
      static final DJIKeyInfo<Boolean> KeyIsFailSafe = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsFailSafe", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示飞行器失控中,即将进行失控行为。

      MSDK 5.0开始支持

      final KeyFailsafeAction
      static final DJIKeyInfo<FailsafeAction> KeyFailsafeAction = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"FailsafeAction", new SingleValueConverter<>(FailsafeAction.class,FCFailsafeActionMsg.class)).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: FailsafeAction

      设置和获取失控行为。当遥控器和飞行器失去连接的时候,飞行器将按照设置的失控行为进行操作。

      MSDK 5.0开始支持

      final KeyLowBatteryWarningThreshold
      static final DJIKeyInfo<Integer> KeyLowBatteryWarningThreshold = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"LowBatteryWarningThreshold", SingleValueConverter.IntegerConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      设置和获取电池低电量警告的阈值。该数值为百分比,范围:[15,50]。当电池电量低于该阀值时,飞行器将进行低电量报警。

      MSDK 5.0开始支持

      final KeyIsLowBatteryWarning
      static final DJIKeyInfo<Boolean> KeyIsLowBatteryWarning = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsLowBatteryWarning", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示当前电池处于低电量状态。

      MSDK 5.0开始支持

      final KeySeriousLowBatteryWarningThreshold
      static final DJIKeyInfo<Integer> KeySeriousLowBatteryWarningThreshold = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"SeriousLowBatteryWarningThreshold", SingleValueConverter.IntegerConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      获取电池严重低电量警告的阈值。该值默认为10%,Matrice 30 Series不可设置。当电池电量低于该阀值时,飞行器将进行返航操作。

      MSDK 5.0开始支持

      final KeyIsSeriousLowBatteryWarning
      static final DJIKeyInfo<Boolean> KeyIsSeriousLowBatteryWarning = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsSeriousLowBatteryWarning", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示当前电池处于严重低电量状态。

      MSDK 5.0开始支持

      final KeyLEDsSettings
      static final DJIKeyInfo<LEDsSettings> KeyLEDsSettings = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"LEDsSettings", new DJIValueConverter<>(LEDsSettings.class)).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: LEDsSettings

      LED相关设置。支持前臂灯、状态指示灯、夜航灯的设置。

      MSDK 5.0开始支持

      电机电调
      final KeyAreMotorsOn
      static final DJIKeyInfo<Boolean> KeyAreMotorsOn = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"AreMotorsOn", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示电机起转。

      MSDK 5.0开始支持

      final KeyLockMotors
      static final DJIKeyInfo<Boolean> KeyLockMotors = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"LockMotors", SingleValueConverter.BooleanConverter).canGet(false).canSet(true).canListen(false).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示锁住电机,掰杆后电机将不会转动。 TODO:模拟器不生效,实际外测可以锁住,需要支持get。

      MSDK 5.0开始支持

      final KeyESCBeepEnabled
      static final DJIKeyInfo<Boolean> KeyESCBeepEnabled = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"ESCBeepEnabled", SingleValueConverter.BooleanConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示开启电调鸣叫功能。当飞行器不慎失联,可开启此功能,通过声音辨别飞行器方位。

      MSDK 5.0开始支持

      final KeyCoordinatedTurnEnabled
      static final DJIKeyInfo<Boolean> KeyCoordinatedTurnEnabled = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"CoordinatedTurnEnabled", SingleValueConverter.BooleanConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示开启协调转弯功能。飞行器转弯时机头跟随飞行方向,没有侧滑的飞行,飞行阻力更小。

      MSDK 5.0开始支持

      final KeyNavigationSatelliteSystemSource
      static final DJIKeyInfo<NavigationSatelliteSystem> KeyNavigationSatelliteSystemSource = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"NavigationSatelliteSystemSource", new SingleValueConverter<>(NavigationSatelliteSystem.class,NavigationSatelliteSystemMsg.class)).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: NavigationSatelliteSystem

      设置使用的卫星定位系统,仅在RTK定位功能关闭下支持设置卫星定位系统,飞行器在空中无法进行修改。切换卫星定位系统后,请确认卫星信号LEVEL_3以上再起飞。如果你开启了RTK定位功能,飞控会同时使用GPS、GLONASS、Galileo和北斗卫星定位系统。

      MSDK 5.0开始支持


      基本操作

      final KeyStartTakeoff
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStartTakeoff = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StartTakeoff", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      启动飞行器自主起飞。当飞行器悬停在离地面1.2米(4英尺)的高度时表示起飞完成。如果电机已经开启,将无法执行此命令。

      MSDK 5.0开始支持

      final KeyPrecisionStartTakeoff
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyPrecisionStartTakeoff = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"PrecisionStartTakeoff", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      启动飞行器自主精准起飞。飞行器将垂直起飞到7m以上,将自动搜集起飞点附近信息,如果信息搜集充分,返航时会精准降落到起飞点。如需要进行精准降落请调用Key_FlightAssistant_PrecisionLandingEnabled开启精准降落功能。

      MSDK 5.0开始支持

      final KeyStopTakeoff
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStopTakeoff = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StopTakeoff", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      停止飞行器自主起飞。如果在自主起飞完成之前调用此接口,飞行器将取消起飞并悬停在当前高度。如果已经自主起飞已经完成,将无法执行此命令。

      MSDK 5.0开始支持

      final KeyStartAutoLanding
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStartAutoLanding = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StartAutoLanding", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      启动飞行器自主降落。

      MSDK 5.0开始支持

      final KeyStopAutoLanding
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStopAutoLanding = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StopAutoLanding", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      停止飞行器自主降落。如果在自主降落过程中调用此接口,飞行器将会停止自主降落,并且悬停在当前位置。

      MSDK 5.0开始支持

      final KeyConfirmLanding
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyConfirmLanding = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"ConfirmLanding", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      确认继续降落着陆。当飞行器与地面的距离小于0.7m时,飞行器将暂停着陆,等待用户确认。 可以通过KeyIsLandingConfirmationNeeded来检查是否需要确认降落。

      MSDK 5.0开始支持

      final KeyRebootDevice
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyRebootDevice = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"RebootDevice", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      重启飞行器的核心设备。建议在IMU校准后调用此方法。

      MSDK 5.0开始支持

      final KeyHeightLimitRange
      static final DJIKeyInfo<IntMinMax> KeyHeightLimitRange = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"HeightLimitRange", new DJIValueConverter<>(IntMinMax.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: IntMinMax

      获取限高设置范围,单位:米。

      MSDK 5.0开始支持

      final KeyHeightLimit
      static final DJIKeyInfo<Integer> KeyHeightLimit = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"HeightLimit", SingleValueConverter.IntegerConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      设置飞行器的最大飞行高度。单位:米。可通过KeyHeightLimitRange获取设置范围。

      MSDK 5.0开始支持

      final KeyIsNearHeightLimit
      static final DJIKeyInfo<Boolean> KeyIsNearHeightLimit = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsNearHeightLimit", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示飞行器已达到最大飞行高度。

      MSDK 5.0开始支持

      final KeyDistanceLimitEnabled
      static final DJIKeyInfo<Boolean> KeyDistanceLimitEnabled = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"DistanceLimitEnabled", SingleValueConverter.BooleanConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示开启限远开关。开启此开关后,你可以通过KeyDistanceLimit设置飞行器的最大飞行距离。

      MSDK 5.0开始支持

      final KeyDistanceLimitRange
      static final DJIKeyInfo<IntMinMax> KeyDistanceLimitRange = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"DistanceLimitRange", new DJIValueConverter<>(IntMinMax.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: IntMinMax

      获取限远设置范围,单位:米。

      MSDK 5.0开始支持

      final KeyDistanceLimit
      static final DJIKeyInfo<Integer> KeyDistanceLimit = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"DistanceLimit", SingleValueConverter.IntegerConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      设置飞行器的最大飞行距离。单位:米。此距离是飞行器与返航点之间的距离。可通过KeyDistanceLimitRange获取设置范围。

      MSDK 5.0开始支持

      final KeyIsNearDistanceLimit
      static final DJIKeyInfo<Boolean> KeyIsNearDistanceLimit = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsNearDistanceLimit", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示飞行器已达到最大飞行距离。

      MSDK 5.0开始支持


      返航功能

      final KeyIsHomeLocationSet
      static final DJIKeyInfo<Boolean> KeyIsHomeLocationSet = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"IsHomeLocationSet", SingleValueConverter.BooleanConverter).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示返航点已设置。当GPS信号良好时,飞行器会自动把当前飞行器位置设置为返航点,此时KeyIsHomeLocationSet将返回true

      MSDK 5.0开始支持

      final KeyHomeLocation
      static final DJIKeyInfo<LocationCoordinate2D> KeyHomeLocation = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"HomeLocation", new DJIValueConverter<>(LocationCoordinate2D.class)).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: LocationCoordinate2D

      设置和获取当前返航点的位置。当GPS信号良好时,飞行器会自动把当前飞行器位置设置为返航点,你也可以使用这个key改变返航点位置。TODO:增加飞行器home点和遥控器home点的连接。

      MSDK 5.0开始支持

      final KeyGoHomeHeight
      static final DJIKeyInfo<Integer> KeyGoHomeHeight = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"GoHomeHeight", SingleValueConverter.IntegerConverter).canGet(true).canSet(true).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: Integer

      设置和获取返航时的相对高度,单位:米。此相对高度是相对于起飞时的高度。可通过KeyGoHomeHeightRange获取返航高度设置范围。 如果飞行器水平距离返航点50米内,飞行器将忽略设置的返航高度,以飞行器当前高度返航。如果此时前视视觉系统未正常工作,飞行器将上升到预设的高度进行返航。

      MSDK 5.0开始支持

      final KeyGoHomeHeightRange
      static final DJIKeyInfo<IntMinMax> KeyGoHomeHeightRange = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"GoHomeHeightRange", new DJIValueConverter<>(IntMinMax.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: IntMinMax

      获取返航高度设置范围,单位:米。

      MSDK 5.0开始支持

      final KeyHomeLocationUsingCurrentAircraftLocation
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyHomeLocationUsingCurrentAircraftLocation = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"HomeLocationUsingCurrentAircraftLocation", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      将飞行器的当前位置设置为返航点位置。

      MSDK 5.0开始支持

      final KeyHomeLocationUsingCurrentRemoteControllerLocation
      static final DJIActionKeyInfo<LocationCoordinate2D,EmptyMsg> KeyHomeLocationUsingCurrentRemoteControllerLocation = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"HomeLocationUsingCurrentRemoteControllerLocation", new DJIValueConverter<>(LocationCoordinate2D.class),EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      参数: LocationCoordinate2D

      将遥控器的当前位置设置为返航点位置。TODO:为啥要设置一个2D坐标?是否有用?

      MSDK 5.0开始支持

      final KeyStartGoHome
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStartGoHome = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StartGoHome", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      启动智能返航。当GPS信号不好的时候,不可启动智能返航功能。你也可以通过遥控器智能返航按键启动智能返航,返航过程用户可通过油门杆控制飞行器高度和俯仰杆控制飞行器速度以躲避障碍物。返航过程中,通过遥控器上的智能返航按键或者调用KeyStopGoHome退出智能返航后,用户可重新获得飞行器控制权。你可以通过KeyGoHomeStatus获取智能返航状态。

      MSDK 5.0开始支持

      final KeyStopGoHome
      static final DJIActionKeyInfo<EmptyMsg,EmptyMsg> KeyStopGoHome = new DJIActionKeyInfo<>(componentType.value(),subComponentType.value(),"StopGoHome", EmptyValueConverter.converter,EmptyValueConverter.converter).canGet(false).canSet(false).canListen(false).canPerformAction(true).setIsEvent(false)
      包:dji.sdk.keyvalue.key
      描述:

      停止智能返航。

      MSDK 5.0开始支持

      final KeyGoHomeStatus
      static final DJIKeyInfo<GoHomeState> KeyGoHomeStatus = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"GoHomeStatus", new SingleValueConverter<>(GoHomeState.class,FCGoHomeStateMsg.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false).setInnerIdentifier("GoHomeState")
      包:dji.sdk.keyvalue.key
      描述:

      参数: GoHomeState

      获取智能返航状态。

      MSDK 5.0开始支持

      低电量返航
      final KeyLowBatteryRTHEnabled
      static final DJIKeyInfo<Boolean> KeyLowBatteryRTHEnabled = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"LowBatteryRTHEnabled", SingleValueConverter.BooleanConverter).canGet(true).canSet(true).canListen(false).canPerformAction(false).setIsEvent(false).setInnerIdentifier("SmartBatteryRTHEnabled")
      包:dji.sdk.keyvalue.key
      描述:

      参数: Boolean

      true表示开启智能低电量返航功能。为防止因电池电量不足而出现不必要的危险,飞行器将会根据飞行的位置信息,智能地判断当前电量是否充足。若当前电量仅够完成返航过程,MSDK将提示是否需要执行返航。若用户在10秒内不作选择,则10秒后飞行器将自动进入返航。返航过程中可短按遥控器智能返航按键取消返航过程。智能低电量返航在同一次飞行过程中仅出现一次。如果用户取消低电量返航提醒并继续飞行,将可能导致飞行器返回时电量不足而迫降,造成飞行器丢失或坠毁。为了安全起见,不建议关闭此功能。 TODO:需要外测

      MSDK 5.0开始支持

      final KeyLowBatteryRTHInfo
      static final DJIKeyInfo<LowBatteryRTHInfo> KeyLowBatteryRTHInfo = new DJIKeyInfo<>(componentType.value(),subComponentType.value(),"LowBatteryRTHInfo", new DJIValueConverter<>(LowBatteryRTHInfo.class)).canGet(true).canSet(false).canListen(true).canPerformAction(false).setIsEvent(false).setInnerIdentifier("GoHomeAssessment")
      包:dji.sdk.keyvalue.key
      描述:

      参数: LowBatteryRTHInfo

      获取智能低电量返航相关信息。仅在KeyLowBatteryRTHEnabled开启后有效。 TODO:需要外测,文案措辞需要根据外测情况重新组织

      MSDK 5.0开始支持