

Drone Flight Controller
Open-source ESP32-based flight controller for quadcopters, featuring sensor fusion, nested PID control, motor mixing, real-time Wi-Fi PID tuning, and a custom KiCad PCB with support for GPS and FPV modules.
- Size
- 53.4 × 68.4 mm
- Copper layers
- 2
- Thickness
- 1.6 mm
- Parts
- 21
- Nets
- 41
- Pads
- 94
- Tracks, vias
- 126, 8
- Pours
- 2
- Routed
- Yes
- KiCad
- KiCad 10.0 (file 20260206)
- Created
- 10 Jul 2026
- Updated
- 4 Oct 2026
Overview
Drone Flight Controller is an open-source printed circuit board by BrijModi, from the BrijModi/ESP32-Quadcopter-FlightController repository on GitHub, published under the MIT licence. It is a 2-layer board of 53.4 × 68.4 mm with 21 parts on 41 nets, routed with 126 tracks and 8 vias.
It is built around the MPU-6050. Its parts include 11 connectors, 2 capacitors, 2 ICs, 1 resistor and 1 diode. It belongs with the robots and motor control and radio and wireless boards and the ESP32 boards of this library.
Main components
1README
README.mdESP32-Quadcopter-FlightController
Open-source ESP32-based flight controller for quadcopters, featuring sensor fusion, nested PID control, motor mixing, real-time Wi-Fi PID tuning, and a custom KiCad PCB with support for GPS and FPV modules.
📘 Introduction
This project is a fully custom ESP32-based quadcopter flight controller, built from scratch to provide complete hardware and firmware flexibility.
Unlike commercial closed-source flight controllers, this system allows direct modification of IMU handling, PID algorithms, motor mixing, and communication layers—making it ideal for learning, research, and UAV experimentation.
The controller runs an 83 Hz control loop, uses a complementary filter for real-time roll/pitch estimation, and stabilizes the quadcopter using nested PID loops (Angle + Rate).
A built-in Wi-Fi interface enables on-the-fly PID tuning and telemetry, eliminating the need to reflash firmware between adjustments.
This repository includes the complete firmware, custom KiCad PCB design, calibration and testing utilities, project media, and a comprehensive technical report documenting the system design and implementation.
⭐ Highlights
- Custom ESP32-based flight controller firmware
- Complementary filter for attitude estimation
- Dual-loop PID control for roll, pitch, and yaw
- Motor mixing for X-configuration quadcopters
- Real-time Wi-Fi tuning dashboard
- Custom two-layer PCB with expansion support
- Stable and tested flight performance (90–95%)
- Open-source and fully modifiable
🖼 Drone Image

🔧 Features
- Real-time IMU data acquisition using MPU6050
- Complementary filter–based angle estimation
- Nested PID loops for angle and rate stabilization
- PWM signal generation for ESCs
- i-BUS / PWM receiver input handling
- Wi-Fi HTTP server for dashboard + tuning
- Support for barometer (alt-hold), GPS, and FPV modules
- Modular code structure for easy experimentation
🛠 Hardware Used
- ESP32 DevKit V1
- MPU6050 IMU
- RS-2212 920KV motors + 30A ESCs
- FlySky FS-i4X receiver
- 3S Li-Po battery
- F450 frame
- Custom-designed flight controller PCB
📂 Repository Contents
-
Firmware/Main_Firmware/– Main ESP32-based quadcopter flight controller firmwareTesting_Calibration/– Calibration, testing, and Wi-Fi PID tuning utilities
-
Hardware/Drone Flight Controller/– Complete KiCad project (schematic, PCB layout, and project files)FC Gerber.zip– PCB manufacturing (Gerber) filesPCB View.pdf– PCB layout overviewSchematic.pdf– Flight controller circuit schematic
-
Media/Drone/– Drone assembly, flight controller, and hardware imagesTest Flight and Calibration/– Flight test videos, calibration recordings, and PID response graph
-
Technical Report.pdf– Comprehensive technical documentation covering hardware design, firmware architecture, implementation, and testing
💻 Software Requirements
- Arduino IDE 2.x
- ESP32 Arduino Core
- KiCad 9.x (for PCB design)
📚 Libraries Used
Wire– I²C communicationESP32Servo– ESC PWM controlWiFi– Wireless communicationAsyncTCP– Asynchronous TCP networkingESPAsyncWebServer– Web-based PID tuning dashboardSPIFFS– Web dashboard file storage
🚀 Getting Started
Follow the steps below to configure and fly the quadcopter for the first time.
1. Hardware Setup
- Assemble the quadcopter and connect all hardware components.
- Wire the ESP32, MPU6050, ESCs, receiver, and motors according to the provided schematic.
2. Verify Receiver and ESCs
- Upload the firmware from
Firmware/Testing_Calibration/Receiver_PWM_Testing/to verify proper receiver operation. - Upload the firmware from
Firmware/Testing_Calibration/ESC_Calibration/and calibrate all ESCs.
3. Calibrate the IMU
- Upload the firmware from
Firmware/Testing_Calibration/IMU_Calibration/. - Place the quadcopter on a level surface and perform the IMU calibration.
- Copy the generated accelerometer and gyroscope offset values into both the main flight controller firmware and the PID tuning firmware.
4. Tune the PID Controller
- Upload the firmware from
Firmware/Testing_Calibration/PID_Tuning_Webserver/. - Connect to the ESP32 Wi-Fi access point and open the PID tuning dashboard.
- Tune the roll, pitch, and yaw PID gains until stable flight performance is achieved.
- Copy the optimized PID values into the main flight controller firmware.
5. Upload the Main Flight Controller Firmware
- Open
Firmware/Main_Firmware/Flight_Controller_v2/Flight_Controller_v2.ino. - Update the firmware with the calibrated IMU offsets and tuned PID gains.
- Upload the firmware to the ESP32.
6. Perform Flight Testing
- Verify the motor rotation direction and propeller orientation.
- Perform an initial low-throttle hover test in a safe, open area.
- Fine-tune the PID gains as required to achieve stable and responsive flight.
Parts
21| Qty | Value | Footprint | References |
|---|---|---|---|
| 4 | MountingHole | MountingHole:MountingHole_3.2mm_M3 | H1, H2, H3, H4 |
| 2 | 470uf, 25v | Capacitor_SMD:CP_Elec_6.3x7.7 | C1, C2 |
| 1 | 220 / 330 | Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_Horizontal | R1 |
| 1 | Batt | Connector_PinHeader_2.54mm:PinHeader_1x02_P2.54mm_Vertical | J9 |
| 1 | Camera | Connector_JST:JST_XH_S3B-XH-A_1x03_P2.50mm_Horizontal | J7 |
| 1 | ESC1 | Connector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_Vertical | J2 |
| 1 | ESC2 | Connector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_Vertical | J3 |
| 1 | ESC3 | Connector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_Vertical | J4 |
| 1 | ESC4 | Connector_PinHeader_2.54mm:PinHeader_1x03_P2.54mm_Vertical | J5 |
| 1 | ESP32 DEV Board | ESP32 Devkit v1:MODULE_ESP32_DEVKIT_V1 | U1 |
| 1 | GPS / Compass | Connector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_Vertical | J11 |
| 1 | LED | LED_THT:LED_D5.0mm | D1 |
| 1 | MPU-6050 | Connector_PinHeader_2.54mm:PinHeader_1x08_P2.54mm_Vertical | U2 |
| 1 | Pressure Sensor | Connector_PinHeader_2.54mm:PinHeader_1x07_P2.54mm_Vertical | J10 |
| 1 | Receiver Channels | Connector_PinHeader_2.54mm:PinHeader_1x06_P2.54mm_Vertical | J6 |
| 1 | Receiver Power | Connector_PinHeader_2.54mm:PinHeader_1x02_P2.54mm_Vertical | J1 |
| 1 | VTX | Connector_JST:JST_GH_SM06B-GHS-TB_1x06-1MP_P1.25mm_Horizontal | J8 |
Questions
How big is the Drone Flight Controller PCB?
It measures 53.4 × 68.4 mm and has 2 copper layers, 1.6 mm thick.
What parts does the Drone Flight Controller use?
21 parts, built around the MPU-6050. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.
Where can I download the Drone Flight Controller KiCad files?
From the BrijModi/ESP32-Quadcopter-FlightController repository on GitHub, at the commit this page was made from: the board is Hardware/Drone Flight Controller/Drone Flight Controller.kicad_pcb and its schematic Hardware/Drone Flight Controller/Drone Flight Controller.kicad_sch. PCBKit opens the board in the browser, with nothing to install.
Can I use the Drone Flight Controller design in my own project?
Its repository publishes it under the MIT licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).
Similar boards
- 2 layers23 × 120 mm

- 4 layers95 × 50 mm

Control board
ZhuYanzhen1/MM32_CLion
本项目是全国大学生智能车竞赛GDUT 2022年极速越野组的项目文件。采用了LQR控制器和多速率卡尔曼融合算法,并在单片机上实现。This project is the project document for the GDUT 2022 Extreme Off-Road Category of the National Student Intelligent Vehicle Competition.
129 parts58AGPL-3.0 - 2 layers50 × 66 mm

- 2 layers36 × 43 mm

Asac fc rev a
victorhook/asac-fc
asac fc is an rp2040 based flight controller made for FPV drone flying
119 parts52GPL-3.0 - 4 layers305 × 208.3 mm

- 2 layers98.5 × 17.8 mm

- 2 layers36.2 × 36.2 mm

- 2 layers26 × 21.3 mm

PModBoard
pms67/PModlet
PMOD PCB with USB-to-UART converter and IMU (MPU-6050, I2C) for FPGAs.
19 parts15MIT