Sport Mode (Copter)
Executive Summary
Sport Mode offers a unique control scheme: Earth-Frame Rate Control. Like Acro, the sticks command angular rotation rates (deg/s) instead of angles. However, unlike Acro, these rates are relative to the Earth's Horizon, not the vehicle's body.
Theory & Concepts
1. Earth Frame Rates (Rate Isolation)
The defining feature of Sport Mode is that it decouples the drone's tilt from its rotation.
- Acro (Body Frame): If you are nose-down and you yaw, the drone rolls.
- Sport (Earth Frame): If you are nose-down and you yaw, the drone just spins its nose while staying nose-down. The autopilot handles the complex motor mixing to keep the pitch/roll constant relative to the horizon, not the drone.
2. The Attitude Leash
Think of Sport mode as "Rate mode with a leash." You have the freedom to rotate as fast as you want, but the autopilot holds onto a leash (ANGLE_MAX). Once you hit that limit, the autopilot "yanks" the leash to prevent the drone from flipping over, even though you are in a rate-control mode.
Hardware Dependency Matrix
Sport Mode is robust and requires minimal sensors.
| Sensor | Requirement | Code Implementation Notes |
|---|---|---|
| Gyroscope | CRITICAL | Required for the rate controller. |
| Accelerometer | CRITICAL | Required to estimate the Earth-Frame (Horizon). Without an accurate level estimate, the controller cannot decouple Body-Roll from Earth-Roll. |
| Compass | OPTIONAL | Helpful for maintaining heading drift, but not strictly required for the core stabilization. |
| GPS | NONE | Not used. |
Control Architecture (Engineer's View)
Sport Mode sits between Stabilize and Acro.
- Stick to Earth-Rate:
- Pilot inputs are converted to target rates (deg/s).
- The code uses
input_euler_rate_roll_pitch_yaw(). - Transformation: The controller calculates the necessary Body Rates (p, q, r) to achieve the requested Euler Rates (dRoll/dt, dPitch/dt).
- Angle Limiting (The Leash):
- Unlike Acro, Sport mode respects
ANGLE_MAX. - Mechanism: It continuously predicts where the vehicle will be. If the predicted angle exceeds
ANGLE_MAX, it overrides the pilot's rate command to "push" the vehicle back. This feels like hitting a soft wall.
- Unlike Acro, Sport mode respects
- Self-Leveling (Virtual Flybar):
- When sticks are centered, the vehicle slowly returns to level (controlled by
ACRO_BAL_ROLL/ACRO_BAL_PITCH). This makes it safer than Acro for FPV beginners.
- When sticks are centered, the vehicle slowly returns to level (controlled by
Pilot Interaction
- Turning: You can bank the aircraft and pull back on the pitch stick to turn, similar to a plane or Acro mode.
- Protection: You can hold full stick, and the drone will pitch/roll aggressively but never flip over (it stops at
ANGLE_MAX). - Throttle: Standard AltHold logic (Climb Rate).
Failsafe Logic
- Crash Check: Standard crash detection.
- Attitude Loss: If the AHRS (Accelerometer) fails or the EKF tumbles, Sport mode becomes disoriented because "Down" is unknown.
Key Parameters
| Parameter | Default | Description |
|---|---|---|
ACRO_RP_RATE |
360 | (deg/s) Max rotation rate. Shared with Acro. |
ANGLE_MAX |
4500 | (centi-deg) The hard limit for bank/pitch angles. |
ACRO_BAL_ROLL |
1.0 | Strength of self-leveling when sticks are centered. |
Source Code Reference
- Mode Logic:
ardupilot/ArduCopter/mode_sport.cpp - Rate Loop:
ModeSport::run()