A low pass filter (LPF) is an electronic circuit that allows signals with frequencies below a specific cutoff point to pass through while attenuating (blocking) higher frequencies. Whether you are smoothing a noisy PWM signal from an ESP32, building an audio crossover, or suppressing EMI on a DC motor line, the LPF is your primary tool for stripping away unwanted high-frequency noise while preserving your base signal.
The Core Mechanics: What It Changes in a Real Circuit
To understand what a low pass filter actually does to a physical signal, you have to look at it in two domains: frequency and time.
In the frequency domain, an LPF changes the spectral amplitude of your signal. It applies a -3dB penalty (cutting signal power in half, and voltage to 70.7%) exactly at the cutoff frequency ($f_c$). Beyond that point, it aggressively rolls off the amplitude, typically at a rate of -20dB per decade for a basic first-order filter.
In the time domain, an LPF changes sharp voltage transitions (high $dV/dt$) into gradual slopes. If you feed a 0-5V square wave with near-instant rise times into an LPF, the output will feature rounded corners. If the square wave frequency is pushed high enough relative to the filter's cutoff, those rounded corners flatten out entirely, leaving you with a pure, steady DC voltage.
Worked Numeric Example: Designing a 500Hz RC Filter
Let’s design a passive first-order RC (Resistor-Capacitor) low pass filter. Our goal is to smooth a 5kHz PWM signal from a microcontroller into a pseudo-analog DC voltage, but we need a cutoff frequency of roughly 500Hz to ensure the 5kHz ripple is heavily attenuated.
The governing formula for the cutoff frequency of an RC filter is:
f_c = 1 / (2 * π * R * C)
Step 1: Pick a standard capacitor. We will use a 100nF (0.1µF) ceramic capacitor. This is a ubiquitous, cheap value available from manufacturers like Murata or Kemet.
Step 2: Calculate the required resistance. Rearranging the formula to solve for R:
R = 1 / (2 * π * f_c * C)
R = 1 / (2 * 3.14159 * 500 * 0.0000001)
R ≈ 3183 Ω
Step 3: Select a standard E24 resistor. The closest standard 5% resistor value is 3.3kΩ.
Step 4: Verify the actual cutoff frequency.
f_c = 1 / (2 * π * 3300 * 0.0000001) = 482.3 Hz
Because our 5kHz PWM signal is roughly a decade (10x) above our 482Hz cutoff, a first-order filter will attenuate that 5kHz ripple by approximately 20dB. This means the 5V ripple will be reduced to roughly 0.5V at the output, yielding a much smoother DC baseline for an ADC or analog meter to read. For deeper attenuation, you would cascade a second RC stage or use an active op-amp topology.
Where You Meet This in Practice
You will encounter low pass filters across almost every electrical and electronics discipline. Here is where they do the heavy lifting:
- PWM to Analog Conversion: Microcontrollers like the Arduino Uno or ESP32 output digital PWM waves. To drive an analog synthesizer control voltage (CV) input or a legacy analog panel meter, an LPF integrates the pulses into a steady DC voltage proportional to the duty cycle.
- Anti-Aliasing in ADCs: Before an analog signal hits an Analog-to-Digital Converter (like the MCP3008 or an ESP32's internal ADC), it must pass through an LPF. This blocks high-frequency RF noise that would otherwise "fold back" into the digital sampling band, creating phantom readings known as aliasing.
- Audio Crossovers: In passive speaker crossovers, an inductor-based LPF routes low-frequency bass to the woofer while blocking high-frequency treble that could damage the driver.
- Snubbers and EMI Suppression: Placing a ferrite bead and a capacitor on a 12V DC motor line forms an LC low pass filter, trapping high-frequency brush noise before it can radiate back into your power supply and reset your logic circuits.
Common Confusions and the Dielectric Trap
The most common mistake hobbyists make is confusing a DC blocking capacitor with a low pass filter. If you place a capacitor in series with an audio signal to block DC offset, you have actually built a high pass filter (it blocks 0Hz DC and passes audio AC). If you want to remove high-frequency alternator whine from a car audio line, you need a low pass filter, which requires placing the capacitor in parallel (shunting the noise to ground), not in series.
When building precision analog LPFs for audio or ADC anti-aliasing, never use Y5V or standard X7R ceramic capacitors. X7R dielectrics exhibit severe capacitance loss under DC bias (a 10µF X7R cap might act like a 2µF cap at 5V) and are microphonic (they generate voltage when vibrated). Always specify C0G (NP0) dielectrics for the capacitors in your filter network. They cost a few cents more but maintain stable capacitance regardless of voltage or temperature. See All About Circuits' filter guide for more on passive component selection.
Decision Path: Choosing Your Filter Topology and Parts
Use this decision tree to select the exact topology and components for your specific application. Do not over-engineer; pick the simplest solution that meets your impedance and noise requirements.
| Application Scenario | Required Topology | Concrete Component Picks | Why This Pick? |
|---|---|---|---|
| Smoothing a low-current MCU PWM (under 5mA) for an ADC or meter. | Passive 1st-order RC | 10kΩ metal film resistor + 100nF C0G ceramic capacitor. | Costs under $0.05, requires no power rails, and provides a 159Hz cutoff that handles 90% of hobbyist noise. |
| Driving a low-impedance load (like an 8Ω speaker or heavy analog meter) from a PWM source. | Active 2nd-order Sallen-Key LPF | TLV2372 rail-to-rail op-amp, dual 10kΩ resistors, dual 10nF C0G capacitors. | A passive RC filter will sag under heavy loads. The op-amp provides a low-impedance output and a sharper -40dB/decade roll-off. (See Analog Devices' filter basics for Sallen-Key math). |
| Suppressing high-frequency EMI on a 12V DC motor power line (drawing 2A+). | LC Pi Filter | 10µH shielded power inductor (e.g., Bourns SRP1265A) + 47µF electrolytic + 100nF ceramic. | Resistors would overheat and cause voltage drop at 2A. An inductor blocks high-frequency AC noise while passing DC current with near-zero resistance. |
The Default Recommendation: If you are simply trying to clean up a noisy sensor signal (like a thermistor or photoresistor) or smooth a PWM line for a microcontroller ADC input, default to a 10kΩ / 100nF passive RC filter. It yields a cutoff of roughly 159Hz, requires no external power supply, avoids the complexity of op-amp stability compensation, and can be built in 30 seconds on a breadboard.






