RTK-GPS UWB Vision EKF

Multi-Sensor Fusion for Relative Localization and Autonomous Mid-Air Docking of Dual UAVs

Enabling robust relative localization and control between multiple UAVs by fusing RTK-GPS, UWB ranging, and vision-based pose estimation through an EKF framework

Project Overview

My ISEF project: Solving the challenge of autonomous aerial docking through multi-sensor fusion

I have developed a multi-sensor fusion system for robust relative localization and autonomous mid-air docking between two UAVs. My system fuses RTK-GPS, UWB ranging, and vision-based pose estimation through an EKF framework, enabling precise aerial docking, cooperative UAV formations, and operations in GPS-degraded environments. This is my original research project for the International Science and Engineering Fair (ISEF).

My System Architecture

Mother UAV (Base Station)

Acts as the docking platform with 4 UWB anchors and AprilTag markers

  • 4x UWB Anchors
  • AprilTag Markers
  • Steel Docking Plate
  • PX4 Flight Controller
  • Companion Computer (ESP32)

Child UAV (Docking Drone)

Performs autonomous approach and docking with sensors and electromagnet

  • UWB Tag Module
  • Vision Camera
  • Electromagnet
  • PX4 Flight Controller
  • Companion Computer (ESP32)

Multi-Sensor Fusion

Each sensor operates at different ranges and precision levels, enabling a seamless docking sequence

RTK-GPS

Range: Unlimited

Global Positioning System provides universal positioning with no distance limitations. Allows initial approach to the mother UAV's general vicinity.

~1m
Accuracy
Max Range

UWB System

Range: < 10m

Ultra-Wideband ranging measures direct distances to 4 UWB anchors on the mother UAV, providing 3D relative position estimation.

~10cm
Accuracy
10m
Max Range

Vision System

Range: ~0.5m

AprilTag-based visual pose estimation provides the highest precision alignment for final docking phase with millimeter-level accuracy.

~1cm
Accuracy
0.5m
Max Range

EKF Fusion

Real-time

Extended Kalman Filter fuses all sensor data into a continuous, stable state estimate, ensuring smooth transitions between sensor handover phases.

100Hz
Update Rate
Smooth

My Autonomous Docking Sequence

Multi-stage control logic I developed ensures safe and precise aerial docking

1

GPS Approach (Long Range)

My child UAV uses RTK-GPS to navigate to the general vicinity of the mother UAV (within ~10m). GPS provides coarse positioning without distance limitations.

2

UWB Alignment (Medium Range)

Within 10m range, my UWB system activates. The child UAV measures distances to 4 anchors on the mother UAV and computes relative 3D position with ~10cm accuracy, gradually aligning and approaching.

3

Vision Locking (Close Range)

Within 0.5m, my vision system identifies AprilTag markers on the mother UAV. Visual algorithms decode precise relative pose with ~1cm accuracy for final alignment.

4

Electromagnetic Docking

Once aligned, the child UAV's electromagnet activates and locks onto the steel docking plate of the mother UAV, completing the autonomous mid-air docking without human intervention.

Technical Challenges & Solutions

Overcoming real-world obstacles to achieve autonomous mid-air docking

Aerodynamic Disturbances

Wind gusts and rotor downwash from both UAVs create unpredictable aerodynamic disturbances during approach.

🛡️ Solution

  • Predictive Control: EKF anticipates wind patterns and compensates proactively
  • High-Rate Updates: 100Hz sensor fusion for rapid disturbance rejection
  • Damping Algorithms: PID tuning optimized for stable hovering
  • Downwash Avoidance: Approach vector accounts for rotor wake zones

Relative Position Drift

Sensor noise and integration errors cause relative position estimation to drift over time, making precise docking impossible.

🛡️ Solution

  • Multi-Stage Sensor Handover: Smooth transition between GPS → UWB → Vision
  • Vision Anchoring: AprilTag provides absolute pose reference at close range
  • EKF Covariance Tracking: Confidence-weighted fusion of all sensors
  • Median Filtering: 5-point window reduces UWB noise by 60%

Sensor Range Limitations

No single sensor provides full coverage: GPS is imprecise, UWB has limited range, vision fails at distance.

🛡️ Solution

  • Adaptive Sensor Fusion: Automatic weight adjustment based on distance
  • Overlap Zones: Smooth handover between sensor effective ranges
  • Redundancy: Multiple sensors cross-validate each other
  • Fallback Strategy: Graceful degradation if any sensor fails

Real-Time Computation

Processing multiple sensor streams and running EKF at 100Hz requires significant computational resources.

🛡️ Solution

  • Dedicated Hardware: ESP32-S3 with dual-core architecture
  • Optimized Algorithms: Linear algebra simplified for embedded systems
  • Hardware Acceleration: UART DMA for sensor data transfer
  • Priority Scheduling: Critical control loop runs on separate core

Mechanical Docking Precision

Electromagnet requires sub-centimeter alignment for successful connection. Misalignment causes docking failure.

🛡️ Solution

  • Vision Fine-Tuning: AprilTag provides 6DOF pose with ~1cm accuracy
  • Gentle Approach: Velocity throttled to <0.1 m/s in final phase

Communication Latency

MAVLink messages between companion computer and flight controller introduce control loop delays.

🛡️ Solution

  • Onboard Companion: ESP32-S3 added onboard to reduce link distance
  • Direct TELEM Link: MavLink over TELEM serial for lower latency
  • Baud Rate Optimization: 57600/115200 baud for minimal latency
  • Prediction: EKF predicts state 10-50ms ahead

Safety & Risk Mitigation

ISEF-aligned risk assessment and procedures for safe testing

Key Risks & Hazards

My project involves typical UAV risks that must be identified and controlled.

🛡️ Identified Risks

  • Spinning Propellers: Laceration risk during operation
  • LiPo Batteries: Fire risk during charging or damage
  • Autonomous Flight: Potential crashes during testing
  • Electrical Wiring: Shock/short risk during assembly
  • GPS or PX4 Errors: Unstable flight if misconfigured
  • No Chemicals/Bio: No hazardous chemicals or biological agents used

Hazardous Items & Activities

Components and activities that require extra caution during development.

🛡️ Items Involved

  • LiPo Batteries: High-energy storage
  • Brushless Motors/Propellers: High-speed rotating parts
  • Soldering: Heat and fumes during wiring
  • Autonomous Flight Tests: Moving vehicles in airspace
  • Optical Flow + LiDAR: Active sensors in close range
  • Onboard Camera: Vision system hardware
  • No Microorganisms: None used in this project

Safety Precautions

Steps I take to reduce risk during testing and operation.

🛡️ Procedures

  • Outdoor Testing: Flights only in open spaces
  • Bench Safety: Propellers removed during bench tests
  • Kill Switch: RC kill switch configured
  • Battery Safety: LiPo charged in a fireproof bag
  • PPE: Safety goggles used during assembly and tests
  • Weather Control: Flights only in low wind conditions
  • Supervision: Direct supervisor present during docking tests

Disposal Procedures

Safe handling and disposal of any damaged components.

🛡️ Disposal

  • No Hazardous Waste: No chemicals or bio waste generated
  • E-Waste: Damaged propellers/electronics disposed as e-waste
  • Battery Recycling: Faulty LiPo batteries recycled at approved centers

Safety References

Guidelines I follow to ensure safe and compliant testing.

🛡️ Sources

  • PX4 Safety Guidelines
  • AMA Drone Safety Code
  • LiPo Battery Safety Manuals
  • Holybro Hardware Documentation
  • ISEF Hazardous Devices Rules

Why This Project?

Bridging the gap between theory and real-world autonomous aerial operations

Extend UAV Endurance

  • Problem: Battery limits UAV flight time to 20-40 minutes
  • Impact: Reduces operational range and mission flexibility
  • My Solution: Mid-air docking enables future in-flight battery swap capability
  • Benefit: Continuous surveillance, border patrol, disaster monitoring without landing

Enable Autonomous Missions

  • Problem: Landing requires skilled pilot and suitable terrain
  • Impact: Limits deployment to remote areas
  • My Solution: Aerial mothership enables child UAVs to autonomously depart and return
  • Benefit: High-efficiency missions with minimal human intervention

Multi-UAV Collaboration

  • Problem: Individual UAVs lack coordination and relative positioning
  • Impact: Cannot perform complex cooperative tasks
  • My Solution: Multi-sensor relative localization enables stable multi-UAV coordination
  • Benefit: Formation flying, distributed sensing, cooperative payloads

Urban & Indoor Operations

  • Problem: GPS is unreliable in cities and indoors
  • Impact: UAVs cannot operate in critical infrastructure
  • My Solution: UWB + Vision maintains relative position without GPS
  • Benefit: Warehouse inspections, search & rescue, building monitoring

What Makes This System Unique

Key differentiators from existing approaches

Multi-Sensor Architecture

Unlike single-sensor systems, I fuse GPS, UWB, and vision seamlessly, each operating in its optimal range. This is the only practical solution for full-scale docking.

Hardware-in-the-Loop

Real UAVs with PX4 autopilot, not simulation. Demonstrates actual aerodynamic challenges and validates algorithms in real-world conditions.

Open & Reproducible

Built on PX4 (open-source) and ESP32 (affordable). Anyone can replicate, modify, and extend the system without expensive proprietary hardware.

Electromagnetic Docking

Mechanical locking via electromagnet provides reliable connection. Alternative methods (mechanical claws, visual servoing) are more complex and less robust.

Wind Robustness

Explicitly designed for aerodynamic disturbances. High-rate control loop (100Hz) and predictive compensation outperform standard approaches.

Core Advantages Over Competing Approaches

GPS-Only Systems

~1m accuracy. Insufficient for docking. My system achieves <1cm final accuracy.

Vision-Only Systems

Fail at >2m range. I use GPS/UWB for approach, vision only for docking.

UWB-Only Systems

~10cm accuracy not enough for magnetic docking. Vision provides sub-centimeter precision.

Simulation-Based Research

Misses real aerodynamic effects. My system handles actual wind and downwash.

Proprietary Solutions

Expensive and closed. I use affordable hardware with open-source software.

Manual Docking

Requires skilled pilot. My system is fully autonomous from takeoff to lock.

Real-World Applications

From industrial operations to advanced research, this technology addresses critical needs

Cooperative UAV Formations

  • Airborne sensor arrays (radar, communication, imaging)
  • Formation photography and mapping
  • Multi-UAV collaborative missions
  • Maintaining "relative stillness" in flight

GPS-Degraded Environments

  • Urban canyons and industrial zones
  • Harbors and shipyards
  • Large semi-indoor facilities
  • Emergency response and industrial inspection

Airborne Communication Relay

  • 5G and emergency communication networks
  • Disaster area signal coverage
  • Temporary network deployment
  • Antenna arrays requiring precise positioning

UAV Mothership Systems

  • In-flight deployment and recovery
  • Dynamic mission reconfiguration
  • Safe and precise recovery phases
  • Reduced reliance on manual control

Aerial Calibration Platforms

  • In-flight equipment calibration
  • Precise relative pose control
  • Aerial mobile reference benchmarks
  • Reconfigurable spatial reference systems

Technology Stack

Open-source flight control meets custom sensor fusion

Hardware

Pixhawk 6C Flight Controller

Reliable autopilot hardware ensuring stable flight

M5Stack UWB Module

DW1000-based Ultra-Wideband ranging (4 anchors + 1 tag)

OpenMV Camera

Machine vision with AprilTag detection

ESP32-S3 Companion Computer

High-performance computing for sensor fusion and control

Electromagnet Docking System

Secure mechanical connection for mid-air docking

Software

PX4 Autopilot

Open-source flight control software - handles basic flight operations

Extended Kalman Filter (EKF)

Multi-sensor state estimation for smooth, continuous positioning

2D/3D Trilateration Algorithm

Linear least squares solving for position from UWB distances

AprilTag Detection

Fiducial marker system for high-precision visual pose estimation

MAVLink Protocol

Communication between companion computer and flight controller

Why This Approach Works

While single-sensor approaches fail in different scenarios, my multi-sensor fusion system provides robust performance across all stages of docking. GPS ensures I can find the mother UAV from anywhere. UWB provides stable convergence when GPS is insufficient. Vision guarantees millimeter-to-centimeter alignment for final docking. The EKF framework keeps the process continuous and controllable. This architecture directly targets ISEF-level research needs for robust, real-world UAV coordination.