ProductConnectivityChanged (Connected As Boolean) BatteryState (Battery As Object, RemainingPercentage As Int) Result (Success As Boolean, ErrorMessage As String) ResultWithValue (Success As Boolean, ErrorMessage As String, Value As Object)
Gets the aircraft name. The ResultWithValue event will be raised. Returns an object that can be used as the sender filter parameter. Example: Waitfor (aircraft.GetName) Aircraft_ResultWithValue (SuccessAsBoolean, ErrorMessageAsString, ValueAsObject)
IfSuccessThen aircraftName = Value EndIf
Initializes the object. EventName - Sets the subs that will handle the events. AircraftData - The parameter passed to DJISDKManager ProductChanged event.
IMUStateChanged (State As DJIIMUState) Result (Success As Boolean, ErrorMessage As String) ResultWithValue (Success As Boolean, ErrorMessage As String, Value As Object)
Gets the LEDs status. The ResultWithValue event will be raised. Returns an object that can be used as the sender filter parameter. Example: WaitFor(controller.GetLEDsEnabled) Controller_ResultWithValue (SuccessAsBoolean, ErrorMessageAsString, ValueAsObject)
IfSuccessThen Log($"LED status: " ${Value}"$)
EndIf
GoHomeCancelAsObject
Cancels a go home action. The Result event will be raised.
GoHomeStartAsObject
Starts a go home action. The Result event will be raised.
Sets the home location based on the current aircraft location. The Result event will be raised. Example: DimsfAsObject = controller.SetHomeLocationUsingAircraftCurrentLocation WaitFor (sf) Controller_Result (SuccessAsBoolean, ErrorMessageAsString)
IfSuccessThen Log("Home location set.")
Else Log("Error: " & ErrorMessage)
EndIf
SetLEDsEnabled (EnabledAsBoolean) AsObject
Sets the LEDS status. The Result event will be raised. Returns an object that can be used as the sender filter parameter. Example: WaitFor (controller.SetLEDsEnabled(True)) Controller_Result (SuccessAsBoolean, ErrorMessageAsString)
Log($"LED state changed. Success = ${Success}"$)
SimulatorStartedAsBoolean [read only]
Returns true if the simulator has started.
TagAsObject
TakeOffAsObject
Starts a takeoff action. The engine will start automatically. The Result event will be raised. Returns an object that can be used as the sender filter parameter.
Returns one of the following values: UNKNOWN, DISCONNECTED, CALIBRATING, CALIBRATION_FAILED, DATA_EXCEPTION, WARMING_UP, IN_MOTION, NORMAL_BIAS, MEDIUM_BIAS, LARGE_BIAS.
CalibrationStatusAsString [read only]
Returns one of the following values: NONE, CALIBRATING, SUCCESSFUL, FAILED, UNKNOWN.
GyroscopeStateAsString [read only]
Returns one of the following values: UNKNOWN, DISCONNECTED, CALIBRATING, CALIBRATION_FAILED, DATA_EXCEPTION, WARMING_UP, IN_MOTION, NORMAL_BIAS, MEDIUM_BIAS, LARGE_BIAS.
RegisteredResult (Success As Boolean, ErrorMessage As String) ActivationStateChanged (State As String) ProductChanged (AircraftData As Object) ProductConnectivityChanged (Connected As Boolean) ComponentConnectivityChanged (Connected As Boolean) ProductName (Success As Boolean, Name As String)
Returns the activation state. One of the following values: NOT_SUPPORTED, LOGIN_REQUIRED, ACTIVATED, UNKNOWN Returns an empty string if the SDK was not registered.
AircraftBindingStateAsString [read only]
Returns the aircraft binding state. One of the following values: NOT_SUPPORTED, INITIAL, BOUND, NOT_REQUIRED, UNBOUND , UNBOUND_BUT_CANNOT_SYNC, UNKNOWN Returns an empty string if the SDK was not registered.
Initialize (EventNameAsString)
Initializes the DJI SDK. The RegisteredResult event will be raised. Note that an internet connection is required on the first run.
IsInitializedAsBoolean
RegisteredAsBoolean [read only]
StartConnectionToProduct
Tries to connect to the product. The ProductChanged event will be raised.
Adds an action that will be executed when the aircraft reaches the point. Action - One of the following values: STAY - Stays at the current point. Parameter = Period in milliseconds. START_TAKE_PHOTO - Starts to shoot a photo. Parameter is ignored. START_RECORD - Starts recordsing. Parameter is ignored. STOP_RECORD - Stops recording. Parameter is ignored. ROTATE_AIRCRAFT - Rotates the aircraft's yaw. Parameter should be between -180 to 180. GIMBAL_PITCH - Rotates the gimbal's pitch. Parameter should be between -90 to 0.
Action that will be executed when the mission finishes. NO_ACTION - No further action will be taken on completion of mission. GO_HOME - The aircraft will go home and land. AUTO_LAND - The aircraft will land at the last waypoint. GO_FIRST_WAYPOINT - The aircraft will go to the first waypoint. CONTINUE_UNTIL_END - Mission will not end until StopMission is called.
MissionProgress (ExecutionEvent As Object, TargetWaypointIndex As Int) MissionStart MissionFinish (Error As String) Result (Success As Boolean, ErrorMessage As String) ResultWithValue (Success As Boolean, ErrorMessage As String, Value As Object)
Loads a mission. The next step is to upload it with UploadMission.
MissionStateAsString [read only]
Returns the mission state. One of the following values: UNKNOWN, DISCONNECTED, NOT_SUPPORTED, RECOVERING, READY_TO_UPLOAD, UPLOADING, READY_TO_EXECUTE, EXECUTING, EXECUTION_PAUSED.
PauseMissionAsObject
Pauses a mission. The Result event will be raised.
ResumeMissionAsObject
Resumes a mission. The Result event will be raised.
StartMissionAsObject
Starts a mission. The Result event will be raised.
StopMissionAsObject
Stops a mission. The Result event will be raised.
TagAsObject
UploadMissionAsObject
Uploads a mission. The Result event will be raised.
Top