DJI Mobile SDK Documentation

      class RTKNetworkServiceProvider

      class RTKNetworkServiceProvider
      Package:dji.sdk.network
      Description:

      This class is used to control the RTK network service. The DJIRTKNetworkServiceProvider can initiate the communication to a third-party RTK network server. The information from the server can be streamed to the RTK airsystem. SDK will not cache the settings to the disk. The provider should be configured in each life cycle of SDK. The life cycle of the network service provider is independent from the aircraft. Therefore, it can be configured before connecting to DJI aircrafts. It is only supported by Phantom 4 RTK and Matrice 210 RTK V2.

      Class Members:
      Get Instance
      method
      method getInstance
      synchronized static RTKNetworkServiceProvider getInstance()
      Package:dji.sdk.network
      Description:

      Accessor for RTKNetworkServiceProvider object.

      Return:
      synchronized static RTKNetworkServiceProviderAn instance of the RTKNetworkServiceProvider object.
      Set Network Service Settings
      method
      method setCustomNetworkSettings
      void setCustomNetworkSettings(@NonNull final NetworkServiceSettings settings)
      Package:dji.sdk.network
      Description:

      Sets the configuration for the network service that provides network reference stations. The network service should use NTRIP (Networked Transport of RTCM via Internet Protocol).

      Input Parameters:
      @NonNull final NetworkServiceSettings settingsThe configuration to set.
      method getCustomNetworkSettings
      NetworkServiceSettings getCustomNetworkSettings()
      Package:dji.sdk.network
      Description:

      Gets the configuration for the network service that provides network reference stations. The network service should use NTRIP(Networked Transport of RTCM via Internet Protocol).

      Return:
      NetworkServiceSettingsAn instance of NetworkServiceSettings.
      Start Network Service
      method
      method startNetworkService
      void startNetworkService(@Nullable final CommonCallbacks.CompletionCallback callback)
      Package:dji.sdk.network
      Description:

      Starts the network service as the reference station. This should be called after setting the network service (setCustomNetworkSettings).

      Input Parameters:
      @Nullable final CommonCallbacks.CompletionCallback callbackThe completion block that receives the result.
      Stop Network Service
      method
      method stopNetworkService
      void stopNetworkService(@NonNull final CommonCallbacks.CompletionCallback callback)
      Package:dji.sdk.network
      Description:

      Stops the network service.

      Input Parameters:
      @NonNull final CommonCallbacks.CompletionCallback callbackThe completion block that receives the result.
      Add Network Service State Listener
      method
      method addNetworkServiceStateCallback
      void addNetworkServiceStateCallback(@NonNull final NetworkServiceState.Callback callback)
      Package:dji.sdk.network
      Description:

      Adds a listener to receive the latest network service state.

      Input Parameters:
      @NonNull final NetworkServiceState.Callback callbackThe completion block that receives the result.
      Remove Network Service State Listener
      method
      method removeNetworkServiceStateCallback
      void removeNetworkServiceStateCallback(@NonNull final NetworkServiceState.Callback callback)
      Package:dji.sdk.network
      Description:

      Removes a listener that is added by passing to addNetworkServiceStateCallback.

      Input Parameters:
      @NonNull final NetworkServiceState.Callback callbackThe completion block that receives the result.
      Set Coordinate System
      method
      method setNetworkServiceCoordinateSystem
      void setNetworkServiceCoordinateSystem(CoordinateSystem coordinateSystem, @Nullable final CommonCallbacks.CompletionCallback callback)
      Package:dji.sdk.network
      Description:

      Sets coordinate system for rtk network service. Only can be used when current ReferenceStationSource is NETWORK_RTK.

      Input Parameters:
      CoordinateSystem coordinateSystemThe DJIRTK_DJIRTKNetworkServiceCoordinateSystem to set.
      @Nullable final CommonCallbacks.CompletionCallback callbackThe completion block that receives the result.
      Get Coordinate System
      method
      method getNetworkServiceCoordinateSystem
      void getNetworkServiceCoordinateSystem(@NonNull final CommonCallbacks.CompletionCallbackWith<CoordinateSystem> callback)
      Package:dji.sdk.network
      Description:

      Gets current network RTK coordinate system. Only can be used when current ReferenceStationSource is NETWORK_RTK.

      Input Parameters:
      @NonNull final CommonCallbacks.CompletionCallbackWith<CoordinateSystem> callbackThe execution callback with the returned value(s).
      Activate Network Service
      method
      method activateNetworkService
      void activateNetworkService(NetworkServicePlanType planType, @NonNull final CommonCallbacks.CompletionCallback callback)
      Package:dji.sdk.network
      Description:

      Activates network RTK activateNetworkService.

      Input Parameters:
      NetworkServicePlanType planTypePlan type to activate.
      @NonNull final CommonCallbacks.CompletionCallback callbackThe completion block that receives the result.
      method getNetworkServiceOrderPlans
      void getNetworkServiceOrderPlans(@NonNull final CommonCallbacks.CompletionCallbackWith<NetworkServicePlansState> callback)
      Package:dji.sdk.network
      Description:

      Gets network service plans.

      Input Parameters:
      @NonNull final CommonCallbacks.CompletionCallbackWith<NetworkServicePlansState> callbackThe completion block that receives the result.
      enum NetworkServiceChannelState
      enum NetworkServiceChannelState
      Package:dji.common.flightcontroller.rtk
      Description:

      All the possible state of NetworkServiceChannelState.

      Enum Members:
      DISABLEDThe network service is not started.
      NETWORK_NOT_REACHABLEThe network is not reachable from the mobile device.
      AIRCRAFT_DISCONNECTEDThe aircraft is not connected.
      LOGIN_FAILURESDK cannot login with the provided username and password. Check getError.
      TRANSMITTINGData is transmitting through the channel.
      DISCONNECTEDThe channel is disconnected and the server is not reachable now. Check getError.
      ACCOUNT_ERRORUser account error. Check getError.
      SERVER_NOT_REACHABLEUnable to connect to server.
      CONNECTINGConnecting to server.
      SERVICE_SUSPENSIONThe account for network RTK plan A has been expired, please activate plan B.
      INVALID_REQUESTThe invalid request is rejected by the server.
      UNKNOWNUnknown.
      Class Members: