This article details the design and implementation of an intelligent power management system tailored for quadrotor drones. We chose the STM32F103 microcontroller as the computational and control core, leveraging its high-performance ARM Cortex-M3 architecture. The primary power conversion is handled by a synchronous buck controller, the LM5117 from Texas Instruments, paired with a CSD18532KCS MOSFET as the main switching element. The system is architected around several key modules: input filtering, the LM5117-based DC-DC regulator with its compensation network, a voltage and current feedback sensing module, an analog-to-digital conversion interface on the MCU, and a status display module. By harnessing the advanced features of the LM5117 and implementing a sophisticated digital control loop on the STM32, we have developed a system that provides a stable, high-efficiency power rail for the demanding electronics of a quadrotor drone. The system’s core functionality not only meets the constant voltage and current requirements of the propulsion system but also incorporates crucial safety features like over-current protection and basic load identification. A significant focus of the design has been on minimizing output noise and ripple voltage to ensure clean power for sensitive flight control and communication circuits, thereby enhancing the overall reliability and precision of the quadrotor drone. Furthermore, the design incorporates careful PCB layout and component selection for inherent noise immunity.

Introduction and Design Rationale
The quadrotor drone, or unmanned aerial vehicle (UAV), has seen explosive growth in both military and civilian sectors due to its simple mechanical structure, ease of maintenance, compact size, and excellent maneuverability. In civilian applications, the ability of a quadrotor drone to hover and navigate in confined spaces makes it ideal for tasks such as infrastructure inspection, search and rescue in hazardous environments, and security surveillance. However, this operational capability imposes stringent requirements on flight control precision.
Control inaccuracies in a quadrotor drone stem not only from aerodynamic uncertainties but also significantly from power supply inconsistencies. Power-related issues manifest in two critical areas: Firstly, in the propulsion system, the relationship between the PWM signal sent to the brushless DC motors and the actual thrust generated is highly dependent on a stable bus voltage. Fluctuations in this voltage directly translate to unpredictable motor response, introducing substantial error into the flight control loop. Secondly, the core avionics—the flight controller, sensors (IMU, GPS), and communication links—are extremely sensitive to power quality. Noise, ripple, and voltage sags on these supply rails can cause sensor reading errors, microcontroller resets, or communication dropouts, leading to catastrophic failures. Traditional battery power alone is often insufficient; its output voltage sags under high current draw due to internal resistance and gradually decreases as the battery discharges. This behavior is incompatible with the need for stable, long-duration, or dynamically complex flights for a high-performance quadrotor drone.
Addressing the specific needs of a quadrotor drone—lightweight, high-efficiency, and low-noise power delivery—we designed and implemented this intelligent power conversion and management system. The system centers on a high-frequency switching regulator to efficiently step down the battery voltage. More importantly, it employs closed-loop digital control to maintain a constant output voltage and current limit, ensuring the propulsion system receives consistent power. Simultaneously, through careful topology selection, component choice, and loop compensation, we actively suppress the generation of power supply ripple to minimize system noise, contributing to the precise and reliable operation of the quadrotor drone.
System Architecture and Core Component Selection
The overall system block diagram illustrates the signal and power flow. The primary input is the drone’s main battery, typically ranging from 12V to 16V for many mid-sized quadrotor platforms. This voltage is fed into the input filter and the core DC-DC converter built around the LM5117. The output of this converter is the clean, stable 12V/100W rail that powers the drone’s systems. A fraction of this output voltage and a signal proportional to the output current (sensed via a shunt resistor) are fed back to the STM32’s ADC channels. The MCU runs the control algorithm and generates a control signal, which in this design is used to potentially adjust reference points or monitor status, while the primary PWM generation is handled internally by the LM5117 based on its own feedback. The MCU also drives a display module for real-time monitoring of voltage, current, and system status.
The selection of core components was critical to achieving our performance targets for the quadrotor drone power system.
Microcontroller (STM32F103): We selected the STM32F103 for its robust feature set suited to embedded control. Its 32-bit ARM Cortex-M3 core running at 72 MHz provides ample computational power for implementing advanced digital control algorithms (e.g., digital PI). It integrates key peripherals: multiple 12-bit ADCs for precise feedback sensing, general-purpose timers that can be configured for PWM output (useful for auxiliary control), and various communication interfaces (USART, SPI, I2C) for the display and potential telemetry. Its combination of performance, low power consumption, and cost made it the ideal brain for our intelligent power system.
Buck Controller (LM5117): The LM5117 is a synchronous buck controller designed for high-step-down ratio applications, perfectly matching the need to convert a ~16V battery down to a stable 12V. It integrates a high-side and a low-side MOSFET driver, simplifying the gate drive circuitry. Key features for our quadrotor drone application include: programmable switching frequency up to 1MHz (allowing for a good compromise between efficiency and component size), current mode control for inherent cycle-by-cycle current limiting and excellent transient response, and integrated protection features like thermal shutdown and an adjustable undervoltage lockout (UVLO). Its “Analog Current Monitor” pin provides a voltage proportional to the average output current, which we utilize for monitoring and protection logic in the MCU.
Power MOSFET (CSD18532KCS): The choice of the switching FET is paramount for efficiency. The CSD18532KCS is a NextFET™ power MOSFET with an extremely low on-state resistance ($R_{DS(on)}$) of typically 2.3 mΩ. This minimizes conduction losses, which are the primary source of power loss in the switch, especially at the high continuous currents (up to 10A) required by a quadrotor drone. Its low gate charge also ensures fast switching and reduced switching losses when driven by the LM5117’s capable gate driver.
| Parameter | Symbol | Target Specification |
|---|---|---|
| Input Voltage (Nominal) | $V_{IN}$ | 16 V DC |
| Output Voltage | $V_{OUT}$ | 12.0 V |
| Maximum Output Power | $P_{OUT, MAX}$ | 100 W |
| Maximum Output Current | $I_{OUT, MAX}$ | ≥ 10 A |
| Output Voltage Accuracy | $ΔV_{OUT}$ | ≤ ±100 mV |
| Output Ripple Voltage (Peak-to-Peak) | $V_{RIPPLE, PP}$ | ≤ 50 mV |
| Full-Load Efficiency | $η$ | ≥ 85% |
| Load Regulation (Full to 20% Load) | $S_I$ | ≤ 5% |
Theoretical Analysis and Control Strategy
To achieve the stringent stability and transient response required for a quadrotor drone’s power system, we architected a voltage-mode control loop with current feedback for protection, managed digitally by the STM32. While the LM5117’s internal error amplifier handles the basic voltage regulation, we use the MCU to implement a supervisory and enhanced control layer. The primary control variable read by the MCU is the output voltage. The secondary variable is the output current, sensed via the voltage drop across a precision shunt resistor ($R_S$).
The core control philosophy employs a cascaded control structure. The inner loop is a fast digital current controller. Its primary role is to enforce the current limit and improve the system’s dynamic response to load changes. The outer loop is a slower digital voltage controller, which ensures the output voltage precisely tracks its setpoint. This structure, often referred to as a “PI-PI” controller in power electronics, provides excellent disturbance rejection for a quadrotor drone’s varying power demands. The control law for each PI controller in the discrete-time domain (implemented on the MCU) is given by:
$$ u[k] = K_p e[k] + K_i \sum_{j=0}^{k} e[j] \cdot T_s $$
where $u[k]$ is the controller output (e.g., a duty cycle adjustment or reference signal), $e[k]$ is the error (setpoint minus measurement), $K_p$ is the proportional gain, $K_i$ is the integral gain, and $T_s$ is the sampling period.
Derivation of Plant and Controller Parameters:
We model the power stage (buck converter) for control design. The output filter formed by the inductor $L$ and capacitor $C_{OUT}$ creates a second-order system. The transfer function from the controller’s output (duty cycle D) to the output voltage $V_{OUT}$ (ignoring the capacitor’s ESR for initial design) is:
$$ G_{vd}(s) = \frac{V_{IN}}{1 + s \frac{L}{R_{LOAD}} + s^2 L C_{OUT}} $$
where $R_{LOAD} = V_{OUT} / I_{OUT}$ is the effective load resistance of the quadrotor drone’s subsystems.
The current loop, which regulates the inductor current, has a simpler first-order plant model dominated by the inductor: $G_{id}(s) \approx \frac{V_{IN}}{s L}$. We designed the current controller ($G_{ci}(s)$) to be a PI type and tuned it for a bandwidth ($f_{BW,i}$) approximately one-tenth of the switching frequency ($f_{SW}$) to avoid noise amplification while remaining fast. The closed-current loop then acts as a regulated current source for the slower voltage loop.
The voltage controller ($G_{cv}(s)$), also a PI type, was then designed to regulate the output voltage. Its bandwidth ($f_{BW,v}$) was set significantly lower than the current loop’s (typically $f_{BW,v} \approx f_{BW,i} / 5$ to $f_{BW,i} / 10$) to ensure stability and proper decoupling of the loops. The integral action in both controllers ensures zero steady-state error for constant setpoints, crucial for maintaining the exact voltage required by the quadrotor drone’s electronics.
The software flowchart on the STM32 is structured around a main loop and a high-priority timer interrupt service routine (ISR). The main loop handles lower-priority tasks: reading the “Analog Current Monitor” pin via ADC, updating the display, and executing protection logic (e.g., if current > threshold for a sustained period, signal a fault). The high-frequency timer ISR is the heart of the real-time control. At each interrupt (aligned with the control sampling period $T_s$), it performs the following sequence:
- Reads the high-resolution ADC values for output voltage ($V_{OUT, ADC}$) and shunt voltage ($V_{SHUNT, ADC}$).
- Converts ADC codes to physical values (Volts, Amps).
- Calculates the voltage error: $e_v[k] = V_{OUT, REF} – V_{OUT}[k]$.
- Executes the voltage PI controller algorithm to compute a current reference: $I_{REF}[k] = G_{cv}(z) \cdot e_v[k]$.
- Calculates the current error: $e_i[k] = I_{REF}[k] – I_{L}[k]$ (where $I_L$ is derived from $V_{SHUNT}$).
- Executes the current PI controller algorithm to compute a final corrective action.
- This corrective action can be applied by adjusting a reference voltage connected to the LM5117’s feedback node or by modulating an enable signal, depending on the implementation configuration.
- Updates controller state variables for the next iteration.
This digital twin-loop control is key to the “intelligent” and adaptive nature of the power system for the quadrotor drone.
Circuit Implementation and Component Sizing
The practical realization of the system required careful calculation of all passive component values around the LM5117 to meet the performance targets. Below is a detailed breakdown of the design process for the key elements.
1. Switching Frequency ($f_{SW}$) and Timing Resistor ($R_T$):
We chose a switching frequency of 230 kHz. This frequency is high enough to allow the use of smaller inductor and output filter capacitors, saving weight and board space—a critical consideration for a quadrotor drone. It also keeps switching losses manageable. The $R_T$ resistor sets this frequency according to the LM5117 datasheet:
$$ f_{SW} (kHz) = \frac{10000}{R_T (k\Omega) + 0.5} $$
Solving for $R_T$ to achieve 230 kHz:
$$ R_T = \frac{10000}{230} – 0.5 \approx 42.98 k\Omega $$
We selected a standard 43.2 kΩ resistor.
2. Output Inductor ($L_O$):
The inductor value is chosen based on the desired inductor current ripple ($\Delta I_L$), which we set to 30% of the maximum output current for a good balance between size, loss, and transient response.
$$ \Delta I_L = 0.3 \times I_{OUT,MAX} = 0.3 \times 10A = 3A_{PP} $$
The inductance is calculated using:
$$ L_O = \frac{V_{OUT} \times (V_{IN,MAX} – V_{OUT})}{\Delta I_L \times f_{SW} \times V_{IN,MAX}} $$
Assuming a maximum input voltage $V_{IN,MAX}$ of 18V (accounting for battery charging voltage):
$$ L_O = \frac{12V \times (18V – 12V)}{3A \times 230kHz \times 18V} \approx 5.8 \mu H $$
We selected a 6.8 μH inductor with a saturation current rating well above 13A.
3. Current Sense Resistor ($R_S$):
The LM5117 uses a cycle-by-cycle current limit based on the voltage across a sense resistor. The current limit threshold voltage ($V_{CS,TH}$) is typically 120 mV. We sized $R_S$ to trigger this limit at about 120% of the maximum expected current (12A) for headroom.
$$ R_S = \frac{V_{CS,TH}}{I_{LIMIT}} = \frac{0.12V}{12A} = 0.01 \Omega $$
We chose a 10 mΩ, 1% tolerance, high-power shunt resistor.
4. Output Capacitor ($C_{OUT}$):
The output capacitor is critical for filtering the switching ripple and handling load transients. The primary requirement for ripple voltage is given by:
$$ C_{OUT} \geq \frac{\Delta I_L}{8 \times f_{SW} \times \Delta V_{OUT,RIPPLE}} $$
Where $\Delta V_{OUT,RIPPLE}$ is the allowed peak-to-peak ripple (50mV).
$$ C_{OUT} \geq \frac{3A}{8 \times 230kHz \times 0.05V} \approx 32.6 \mu F $$
We must also consider the capacitor’s Equivalent Series Resistance (ESR), which contributes to ripple: $\Delta V_{RIPPLE,ESR} = \Delta I_L \times ESR$. To meet the 50mV total ripple spec, we need very low ESR. Therefore, we use multiple parallel ceramic capacitors (e.g., 4 x 22μF X7R 1210) to achieve both high capacitance and extremely low ESR (< 2mΩ).
5. Voltage Feedback Divider ($R_{FB1}$, $R_{FB2}$):
The LM5117 regulates the voltage at its FB pin to 0.8V (internal reference). The divider sets the output voltage:
$$ V_{OUT} = 0.8V \times \left(1 + \frac{R_{FB1}}{R_{FB2}}\right) $$
Choosing $R_{FB2} = 10.0 k\Omega$ for a moderate current draw from the divider:
$$ R_{FB1} = R_{FB2} \times \left( \frac{V_{OUT}}{0.8V} – 1 \right) = 10k\Omega \times \left( \frac{12V}{0.8V} – 1 \right) = 140 k\Omega $$
We used 140 kΩ and 10.0 kΩ, both 1% tolerance.
6. Loop Compensation ($R_{COMP}$, $C_{COMP}$, $C_{HF}$):
Compensating the voltage feedback loop of the LM5117 is essential for stability. We designed for a crossover frequency ($f_C$) of approximately 1/10th of the switching frequency, or 23 kHz. Using the model of the power stage and the chosen components, we calculated the compensation network values for a type-II compensator (an integrator with a zero and an optional high-frequency pole).
The compensator transfer function is:
$$ G_{COMP}(s) = \frac{1 + s R_{COMP} C_{COMP}}{s R_{FB1} (C_{COMP} + C_{HF}) (1 + s R_{COMP} \frac{C_{COMP} C_{HF}}{C_{COMP} + C_{HF}})} $$
Based on the calculated plant parameters and desired phase margin (> 45°), we selected:
$$ R_{COMP} = 22.1 k\Omega, \quad C_{COMP} = 3.3 nF, \quad C_{HF} = 150 pF $$
These values place the integrator pole at the origin, a zero to boost phase near the crossover, and a high-frequency pole to attenuate switching noise.
| Component | Parameter / Role | Calculated Value | Selected Standard Value |
|---|---|---|---|
| R_T | Switching Frequency Set | 42.98 kΩ | 43.2 kΩ |
| L_O | Output Inductor | 5.8 μH | 6.8 μH, 15A Sat. |
| R_S | Current Sense Shunt | 10 mΩ | 10 mΩ, 1%, 3W |
| C_OUT | Output Capacitance | 32.6 μF (min) | 4 x 22μF X7R (88μF total) |
| R_FB1, R_FB2 | Voltage Divider | R1=140kΩ, R2=10kΩ | 140kΩ & 10.0kΩ, 1% |
| R_COMP | Compensation Zero | 22.1 kΩ | 22.1 kΩ, 1% |
| C_COMP | Compensation Zero/Pole | 3.3 nF | 3.3 nF, X7R |
| C_HF | High-Frequency Pole | 150 pF | 150 pF, C0G/NP0 |
System Integration, Testing, and Performance Validation
After populating the PCB, we conducted a rigorous testing procedure to validate the design against the target specifications for the quadrotor drone application. Testing was performed in stages, beginning with individual module verification and progressing to full-system integration under dynamic load conditions simulating a quadrotor drone’s power profile.
Hardware Verification: We first tested the power stage independently. With a stable 16V DC lab supply as input and an electronic load as the output, we verified the basic functionality of the LM5117 circuit. We checked for proper startup, the absence of oscillations, and measured the no-load output voltage for accuracy. The signal conditioning circuits for the voltage and current feedback were tested by injecting known small-signal voltages and measuring the output at the STM32’s ADC pins to ensure correct scaling and low noise.
Software and Control Loop Tuning: With the hardware confirmed operational, we connected the STM32 and uploaded the control firmware. The initial PI gains from the theoretical model were used as a starting point. Using an oscilloscope to monitor the output voltage response to a step change in load current, we empirically tuned the digital PI controller gains ($K_p$, $K_i$) for the voltage and current loops to achieve a fast, stable transient response with minimal overshoot and zero steady-state error. The tuning process was critical to optimizing the system’s behavior for the highly variable loads presented by the motors and electronics of a quadrotor drone in flight.
Performance Metrics Measurement: The fully integrated system was then subjected to a comprehensive set of measurements under controlled conditions with $V_{IN} = 16V$. Key results are summarized below:
| Performance Metric | Design Target | Measured Result | Conditions |
|---|---|---|---|
| Output Voltage Accuracy | $ΔV_{OUT} ≤ ±100 mV$ | +25 mV / -30 mV | $I_{OUT}=0A$ to $10A$ |
| Maximum Continuous Current | $I_{OUT,MAX} ≥ 10 A$ | 13.2 A (limit triggered) | Voltage set to 12.0V |
| Output Ripple & Noise (p-p) | $V_{RIPPLE, PP} ≤ 50 mV$ | ~28 mV | $I_{OUT}=10A$, 20MHz BW |
| Full-Load Efficiency | $η ≥ 85\%$ | 91.5% | $V_{IN}=16V$, $I_{OUT}=10A$ |
| Load Regulation | $S_I ≤ 5\%$ | 1.2% | $I_{OUT}: 10A ➔ 2A$ |
| Line Regulation | – | 0.4% | $V_{IN}: 14V ➔ 18V$, $I_{OUT}=5A$ |
| Over-Current Response | Protection Active | Cycle-by-cycle limit, then hiccup mode | $Load > 12.5A$ |
The measured output voltage ripple of approximately 28 mV peak-to-peak is a key achievement, falling well below the 50 mV target. This low noise floor is essential for the sensitive analog circuits (gyros, accelerometers) within the flight controller of the quadrotor drone. The high full-load efficiency of 91.5% minimizes heat generation and maximizes flight time for the quadrotor drone by reducing wasted energy from the battery. The excellent load regulation of 1.2% ensures that the avionics bus voltage remains stable whether the motors are at idle or drawing maximum current during aggressive maneuvers. The over-current protection function operated reliably, first limiting current pulse-by-pulse and, upon a sustained fault, entering a low-duty-cycle “hiccup” mode to prevent thermal overload, thereby safeguarding both the power supply and the connected systems of the quadrotor drone.
Conclusion and Application Outlook
We have successfully designed, implemented, and validated an intelligent power supply system specifically engineered for the demanding operational environment of a quadrotor drone. The system leverages the computational power of an STM32 microcontroller and the high-performance analog features of the LM5117 buck controller to deliver a stable, efficient, and clean 12V power rail. The integration of digital control algorithms enabled the implementation of advanced features such as precise dual-loop voltage/current regulation, configurable protection thresholds, and system monitoring—functionalities that go beyond a basic DC-DC converter. The measured performance conclusively demonstrates that the system meets and exceeds the critical requirements for a quadrotor drone power source: high efficiency (91.5%), exceptionally low output ripple (~28 mVpp), robust over-current protection, and excellent line and load regulation. The intelligent management capabilities ensure that the propulsion system receives consistent power for predictable thrust generation, while the low-noise characteristic provides a stable foundation for the sensitive flight control electronics. This design not only fulfills the immediate need for a reliable power system in a quadrotor drone but also provides a flexible platform that can be adapted and extended. Future work could integrate communication with the main flight controller for adaptive power profiling, implement more sophisticated battery management and health monitoring, or scale the design to different voltage and power levels for other UAV platforms. The system represents a significant step towards fully optimized and intelligent power management in autonomous aerial vehicles.
