Parrot Minidrone Control Competition

MathWorks MATLAB control competition implementing advanced flight control algorithms, vision-based landing detection, and trajectory tracking for a Parrot Minidrone. Project combines system identification, control design, and computer vision for autonomous drone operation.

Parrot Minidrone Control Competition

Overview

MathWorks MATLAB control competition implementing advanced flight control algorithms, vision-based landing detection, and trajectory tracking for a Parrot Minidrone. Project combines system identification, control design, and computer vision for autonomous drone operation.

Project Overview

The Parrot Minidrone Control Competition was a MathWorks MATLAB-based control engineering challenge completed in August 2021 at the Universidad Nacional de Colombia. The project required designing and implementing an advanced control system for autonomous flight of a Parrot Minidrone, including trajectory tracking, vision-based landing detection, and robust flight stabilization.

The competition emphasized practical control theory application, combining classical control design with modern techniques for multi-axis drone flight control and computer vision integration.

Key Objectives

  1. Flight Control Design: Develop robust controllers for stable flight in all three axes (X, Y, Z)
  2. System Identification: Characterize drone dynamics through experimental testing and MATLAB identification tools
  3. Vision-based Landing: Implement image processing pipeline for autonomous landing pad detection and approach
  4. Trajectory Tracking: Execute complex reference trajectories with high accuracy and minimal overshoot
  5. Real-time Implementation: Deploy control algorithms in Simulink with real-time performance constraints

System Architecture

Hardware Platform

Drone: Parrot Minidrone (Mambo or Rolling Spider variant)

  • Lightweight quadcopter platform (~50g)
  • Built-in stabilization and attitude control
  • WiFi communication for command and telemetry
  • On-board camera for vision-based operations

Communication: WiFi link for real-time command transmission and sensor data acquisition

Control Architecture

Vision Processing → Landing Pad Detection
                    ↓
              Landing Controller
                    ↓
        ┌─────────────────────────────────┐
        ↓                                   ↓
  Flight Controller               Yaw Controller
  (X-Y Position)                (Heading/Rotation)
        ↓                                   ↓
   Desired Thrust              Desired Rotation Rate
        ↓                                   ↓
     Motor Commands ← ────────────────────→

Vision System

Objective: Detect and localize landing pads for autonomous landing operations

Pipeline:

  1. Image Acquisition: Real-time video stream from drone camera
  2. Color Segmentation: Isolate landing pad color signature
  3. Geometric Analysis: Detect landing pad boundaries and calculate offset
  4. Position Estimation: Determine relative position and orientation of landing target
  5. Control Input: Generate corrective commands to align with landing pad

Implementation: MATLAB Image Processing Toolbox with optimized segmentation algorithms

Control System Design

Flight Controller (X-Y Axis)

The position controller implements a cascaded control architecture:

Reference Position (X_ref, Y_ref)
           ↓
    Position Error
           ↓
    PID Position Controller → Desired Velocity
           ↓
    Velocity Error
           ↓
    PID Velocity Controller → Desired Tilt Angle
           ↓
    Rate Controller → Motor Commands

Control Parameters:

  • Position loop: Moderate bandwidth for trajectory tracking
  • Velocity loop: High bandwidth for responsive tracking
  • Rate loop: Very high bandwidth for stabilization

Yaw Controller (Z-axis Rotation)

Independent heading control with:

  • Reference yaw angle from vision system or manual commands
  • Rate-based control for smooth rotation
  • Anti-windup mechanisms for integral terms

Landing Controller

Specialized subsystem for autonomous landing approach:

  1. Detection Phase: Identify landing pad in camera frame
  2. Alignment Phase: Move drone to center position above pad
  3. Descent Phase: Smooth vertical descent while maintaining horizontal alignment
  4. Safety: Automatic abort if landing pad tracking is lost

System Identification Results

Drone Dynamics Characterization

The Parrot Minidrone exhibits approximately first-order response characteristics in the altitude channel with:

  • Response time: ~200-300 ms
  • Minimal overshoot due to built-in stabilization
  • Steady-state error: <5% for step inputs

Position tracking demonstrates accurate response to reference commands with performance limited primarily by vision-based position estimation accuracy.

Performance Metrics

Metric Achievement
Position Accuracy ±10-15 cm in X-Y plane
Altitude Stability ±5-10 cm
Response Time ~0.5 s for position changes
Landing Success Rate >90% (vision-dependent conditions)
Flight Duration 8-12 minutes (typical competition time)
Control Update Rate 40-50 Hz

Technical Approach

Tools Used:

  • MATLAB for algorithm development and testing
  • Simulink for real-time control implementation
  • Image Processing Toolbox for vision algorithms
  • System Identification Toolbox for drone characterization
  • Real-Time Operating System (RTOS) deployment

Key Design Decisions

  1. Cascaded Control Loop: Enables independent tuning of position, velocity, and rate controllers
  2. Vision-based Sensing: Provides absolute position reference without drift (unlike odometry)
  3. Robust Stability: Handles camera latency (200-300 ms) through predictive control
  4. Modular Architecture: Separate controllers for flight, landing, and yaw enable easy testing and modification

Results and Validation

Trajectory Execution

Successfully demonstrated:

  • Square Pattern Navigation: Drone executed 2m × 2m square perimeter autonomously
  • Curved Path Following: Smooth tracking of complex reference trajectories
  • Vision-based Landing: Automatic detection and approach to landing pads
  • Multi-axis Coordination: Simultaneous X-Y position and Z altitude control

Performance Data

The flight performance visualization (see plots panel) shows:

  • X-Position: Accurate tracking of reference trajectory with minimal error accumulation
  • Y-Position: Smooth lateral control without oscillation
  • Z-Position: Stable altitude maintenance throughout mission

Competition Context

This project was completed as part of the MathWorks MATLAB Minidrone Competition at the Universidad Nacional de Colombia, a prestigious international control engineering challenge. The competition evaluated:

  • Control Design: Quality of algorithms and tuning
  • Robustness: Performance under varying conditions
  • Innovation: Novel approaches to vision integration or control methods
  • Implementation: Real-time performance and reliability

Key Innovation Areas

  1. Integrated Vision System: Combined with closed-loop flight control for autonomous landing
  2. Adaptive Control: Position reference adaptation based on visual feedback
  3. System Identification: Real-time characterization improving control performance
  4. Optimization: Minimized computational load for embedded platform

Technical Stack

  • Control Framework: MATLAB/Simulink
  • Programming Languages: MATLAB M-code, Simulink block diagrams
  • Image Processing: Color-based segmentation, geometric analysis
  • Communication: WiFi UDP protocol for command transmission
  • Real-time System: Simulink Real-Time deployment on drone controller

Future Enhancements

  1. ROS Integration: Port control algorithms to Robot Operating System for broader platform support
  2. Advanced Vision: Implement marker-based landing (AprilTags) for improved accuracy
  3. Swarm Control: Multi-drone coordination algorithms
  4. Extended Missions: Longer flight paths with intermediate waypoints and obstacle avoidance
  5. Sensor Fusion: IMU-camera fusion for improved localization in GPS-denied environments

Resources

Control Systems Robotics Computer Vision MATLAB/Simulink Autonomous Systems

Flight Performance & System Response

Schematics