In the waypoint mission, the aircraft will travel between waypoints, execute actions at waypoints, and adjust heading and altitude between waypoints. Waypoints are physical locations to which the aircraft will fly. Creating a series of waypoints, in effect, will program a flight route for the aircraft to follow. Actions can also be added to waypoints, which will be carried out when the aircraft reaches the waypoint. The aircraft travels between waypoints automatically at a base speed. However, the user can change the speed by using the pitch joystick. If the stick is pushed up, the speed will increase. If the stick is pushed down, the speed will slow down. The stick can be pushed down to stop the aircraft and further pushed to start making the aircraft travel back along the path it came. When the aircraft is travelling through waypoints in the reverse order, it will not execute waypoint actions at each waypoint. If the stick is released, the aircraft will again travel through the waypoints in the original order, and continue to execute waypoint actions (even if executed previously). If the aircraft is pulled back along the waypoint mission all the way to the first waypoint, then it will hover in place until the stick is released enough for it to again progress through the mission from start to finish.
Number of waypoints in the waypoint mission. Note there are some cases when the waypoint count will be different to the waypoint array length from waypoints. This is usually the case when the waypoint mission is still being downloaded from the aircraft and the mission object hasn't existed previously (e.g. when the mobile device is connected to an aircraft with a previously uploaded mission). In these cases, isComplete will return null.
While the aircraft is travelling between waypoints, you can offset its speed by using the throttle joystick on the remote controller. maxFlightSpeed is this offset when the joystick is pushed to maximum deflection. For example, If maxFlightSpeed is 10 m/s, then pushing the throttle joystick all the way up will add 10 m/s to the aircraft speed, while pushing down will subtract 10 m/s from the aircraft speed. If the remote controller stick is not at maximum deflection, then the offset speed will be interpolated between [0, maxFlightSpeed] with a resolution of 1000 steps. If the offset speed is negative, then the aircraft will fly backwards to previous waypoints. When it reaches the first waypoint, it will then hover in place until a positive speed is applied. maxFlightSpeed has a range of [2,15] m/s.
The base automatic speed of the aircraft as it moves between waypoints with range [-15, 15] m/s. The aircraft's actual speed is a combination of the base automatic speed, and the speed control given by the throttle joystick on the remote controller. If autoFlightSpeed > 0: Actual speed is autoFlightSpeed + Joystick Speed (with combined max of double maxFlightSpeed) If autoFlightSpeed = 0: Actual speed is controlled only by the remote controller joystick. If autoFlightSpeed < 0 and the aircraft is at the first waypoint, the aircraft will hover in place until the speed is made positive by the remote controller joystick.
Action the aircraft will take when the waypoint mission is complete.
Heading of the aircraft as it moves between waypoints. Default is AUTO.
The path the aircraft follows between waypoints. The aircraft can either fly directly between waypoints in a straight line, or turn near a waypoint in the curve where the waypoint location defines a part of the curve.
This enum will determine the goto point mode while the drone executes the flight.
Go to the waypoint safely. The aircraft will rise to the same altitude of the waypoint if the current altitude is lower then the waypoint altitude. It then goes to the waypoint coordinate from the current altitude, and proceeds to the altitude of the waypoint.
Go to the waypoint from the current aircraft point to the waypoint directly.
Aircraft has reached a waypoint, has rotated to the new heading and is now processing actions. This state will be called before the waypoint actions starts executing and will occur for each waypoint action.
Aircraft is at a waypoint and is executing an action.
Aircraft is at a waypoint and has finished executing the current waypoint action. This state occurs once for each waypoint action.
Loads a waypoint mission into the device memory. A mission can be loaded only when the WaypointMissionState is one of the following:READY_TO_UPLOAD or READY_TO_EXECUTE. Calling LoadMission when the current state is READY_TO_EXECUTE will change the state to READY_TO_UPLOAD.
Gets the currently loaded mission of the manager. There are two ways to load a mission. 1. A mission can be loaded by user through loadMission. 2. If the aircraft is already executing a waypoint mission when SDK is re-connected, the manager will download part of the mission's information from the aircraft and load it automatically. In that case, the loaded mission will only contain the summary of the executing mission but information for each waypoint is absent. User can call DownloadMission to get all the information for the loaded mission. The loadedMission will be reset to null when the execution of the loadedMission is stopped, finished or interrupted.
If app is restart and waypoint mission is executing,you need to download mission from aircraft. The operation will download information of each waypoint from aircraft and save it to GetLoadedMission. If a download operation is started, the manager will download the information of waypoints missing in GetLoadedMission one-by-one in ascending order. It can only be called when the GetCurrentState is one of the following: - EXECUTING - EXECUTE_PAUSED,The download progress will be notify by DownloadStateChanged .