Copter Mission Command List

This page provides details of all the mission commands (i.e. MAVLink commands) supported by Copter that can be run as part of a mission (i.e. AUTO flight mode).

Each of the commands below is either a “Navigation” command or a “Do” command. Navigation commands (i.e. “TakeOff” and “Waypoint”) affect the location of the vehicle while “Do” commands (i.e. “Do-Set-Servo” and “Do-Cam-Trigg-Dist”) are for auxiliary functions and do not affect the vehicle’s position. During a mission at most one “Navigation” command and one “Do” command can be running at one time. The “Do” commands will be run in order as soon as the preceeding navigation command before them starts. For more information on setting up missions please refer to the Planning a Mission with Waypoints and Events page.

Takeoff

../_images/TakeOff.jpg

The vehicle will climb straight up from it’s current location to the altitude specified (in meters). This should be the first command of nearly all missions. If the mission is begun while the copter is already flying, the vehicle will climb straight up to the specified altitude, if the vehicle is already above the specified altitude the takeoff command will be ignored and the mission will move onto the next command immediately.

Waypoint

../_images/WayPoint.jpg

The vehicle will fly a straight line to the location specified as a lat, lon and altitude (in meters).

Delay - the amount of time to wait (in seconds) at the waypoint before proceeding to the next command

Hit Rad - not supported - meant to hold the distance (in meters) from the target point that will qualify the waypoint as complete. This command is not supported. Instead the WPNAV_RADIUS parameter should be used (see “WP Radius” field in above screen shot or adjust through the Standard Parameters List). Even the WPNAV_RADIUS is only used when the waypoint has a Delay. With no delay specified the waypoint will be considered complete when the virtual point that the vehicle is chasing reaches the waypoint. This can be 10m (or more) ahead of the vehicle meaning that the vehicle will turn towards the following waypoint long before it actually reaches the current waypoint

Yaw Ang - not supported - meant to hold the resulting yaw angle in degrees (0=north, 90 = east). Instead use a CONDITION_YAW command.

Lat, Lon - the latitude and longitude targets. If left as zero it will hold the current location.

Alt - the target altitude above home in meters. If left as zero it will hold the current altitude.

Spline Waypoint

../_images/MissionList_SplineWaypoint.jpg

From AC3.2 (and higher), Spline waypoints are supported. The Spline commands take all the same arguments are regular waypoints (lat, lon, alt, delay) but when executed the vehicle will fly smooth paths (both vertically and horizontally) instead of straight lines. Spline waypoints can be mixed with regular straight line waypoints as shown in the image above.

The Mission Planner shows the path the vehicle will take. The image above shows some characteristics of the spline

  • The 1 second delay at the end of Waypoint #1 causes the vehicle to stop so Spline command #2 begins by taking a sharp 90degree turn
  • The direction of travel as the vehicle passes through Spline Waypoint #3 is parallel to an imaginary line drawn between waypoints #2 and #4
  • Waypoint #5 is a straight line so the vehicle lines itself up to point towards waypoint #5 even before reaching waypoint #4.

Note

As of AC3.2-rc4, there is a slight twitch as the vehicle passes through each spline waypoint. This is a technical issue that we hope to resolve in an upcoming release.

Loiter_Time

../_images/MissionList_LoiterTime.png

The vehicle will fly to and then wait at the specified location for the specified number of seconds. This is the mission equivalent of the Loiter flight mode.

Times - the number of seconds to remain at the location.

Lat, Lon - the latitude and longitude targets. If left as zero it will hold at the current location.

Alt - the target altitude above home in meters. If left as zero it will hold at the current altitude.

Loiter_Turns

../_images/MissionList_LoiterTurns.png

The mission equivalent of the Circle flight mode. The vehicle will fly a circle around the specified lat, lon and altitude (in meters). The radius of the circle is controlled by the CIRCLE_RADIUS parameter (i.e. cannot be set as part of the mission).

Turn - the number of full rotations to complete around the point.

Dir 1=CW - the direction to turn around the point. -1 = counter clockwise, +1 = clockwise.

Lat, Lon - the latitude and longitude targets. If left as zero it will circle around the current location.

Alt - the target altitude above home in meters. If left as zero it will circle at the current altitude.

Loiter_Unlimited

../_images/MissionList_LoiterUnlimited.png

The vehicle will fly to and then wait at the specified location indefinitely. The mission will not proceed past this command.

Lat, Lon - the latitude and longitude targets. If left as zero it will wait at the current location.

Alt - the target altitude above home in meters. If left as zero it will wait at the current altitude.

Return-To-Launch

../_images/MissionList_RTL.png

Mission equivalent of the RTL flight mode. As described on the RTL flight mode wiki page, the vehicle will first climb to the RTL_ALT parameter’s specified altitude (default is 15m) before returning home. The home location is where the vehicle was last armed.

This command takes no parameters and generally should be the last command in the mission.

Land

../_images/MissionList_Land.png

Vehicle will land at it’s current location or at the lat/lon coordinates provided. This is the mission equivalent of the LAND flight mode.

Lat, Lon - the latitude and longitude targets. If left as zero it will land at the current location.

Do-Set-ROI

../_images/MissionList_DoSetRoi.jpg

Points the nose of the vehicle and camera gimbal at the “region of interest”. In the example above the nose and camera would be pointed at the red marker.

If using AC3.1.5: The nose would point at the marker for only the period that the vehicle is flying from Waypoint #1 to Waypoint #3. If you wanted the nose/camera to continue to point at the red marker as it flies from #3 to #4, a second DO_SET_ROI command would need to be entered after Waypoint #3.

If using AC3.2: The nose would continue to point at the red marker until the end of the mission. To “clear” the do-set-roi and cause the vehicle to return to it’s default behaviour (i.e. pointing at the next waypoint) a second DO_SET_ROI command should be placed later in the mission with all zero for Lat, Lon and Alt.

Lat, Lon - the latitude and longitude targets.

Alt - the target altitude above home in meters.

Condition-Delay

../_images/MissionList_ConditionDelay.png

Delays the start of the next “Do” command for the specified number of seconds. In the example above, Command #4 (Do-Set-Roi) is delayed so that it only starts 5 seconds after the vehicle has passed Waypoint #2. Note: this command does not stop the vehicle. Also note that the delay timer is only active until the next waypoint is reached, so if the “Do” command hasn’t been triggered by then it never will be.

Time (sec) - the time to delay the next “Do” command in seconds.

Condition-Distance

../_images/MissionList_ConditionDistance.png

Delays the start of the next “Do” command until the vehicle is within the specified number of meters of the next waypoint. In the example above, Command #4 (Do-Set-Roi) is delayed so that it only starts once the vehicle is within 50m of waypoint #5. Note: this command does not cause the vehicle to stop or pause during the mission, it only affects “Do” commands.

Dist (m) - how close the vehicle should be to the next waypoint (in meters) before beginning the next “Do” command.

Condition-Yaw

../_images/MissionList_ConditionYaw.png

Point the nose of the vehicle to the specified heading by a specified amount.

Deg - the desired heading in degrees (0 = North, 90 = East, etc) when “rel/abs” field is “0” (meaning absolute)

OR the change in heading (in degrees) when “rel/abs” field is “1” (meaning relative)

Sec - not supported. meant to limit the rotation speed (in deg/sec) as the vehicle turns to the desired heading

Dir (1=CW, -1=CCW) - Used only when relative heading is specified (i.e. “rel/abs” = “1”) denotes whether the flight controller should add (CW) or subtract (CCW) the degrees (Deg) from the current heading to calculate the target heading. The vehicle will always turn in direction that most quickly gets it to the new target heading regardless if CW or CCW are used.

rel/abs - allows specifying the heading (i.e “Deg” field) as an absolute heading (if “0”) or relative to the current heading (if “1”)

Do-Jump

../_images/MissionList_DoJump.png

Jump to the specified mission command the specified number of times before continuing with the mission. In the example above the vehicle would fly back-and-forth between waypoints #1 and #2 a total of 3 times before flying on to waypoint #4.

WP # - the mission command to jump to.

Repeat - the maximum number of times we should perform the jump. -1 means always jump

Despite the name, Do-Jump is really a “Nav” command rather than a “Do” command, so conditional commands like CONDITION_DELAY won’t affect Do-Jump, it will always perform the jump as soon as it hits that command.

Warning

No more that three (3) Do-Jump commands can be used in a mission, the fourth and subsequent Do-Jumps will be ignored.

Warning

This command should not be used with ArduCotper 3.1.5 or earlier (it works properly in AC3.2).

Do-Change-Speed

../_images/MissionList_DoChangeSpeed.png

Change the target horizontal speed (in meters/sec) of the vehicle.

speed m/s - the desired maximum speed in meters/second.

Note

In AC3.1.5 (and earlier) versions the speed change will only take effect after the current navigation command (i.e. waypoint command) completes. From AC3.2 onwards the vehicle speed will change immediately. Also note that in AC3.2 the speed parameter will be in the SECOND COLUMN, not the first column as in previous releases as shown in the screenshot above (this is to match the official MAVLINK protocol)

Do-Set-Home

../_images/MissionList_DoSetHome.png

This command should not be used because of an issue found in AC3.2. Instead Rally Points can be used to control the position used for Return-To-Launch (“Home” is also used internally as the “origin” for all navigation calculations).

Current(1)/Spec(0) - if “1” use the current location as the new home, if “0” use the specified Lat and Lon coordinate (not labelled yet!)

Lat, Lon - the latitude and longitude targets.

Do-Set-Cam-Trigg-Dist

../_images/MissionList_DoSetCamTriggDist.png

Trigger the camera shutter at regular distance intervals. For example the command above will cause the camera shutter to trigger after every 5m that the vehicle travels.

Dist (m) - distance interval in meters.

Note: In AC3.1.5 (and earlier) versions this command cannot be shut-off. The camera will continue to be triggered repeatedly even after the mission has been ended. In AC3.2 (and higher) providing a distance of zero will stop the camera shutter from being triggered

Do-Set-Relay

../_images/MissionList_DoSetRelay.png

Set a Relay pin’s voltage high or low. The columns are mislabeled in the Mission Planner (issue here).

First column is Relay number : 0 = First Relay, 1 = Second Relay

Second column is On/Off : 0 = Off (i.e. 0V), 1 = On (i.e. 3.3V on Pixhawk, 5V on APM)

Do-Repeat-Relay

../_images/MissionList_DoRepeatRelay.png

Toggle the Relay pin’s voltage a specified number of times. In the example above, assuming the relay was off to begin with, it would be set high and then after 3 seconds it would be toggled low again.

First column is Relay number : 0 = First Relay, 1 = Second Relay

Repeat # : how many times the relay should be toggled

Delay(s) - Number of seconds between each toggle.

Do-Set-Servo

../_images/MissionList_DoSetServo.png

Move a servo to a particular PWM value. In the example above, the servo attached to output channel 8 would be moved to PWM 1700 (servo’s generally accept PWM values between 1000 and 2000).

Ser No : the output channel the servo is attached to

PWM : PWM value to output to the servo

Do-Repeat-Servo

../_images/MissionList_DoRepeatServo.png

Repeatedly move a servo back and forth between it’s mid position and a specified PWM value. In the example above, the servo attached to output channel 8 would be moved to PWM 1700, then after 4 second, back to mid (default is 1500 which is held in the RC8_TRIM parameter), after another 4 seconds it would be moved to 1700 again, then finally after 4 more seconds it would be moved back to mid.

Ser No : the output channel the servo is attached to

PWM : PWM value to output to the servo

Repeat # : Number of times to move the servo to the specified PWM value

Delay (s) : the delay in seconds between each servo movement

Do-Digicam-Control

../_images/MissionList_DoDigicamControl.png

Trigger the camera shutter once. This command takes no additional arguments.

Do-Mount-Control

../_images/MissionList_DoMountControl.png

From AC3.3 This command allows you to specify a roll, pitch and yaw angle which will be sent to the camera gimbal. This can be used to point the camera in specific directions at various times in the mission.