How PC Power Supplies Work

00 PSU opener

A look at the gritty details of what gives your rig its juice

The power supply unit (PSU) is one of the PC components that we tend to take for granted. It sits in the case with a bunch of wires sticking out of it, and maybe once in a while we blow some air blown into it to get rid of dust bunnies. But it’s arguably the most important piece of hardware in the PC because it does one thing: feeds the rest of the machine the electricity it needs.

Unfortunately, electricity as it comes out of the wall socket just isn’t the right kind. Electronic devices are designed to use DC electricity, while what’s coming out of the wall is AC. Plus, the electricity from the wall is way too powerful. This means the primary role of the PSU is to convert AC electricity into DC electricity at a safe level.

We’ll take a look into how a PSU does this, and the actual hardware inside it that makes this possible. As a visual aid, we’ll be cracking one open to expose its innards.

Quick Primer: types of power supplies

Power supplies come in two main flavors: linear and switched mode.

Linear power supplies are simpler, requiring only a few steps to convert AC electricity into DC electricity. They expend energy constantly and normally dump excess energy as heat and will require larger components for high power delivery. This limits them mostly to smaller power applications. Where they really shine is that their output has little noise to worry about, and laboratory-grade bench supplies will often be linear for this reason.

A switched mode power supply, on the other hand, has an internal switch that controls the flow of electricity going into the rest of the power supply. While this adds complexity, it has a couple of benefits. The first is that the power supply uses less electricity than a linear power supply. The second is that the switching action generates high-frequency AC electricity, which in turn allows some components, such as inductors and transformers, to be smaller. The downside is that the switching creates a lot of noise that needs to be filtered in the output and possibly shielded to prevent leakage.

From AC to DC: steps in a power supply’s process

As mentioned, the primary job of the power supply is to convert AC to DC. Once the DC electricity is made, it turns this into the appropriate voltages for the components to use. It gets a bit complicated once other features are taken into account, so here’s a block diagram breaking it down:

01 Psu_block_diagram

Block diagram of a PC power supply. Red lines are AC, green lines are DC.

Here’s a picture of the PSU we’re examining with the parts that do all of those steps highlighted. In case you’re wondering about the white goop and plastic sheets, the goop is to minimize vibrations while the plastic sheets are to isolate components from touching either each other or the chassis, which has the ground wire connected to it.

02-psu Layout

Step 1 – Filtering the AC input

Electricity coming out of the wall is very noisy, for a number of reasons. The first step is to filter out as much of the noise as possible, using a combination of capacitors (known as X and Y capacitors) and inductors. In addition, there may be some protection circuitry similar to that found in surge protectors to guard against sudden in-rushes of current.

If the power supply has a physical voltage switch, the input either goes into a voltage doubler circuit or continues on. The voltage doubler is used when the input is 115V, so that the rest of the power supply only has to work with 230V regardless of the actual input. If there’s active power factor correction, then it takes care of this step. Thus if the power supply takes 115V–230V with no physical switch, there’s a good chance it has active power factor correction.

03-ac Filter And Recitfier

This picture shows the bulk of the AC filtering and parts of rectifying the AC electricity described in step 2. The screws in the middle of the heatsink attach a diode for power factor correction (described in step 3) and a couple of switching MOSFETs (responsible for switching described in step 4).

Step 2 – Rectify and filter

Electricity coming from the wall is alternating back and forth between positive and negative voltages. This causes current to flow back and forth throughout the wires, producing no real work over time. Rectifiers convert the alternating current into a purely positive current as seen in the picture below:

04 Rectifier_circuit_with_graph

AC input to a full-wave rectified output (from Falstad’s Circuit Simulator).

A reservoir capacitor is used to capture energy from the still alternating flow to turn it into a more flat and stable one.

05 Filter_cap_and_ripple

Notice that on the output, there’s a sort of saw-tooth pattern. This is because the capacitor can only be charged up when the voltage of the rectified output reaches a certain point to the peak voltage. Otherwise it’s discharging. The lowest and highest points in the saw-tooth form what is known as ripple. The amount of ripple depends on the quality, capacity, and type of capacitor. High-quality power supplies will keep ripple to a minimum.

As an aside, the ATX specification calls for no more than five percent ripple on the 3.3V, 5V, 5V_SB, and 12V lines.

Step 3 – Power Factor Correction (PFC)

Power factor is a phenomena that happens with AC circuitry. There are two types of power in AC circuits: active and reactive power. Active power is power that’s being used on resistive loads, like turning a motor. Reactive power is power that works on components such as capacitors and inductors to charge them up, with no work done on the actual load.

Power factor is the ratio between the sum of the active and reactive power (called apparent power) and the active power itself, and is always lower than 1. Power factor correction aims to get this ratio as close to 1 as possible. While this sounds similar to efficiency, efficiency is an inherit component of electronics that cannot use all of the electricity to do useful work and dumps what it can’t use as heat.

There are two types of power factor correction: passive and active. Passive PFC uses inductors, a passive electric component. Active PFC uses control circuitry and transistors, or active electric components.

Step 4 – Switching

Switching clumps a few actions together to achieve the same effect: allow electricity to flow through to the rest of the power supply. Other functions of switching include:

  • Protection circuitry, such as overvoltage, overcurrent, overpower, and short circuit protections.
  • Provide basic feedback to the computer, the most important one being the power good signal, which tells the motherboard that the PSU is good to go.
  • Create a high-frequency (in the tens of kilohertz range) AC output. The reason is that this allows the transformers used in the next step to be small.

Switching requires feedback from the output in order to work properly. This is done by tapping into the output voltages that feed into the computer.

06-control Circuitry

This is the control circuitry for handling switching.

Step 5 – Transform

Transformers are used to step down the voltage to a primary 12V line and a secondary 5V line. The main 12V line is then stepped down further using DC-to-DC converters to 5V and 3.3V for the PC to use. A secondary 5V line is used to supply the 5V standby power circuitry so that the computer can turn on from the front power switch.

Step 6 – Rectify output and filter

After transforming the input into a safe voltage level output, it’s time to rectify and filter once more, because what’s coming out of the transformer is AC electricity. It’s basically a repeat of step 2.

07-output Rectifier

The picture shows the rectifier on the right, which for this model is the half-wave type. This means only half of the AC wave is used. This is most likely a cost-saving measure to avoid needing a more complex transformer. To the left of the rectifier are the capacitors used for filtering.

The output is tapped back into the switching circuit. For safety reasons, the output circuitry is not directly connected to the input circuitry. That is, there’s no PCB trace or wire connecting the two. To get around this, this power supply uses an isolating transformer. In other power supplies, they may use what is called an optocoupler. (https://en.wikipedia.org/wiki/Opto-isolator)

Step 7 – Convert and regulate

Since only 12V is created from the main transformer, DC-to-DC converters are used to create the 5V and 3.3V. Regulators help keep voltages as stable as possible. The following images show the output of these lines. The output wires are very thick because they have to support a lot of current.

08-12v And 3v Outputs

The 12V and 3.3V lines come out here.

09-5v And 3v Outputs

The 5V line comes out here.

10-main Output

All of those wires lead into the main distributor PCB. Nothing fancy going on here.

You may have noticed there were two 12V lines coming out of the output (noted by the label “12V2” on the PCB). This would imply that this particular power supply has two 12V rails, most likely distributed between the main 24-pin connector and EPS12V connector for one rail with the peripherals, including the PCI Express connector, for the other.

Putting it all together: It takes a lot to convert electricity

For the seemingly simple task of converting electricity, the power supply goes through more than a few steps to ensure the safe, correct electricity plugs into your components. While this article scratches the surface of its inner workings, we hope the information gives a better appreciation of an often overlooked part.