DJI Mobile SDK Documentation

      class GoHomeAssessment

      @EXClassNullAway
      final class GoHomeAssessment
      Package:dji.common.flightcontroller
      Description:

      Class for smart go home status.

      Class Members:
      method getRemainingFlightTime
      int getRemainingFlightTime()
      Package:dji.common.flightcontroller
      SDK Key:FlightControllerKey.REMAINING_FLIGHT_TIME
      Description:

      The estimated remaining time, in seconds, it will take the aircraft to go home with a 10% battery buffer remaining. This time includes landing the aircraft. If the aircraft is using the simulator, this value will be 0.

      Return:
      intAn int value.
      method getTimeNeededToGoHome
      int getTimeNeededToGoHome()
      Package:dji.common.flightcontroller
      SDK Key:FlightControllerKey.TIME_NEEDED_TO_GO_HOME
      Description:

      The estimated time, in seconds, needed for the aircraft to go home from its current location.

      Return:
      intAn int value.
      method getTimeNeededToLandFromCurrentHeight
      int getTimeNeededToLandFromCurrentHeight()
      Package:dji.common.flightcontroller
      SDK Key:FlightControllerKey.TIME_NEEDED_TO_LAND_FROM_CURRENT_HEIGHT
      Description:

      The estimated time, in seconds, needed for the aircraft to move downward from its current position and land.

      Return:
      intAn int value.
      method getBatteryPercentageNeededToGoHome
      int getBatteryPercentageNeededToGoHome()
      Package:dji.common.flightcontroller
      SDK Key:FlightControllerKey.BATTERY_PERCENTAGE_NEEDED_TO_GO_HOME
      Description:

      The estimated battery percentage, in the range of [0,100], needed for the aircraft to go home and have 10% battery remaining. This includes landing of the aircraft.

      Return:
      intAn int value.
      method getBatteryPercentageNeededToLandFromCurrentHeight
      int getBatteryPercentageNeededToLandFromCurrentHeight()
      Package:dji.common.flightcontroller
      SDK Key:FlightControllerKey.CURRENT_LAND_IMMEDIATELY_BATTERY
      Description:

      The battery percentage, in the range of [0,100], needed for the aircraft to move downward from its current position and land.

      Return:
      intBattery percentage.
      method getMaxRadiusAircraftCanFlyAndGoHome
      float getMaxRadiusAircraftCanFlyAndGoHome()
      Package:dji.common.flightcontroller
      SDK Key:FlightControllerKey.MAX_RADIUS_AIRCRAFT_CAN_FLY_AND_GO_HOME
      Description:

      The maximum radius, in meters, an aircraft can fly from its home location and still make it all the way back home, based on altitude, distance, battery, etc. If the aircraft goes out farther than the max radius, it will fly as far back home as it can and land. If the aircraft is using the simulator, this value will be 0.

      Return:
      floatA float value.
      method getSmartRTHState
      SmartRTHState getSmartRTHState()
      Package:dji.common.flightcontroller
      Description:

      The Smart Return-To-Home (RTH) state for the current flight.

      Return:
      SmartRTHStateAn enum value of SmartRTHState.
      method getSmartRTHCountdown
      int getSmartRTHCountdown()
      Package:dji.common.flightcontroller
      Description:

      The countdown (in seconds) for the Smart Return-To-Home (RTH). Once the countdown reaches 0, the aircraft will execute an automatic go-home procedure. It is only valid when getSmartRTHState is COUNTING_DOWN.

      Return:
      intThe countdown for the Smart Return-To-Home (RTH).