MAVLINKHUD

Overview

The YAW parameter group handles configuration for the Heading (Yaw) Axis across various vehicle types.

Key Concepts

1. Heading Maintenance

Yaw is critical for ensuring the vehicle's nose is pointed correctly for navigation, sensors (cameras/Lidar), or aerodynamics.

  • YAW_BEHAVE: Defines how the nose behaves during mission flight (Face next WP, Face Home, etc.).

2. PID Tuning (YAW_RATE_P/I/D)

(If present in group) Standard gains to control the responsiveness of the yaw rotation.

Developer Notes

  • Library: libraries/AC_AttitudeControl.
  • See Also: ATC for more details on rate PID loops.

YAW2SRV_DAMP

Default 0
Range 0 2.0

Yaw Damping (YAW2SRV_DAMP)

Description

YAW2SRV_DAMP is the "Anti-Wag" gain for planes.

When a plane hits a gust of wind, the tail often "Fishtails" back and forth. This gain uses the gyro to detect that horizontal motion and applies counter-rudder to stop it instantly. This is the most important parameter for a stable, professional-feeling flight on fixed-wing aircraft.

  • Higher Value: Stiffer, more damped tail.
  • Too High: The rudder will chatter or vibrate.

YAW2SRV_IMAX

cdeg
Default 1500
Range 0 4500

Yaw Integrator Limit (YAW2SRV_IMAX)

Description

YAW2SRV_IMAX prevents the automatic rudder trim from taking over the entire plane.

It limits how many degrees of deflection the YAW2SRV_INT term can command. If your plane is badly out of alignment, the integrator could theoretically "Walk" the rudder all the way to its mechanical limit. This safety cap ensures you always have visual control remaining.

  • Default: 1500 (1/3rd of the total rudder travel).

YAW2SRV_INT

Default 0
Range 0 2.0

Sideslip Control Integrator (YAW2SRV_INT)

Description

YAW2SRV_INT acts like a "Self-Trimming Rudder."

If your plane naturally pulls to one side because of motor torque or a warped tail, the I-term learns the required offset to keep the flight perfectly coordinated without any pilot input.

YAW2SRV_RLL

Default 1.0
Range 0.8 1.2

Yaw Coordination Gain (YAW2SRV_RLL)

Description

YAW2SRV_RLL is the "Turn Finisher."

Once a turn is established, this gain fine-tunes the rudder to ensure the plane's tail is perfectly tracking its nose. If the plane tends to skid (tail out) or slip (tail in) during a steady circle, this value is adjusted to fix it.

  • 1.0 (Default): Physics-based calculation.
  • Values > 1.0: Increase yaw into the turn.
  • Values < 1.0: Decrease yaw into the turn.

YAW2SRV_SLIP

Default 0
Range 0 4.0

Sideslip Control Gain (YAW2SRV_SLIP)

Description

YAW2SRV_SLIP helps a plane fly "Straight" through the air during turns.

For aircraft with a significant vertical tail or fuselage area, a sideslip causes lateral (sideways) acceleration. This parameter uses the accelerometer to detect that sideways force and automatically applies rudder to cancel it out, ensuring the plane's nose is always pointing exactly where it is going.

  • Higher Value: More aggressive rudder correction to keep the ball centered.
  • 0: Disabled.

Tuning & Behavior

  • Default Value: 0.
  • Recommendation: Only tune this after YAW2SRV_DAMP is set. Do not use on flying wings or gliders without a large vertical tail.

YAW_BEHAVE

Default 1
Range 0 3

Follow Yaw Behavior (YAW_BEHAVE)

Description

YAW_BEHAVE defines what the drone points its "Face" (camera) at while it is chasing a target.

  • 0: None. The drone keeps its current heading and does not automatically rotate.
  • 1: Face Target (Default). The drone always turns to point its nose directly at the person or object it is following. Good for filming yourself.
  • 2: Face Next Waypoint.
  • 3: Face Direction of Travel. The drone points its nose where it is going, like a real airplane.

Tuning & Behavior

  • Default Value: 1.
  • Use Case: If you are using "Follow Me" to film a mountain biker from the side, you want Mode 1 so the camera stays locked on the subject.

YAW_CORR

Default 0.1
Range 0 1.0

Yaw Correction Gain (YAW_CORR)

Description

YAW_CORR defines how much the autopilot trusts the compass or GPS heading compared to its internal motion sensors (IMU).

Over time, the IMU "Drifts" and loses track of true North. The autopilot uses the compass (or GPS ground track) to "Pull" the IMU back into alignment.

  • Higher Value: Faster alignment to the compass, but more susceptible to compass glitches (e.g. flying near large metal structures).
  • Lower Value: Smoother heading, but more prone to long-term drift.

YAW_MAX

deg
Default 180
Range -180 180

Mount Yaw angle maximum

Note: This parameter configures instance MAX. It functions identically to MNT1_YAW_MAX.

YAW_MIN

deg
Default -180
Range -180 180

Mount Yaw angle minimum

Note: This parameter configures instance MIN. It functions identically to MNT1_YAW_MIN.

YAW_M_NSE

rad
Default 0.2f
Range 0.05 1.0

Visual odometry yaw measurement noise

Note: This parameter configures instance None. It functions identically to VISO_YAW_M_NSE.

YAW_RANGE

deg
Default 360
Range 0 360

Antenna Tracker Yaw Range (YAW_RANGE)

Description

YAW_RANGE defines the mechanical limits of the tracker's pan axis.

Antenna trackers often have slip-rings (allowing continuous 360 rotation) or cable limits. This parameter tells the software how far it can turn before it needs to stop or "unwind."

  • 360 (Default): Full rotation allowed (assuming slip ring).
  • 180: Limited rotation (e.g. +/- 90 degrees).

Tuning & Behavior

  • Safety: If you do not have a slip ring, setting this correctly is vital to prevent tearing your antenna cables.

YAW_RATE_D

Default 0
Range 0 0.05

Yaw Rate D Gain (YAW_RATE_D)

Description

YAW_RATE_D acts as a brake for horizontal rotation.

It is rarely needed for multirotors, as the drag of the propellers usually provides enough natural damping. However, on large drones with heavy batteries mounted far from the center, a small amount of D-gain can help stop the rotation more cleanly.

YAW_RATE_D_FF

null
Default 0
Range null

FF FeedForward Gain

Note: This parameter configures instance D_FF. It functions identically to RLL_RATE_D_FF.

YAW_RATE_ENABLE

Default 1
Range 0 1

Yaw Rate Controller Enable (YAW_RATE_ENABLE)

Description

YAW_RATE_ENABLE activates the yaw stabilization loop.

  • 1 (Default): The autopilot actively uses the motors (and rudder/tail) to hold the drone's heading.
  • 0: Yaw stabilization is disabled. The pilot has 100% manual control over yaw torque. (Highly unstable for multirotors!).

YAW_RATE_FF

Default 0
Range 0 0.5

Yaw Rate Feed-Forward (YAW_RATE_FF)

Description

YAW_RATE_FF gives the drone a "Head Start" on turning.

It injects a portion of your stick command directly into the motors, bypassing the PID calculation. This makes the drone feel more connected and less "mushy."

Tuning & Behavior

  • Default Value: 0.
  • Recommendation: Tune until the drone starts rotating exactly when you move the stick, without waiting for the error to build up.

YAW_RATE_FLTD

Hz
Default AC_PID_DFILT_HZ_DEFAULT
Range null

PID D term filter frequency in Hz

Note: This parameter configures instance FLTD. It functions identically to RLL_RATE_FLTD.

YAW_RATE_FLTE

Hz
Default AC_PID_EFILT_HZ_DEFAULT
Range null

PID Error filter frequency in Hz

Note: This parameter configures instance FLTE. It functions identically to RLL_RATE_FLTE.

YAW_RATE_FLTT

Hz
Default AC_PID_TFILT_HZ_DEFAULT
Range null

PID Target filter frequency in Hz

Note: This parameter configures instance FLTT. It functions identically to RLL_RATE_FLTT.

YAW_RATE_I

Default 0.02
Range 0 0.1

Yaw Rate I Gain (YAW_RATE_I)

Description

YAW_RATE_I ensures the drone stays pointed in the correct direction over long periods.

If the drone is constantly being pushed by a crosswind or has an imbalanced motor, the I-term builds up pressure to hold the nose exactly where it is supposed to be.

YAW_RATE_IMAX

Default 0.222
Range 0 1.0

Yaw Rate I Max (YAW_RATE_IMAX)

Description

YAW_RATE_IMAX limits how much power the "Memory" (I-Term) can use to fix a yaw error.

  • 0.222 (Default): The integrator can use up to 22.2% of the motor range.
  • 1.0: The integrator can use 100% of the motor range. (Dangerous!).

Tuning & Behavior

  • Safety: This prevents "Wind-Up." If you block the drone's rotation with your hand, the integrator would normally keep building up power to try and move it. IMAX caps that power so the drone doesn't explode when you let go.

YAW_RATE_P

Default 0.25
Range 0.1 0.5

Yaw Rate P Gain (YAW_RATE_P)

Description

YAW_RATE_P controls how aggressively the drone stops its horizontal rotation.

When you let go of the yaw stick, the drone should stop spinning and hold its new heading. If the drone is slow to stop or "Drifts" around, you need more P.

  • Too High: The tail will "Wag" or vibrate horizontally.
  • Too Low: The drone will be slow to respond to yaw commands and will not hold its heading well in the wind.

YAW_RATE_PDMX

null
Default 0
Range null

PD sum maximum

Note: This parameter configures instance PDMX. It functions identically to RLL_RATE_PDMX.

YAW_RATE_SMAX

null
Default 0
Range 0 200

Slew rate limit

Note: This parameter configures instance SMAX. It functions identically to RLL_RATE_SMAX.

YAW_SLEW_TIME

s
Default 2
Range 0 20

Yaw Slew Time (YAW_SLEW_TIME)

Description

YAW_SLEW_TIME acts as a speed governor for the Antenna Tracker's pan axis.

It forces the tracker to move smoothly between targets rather than snapping instantly. This reduces mechanical stress on the gears and prevents the heavy high-gain antenna from wobbling when it stops.

  • 0: Unlimited speed (Servo max speed).
  • 2 (Default): Takes at least 2 seconds to do a full rotation.

Tuning & Behavior

  • Recommendation: Increase this value if you have a heavy antenna array. Smoother movement is generally better for video link quality than jerky tracking.