# Bypass capacitors: no black magic here

A basic requirement for all electronic circuits is the inclusion of bypass, or decoupling, capacitors. These devices reside across the positive supply to ground, as close as possible to the supply pin of the active device. You may get away with excluding these capacitors in low-frequency circuits, but many low-frequency active devices have high-frequency entities inside the active devices. An example of a supposed "low-frequency device" is a microcontroller that uses a low-frequency system clock. Granted, the clock's frequency is slow, but the internal-gate transitions can occur in nanoseconds. Without proper power-supply filtering, these rising and falling glitches will traverse the circuit. The first step to proper supply filtering is to include a properly valued bypass capacitor.

Digital devices are not the only chips that require bypass capacitors. Analog circuits also benefit from including bypass capacitors but in another way. Although bypass capacitors in digital systems control fast rising- and falling-time glitches from the device, bypass capacitors in analog systems help reduce power-supply noise at the analog device. Typically, analog devices have built-in, preventive power-supply filtering or line-rejection capability. These noise-rejection mechanisms effectively reduce low-frequency power-supply noise, but this scenario is not the case at higher frequencies.

Typically, manufacturers include suggested bypass-capacitor values in their data sheets, but you can also determine the proper value on your own.

For instance, with microcontrollers or microprocessors, you can calculate the bypass-capacitor value when you know the typical rise and fall times (t_{RISE}) of the device signals. You also need the controller's average operating current (I_{AVE}). These quantities are in the product-data-sheet tables. You finally need to define the maximum voltage-ripple noise (V_{RIPPLE}) that your power-supply trace can tolerate. Using these values, you can determine noise frequency with the formula f_{NOISE}=1/(2×t_{RISE}); approximate surge current with the formula I_{SURGE}=I_{AVE}×f_{NOISE}/f_{MICRO}, where f_{MICRO} is the clock frequency of the controller; and calculate bypass-capacitor value with the formula C_{BYPASS}=I_{SURGE}/(2×π×f_{NOISE}×V_{RIPPLE}).

Bypass-capacitor selection for analog devices is another matter. With these kinds of circuits, you need to find the frequency at which power-supply noise affects your circuit. The best place to find this information is with the power-supply- or line-rejection-performance-over-frequency graphs in the product data sheet. Additionally, you need to determine the minimum acceptable noise that your design can tolerate. For instance, with a 12-bit ADC, you can tolerate unrejected power-supply noise of approximately ±¼ LSB for true 12-bit performance. You also need to estimate the power-supply noise-voltage magnitude. With these two parameters, you can refer to the typical power-supply-rejection-versus-frequency curve in the manufacturer's data sheet.

For example, Figure 1a provides the power-supply-rejection-over-frequency curve of a 12-bit ADC. This converter's power-supply rejection is equal to 20 log (V_{POWER-SUPPLY-RIPPLE}/V_{ADC-ERROR}).

If the noise level of your ADC power is ±20 mV (or 40 mV peak) and the allowed error is ±¼ LSB (or 0.61 mV peak, implying 5V full-scale range), the noise from the power supply will show up in the converter's output code at a –36.33-dB level. In Figure 1a, this scenario occurs at approximately 5 MHz. In Figure 1b, the appropriate bypass-ceramic-capacitor value for this converter is 0.1 to 0.01 µF.

Note that these calculations use typical values. Additionally, devices and capacitors vary from part to part. But don't let this situation deter you from using bypass capacitors. The worst of all cases is when you use none.

Complete the simulation of your ADC with IBIS

Simulating the front-end of your ADC

Painless reduction of analog filter noise

The inner workings of the three-op-amp INA

Will the right voltage reference stand up?

Measuring amplifier DC offset voltage, PSRR, CMRR, and open-loop gain

PCB signal coupling can be a problem

Phantom voltage dividers on your PCB

Accidental engineering: 10 mistakes turned into innovation

That 60W-equivalent LED: What you don’t know, and what no one will tell you…

6 famous people you may not know are engineers

DC distribution in your house and 42-V cars

10 tips for a successful engineering resume

The 5 greatest engineers of all time

Higgs Pt. 9: What makes King Carl XVI Gustaf think it’s the Higgs Boson?

10 things you may not know about Tesla

Analog Fundamentals: Instrumentation for impedance measurement

T&M survey: Engineers still prefer knobs

A mid-range approach to home-energy saving

Hush noisy steppers with novel drive algorithm

Using Micro Python for real-time software development

It's not a Maker Faire unless there's fire

Voyager: The mathematics of interstellar space travel