VC.
ResearchHardware

Adaptive Backstepping — Indoor Micro-Quadrotor

Taming nonlinear quadrotor dynamics with adaptive backstepping control design.

Lyapunov

Stability Proof

vs PID

Benchmarked

University of Utah

Research Lab

Tech Stack

MATLAB/SimulinkBackstepping ControlLyapunov AnalysisNonlinear ControlC

The Challenge

A micro-quadrotor with a hanging payload creates a highly nonlinear, underactuated system where the pendulum dynamics couple into the rotational equations of motion. Standard PID controllers linearize around the hover equilibrium and perform poorly under large perturbations. The task was to design a controller that formally guarantees stability for the full nonlinear model, not just a linearized approximation.

Architecture & System Design

Adaptive Backstepping — Indoor Micro-Quadrotor system architecture

Nonlinear control design for quadrotor with suspended payload: adaptive controller handles model uncertainties. Stability proven mathematically using Lyapunov functions. Outperforms classical linear control under large perturbations.

Full system schematic available upon request

The system model was derived using Euler-Lagrange mechanics, capturing full coupling between the quadrotor body and the suspended payload. A backstepping control design recursively constructed a Lyapunov function for the cascaded subsystems, synthesizing virtual control inputs at each stage. Adaptive parameter estimation handled model uncertainties in the payload mass. Simulations in MATLAB/Simulink validated the closed-loop stability and compared step response, disturbance rejection, and tracking error against a baseline PID controller.

Code Walkthrough

3-step walk-through of the production implementation — file paths and intent shown above each block.

  1. Step 1 of 3

    Altitude subsystem — first backstepping step

    control/altitude_backstepping.m

    Backstepping designs controllers recursively for cascaded subsystems. A virtual control α₁ (desired vertical velocity) is constructed so the first Lyapunov candidate V₁ = ½e₁² is non-increasing, then the actual thrust u₁ is derived to make V₁ + ½e₂² also non-increasing. This guarantees asymptotic stability at each stage without linearising the quadrotor dynamics.

    matlab
    % altitude_backstepping.m — Step 1 of the recursive backstepping design.
    % z: altitude [m], dz: vertical velocity [m/s], u1: total thrust [N]
    
    function [u1, V1] = altitude_backstepping(z, dz, z_d, dz_d, m, g)
        e1     = z_d - z;
        alpha1 = dz_d + k1 * e1;   % virtual control: desired dz
        e2     = alpha1 - dz;       % step-2 error
    
        % Lyapunov candidate: V = 0.5*e1^2 + 0.5*e2^2
        V1 = 0.5 * e1^2 + 0.5 * e2^2;
    
        % Control law ensuring dV/dt = -k1*e1^2 - k2*e2^2 < 0
        u1 = m * (g + dz_d + k1*(dz_d - dz) + k2*e2 + e1);
    end
    Takeaway

    Each backstepping step adds one error term to V and one gain — the stability proof is built into the construction, so there is no separate stability analysis to run.

  2. Step 2 of 3

    Attitude subsystem — roll and pitch channels

    control/attitude_backstepping.m

    Roll and pitch use the same recursive argument as altitude. The coupled pendulum dynamics mean pitch errors feed into lateral drift, so gains k3–k6 must suppress pendulum-induced oscillations without over-driving the attitude actuators. Mirrored gain pairs make hardware tuning systematic: k3/k5 set tracking speed, k4/k6 set damping.

    matlab
    function [u2, u3] = attitude_backstepping(phi, dphi, theta, dtheta, ...
                                               phi_d, dphi_d, theta_d, dtheta_d, ...
                                               Ixx, Iyy, k3, k4, k5, k6)
    % Roll channel ---
    e_phi   = phi_d - phi;
    de_phi  = dphi_d - dphi;
    e2_phi  = (dphi_d + k3*e_phi) - dphi;
    u2      = Ixx * (dphi_d + k3*de_phi + k4*e2_phi + e_phi);
    
    % Pitch channel ---
    e_the   = theta_d - theta;
    de_the  = dtheta_d - dtheta;
    e2_the  = (dtheta_d + k5*e_the) - dtheta;
    u3      = Iyy * (dtheta_d + k5*de_the + k6*e2_the + e_the);
    end
    Takeaway

    Roll and pitch share the same controller template — swapping in different inertia constants (Ixx, Iyy) adapts it to a new airframe without restructuring the proof.

  3. Step 3 of 3

    Adaptive payload mass estimation

    control/adaptive_update.m

    The pendulum mass is unknown at runtime. An adaptive update law estimates it online from the altitude step-2 error and vertical velocity, so the controller compensates without prior knowledge. A projection operator clamps the estimate to physically realistic bounds, preventing noise-driven drift to negative values that would invert the thrust command.

    matlab
    function m_hat_new = adaptive_mass_update(m_hat, e2_alt, dz, gamma, dt)
    % Adaptive law: dm_hat/dt = -gamma * e2_alt * dz
    % Derived by augmenting the Lyapunov function with 0.5*(1/gamma)*m_tilde^2.
    
    M_MIN = 0.05;   % 50 g  — lightest expected payload
    M_MAX = 0.50;   % 500 g — heaviest expected payload
    
    dm_hat    = -gamma * e2_alt * dz;
    m_hat_new = min(max(m_hat + dm_hat * dt, M_MIN), M_MAX);
    end
    
    % Main loop (1 kHz) — called after altitude_backstepping each step:
    %   [u1, ~] = altitude_backstepping(z, dz, z_d, dz_d, m_hat, g);
    %   m_hat   = adaptive_mass_update(m_hat, e2_alt, dz, gamma, dt);
    Takeaway

    Without projection, noise in the dz measurement can push the mass estimate negative — the clamp is what keeps the thrust command from inverting mid-flight.

Results

The adaptive backstepping controller demonstrated superior performance vs. PID in all tested scenarios: 40% faster disturbance recovery, stable operation under ±30° pitch perturbations where PID became unstable, and formal asymptotic stability guaranteed by the Lyapunov construction. Results were documented in the University of Utah thesis report.

Gallery & Demos

Adaptive Backstepping — Indoor Micro-Quadrotor screenshot
Adaptive Backstepping — Indoor Micro-Quadrotor screenshot
Adaptive Backstepping — Indoor Micro-Quadrotor screenshot
Adaptive Backstepping — Indoor Micro-Quadrotor screenshot
Adaptive Backstepping — Indoor Micro-Quadrotor screenshot

Click any image or video to expand · ← → keys navigate

University of Utah

More from University of Utah

Vision-Based Autonomous Quadrotor

Researcher

MS thesis project: a quadrotor capable of autonomously taking off, navigating, and perching on branch-like structures using only visual feedback — designed for autonomous crop monitoring in agricultural fields.

OpenCVPID ControlROS

Multi-Arm Coordination — 2-DOF QUANSER

Researcher

Dual-arm robotic manipulation system using 2-DOF QUANSER robots with a master-slave architecture — one arm controlling position, the other controlling force — to collaboratively manipulate objects with precision.

MATLAB/SimulinkQUARCImpedance Control

Sensor-Based SLAM Navigation — iRobot Create

Researcher

Autonomous mapping and navigation system on an iRobot Create platform using IR rangefinders and servo-mounted sensors for 360° SLAM — with RRT path planning to navigate complex maze environments.

MATLABiRobot CreateRRT Path Planning

PUMA 6-DOF Robot Arm — Forward & Inverse Kinematics

Researcher

Full forward and inverse kinematics solver for a 6-DOF PUMA 762 robot arm, built from scratch using Denavit-Hartenberg parameters — with an interactive 3D MATLAB GUI featuring joint sliders, motion trail, and collision detection.

MATLABDenavit-HartenbergRobotics Toolbox

Sampling-Based & Graph-Search Motion Planning

Researcher

MATLAB implementations of four canonical path-planning algorithms — Dijkstra, A*, PRM, and RRT — applied to a differential-drive robot navigating bitmap maps in configuration space, with real hardware execution on an iRobot Create.

MATLABRRTPRM

Monocular Depth Estimation for UAV Perch Landing

Researcher

C++/OpenCV vision system that estimates the 3D position and orientation of a landing perch from a single monocular camera — using image moments, covariance eigendecomposition for attitude, and focal-length triangulation for depth — enabling closed-loop visual servoing on a quadrotor.

C++OpenCVHSV Segmentation

RC Fixed-Wing Glider — Servo Actuation & Aerodynamics

Researcher

Fixed-wing RC glider designed and built from scratch — two servos providing roll and pitch authority via aileron and flap control surfaces, with a brushless DC motor and ESC delivering forward thrust. Flight-tested outdoors.

Servo ControlBrushless DC MotorESC

Interested in this work?

Full architecture walkthrough and code review available during interviews.