Categories
Tech Explorations

Building a lab-grade power supply from old computer parts

A bench power supply is a fundamental tool for testing electronics, allowing for flexible power delivery to a range of different devices that could make their way to your bench. As electronics became ubiquitous DC power supplies have become easy to find, building capable devices from scrap electronics becomes a very budget friendly way to expand the capabilities of your setup.

I’m not beating around the bush: this isn’t how to make a fully-featured power supply for cheap, it’s a hacky, cobbled together device that could be so much more powerful, but I just don’t want it to: it’s just so I can charge batteries, power junk on to see if it works, and just get some voltages out to the world when I’m too lazy to go get a power brick. It’s ugly and profoundly utilitarian, but it works.

I’ve got a ton of ATX power supplies, and you probably do too

I’m willing to bet that when IBM launched the PC AT in 1984, they didn’t expect that it’s overall layout and design would become the de facto standard for computers, especially forty years later. One would be forgiven for questioning how we came to this predicament: there are many things to hate about the AT standard: The card risers are barely adequate for holding modern GPUs, the power supplies are way too bulky and have a rats nest of wires that you may not need, the connectors suck, and so, so much more. However, it is what stuck, so we’re stuck with it too.

This means that pretty much every desktop computer that has a tower form factor has an ATX (AT eXtended, basically a beefed up AT standard for slightly less crap and more modern applications) compatible power supply and pretty much everything is more or less in the same place inside the chassis, which makes it great for finding parts that more or less all work with each other.

If you’ve ever disassembled a desktop computer (and let’s face it, if you’re reading this you probably have), you probably ended up throwing the PSU into a pile of them that you look at every so often thinking “I should probably do something with them”; well, here we are.

Contemporary power supplies usually have a few components in common:

  • A 24-pin motherboard connector. (+3.3V, +5V, +12V, -12V, 5Vsb)
  • A 4 or 8-pin processor connector. (+12V)
  • A PCIe power connector, either 6-8 pins, with higher power models having multiple connectors. (+12V)
  • Accessory connectors, usually SATA and/or Molex connectors, for stuff like storage drives, optical drives, fans, etc. (+5V, +12V)

These devices are extraordinarily dumb: while the motherboard does have some control over its operation, the protocol is extremely simple: a +5V standby signal powers the control circuitry, which turns on the supply by pulling the PWR_ON line to ground, and it is notified that the PSU is ready to go when the PG line is pulled to +5V. That’s it. The wide array of voltages and simple communications make these supplies an exceptional way of powering almost everything. Almost.

Most bench power supplies are adjustable, having both voltage and current control over a wide range of supply conditions, which is very handy to get that pesky device that uses a weird voltage to power up, or even running tests under different conditions. There could be ways of modifying the feedback circuitry of the switchmode power supply inside, but I’m not knowledgeable enough in electronics to know how to do so, and from what I’ve seen, it might not even be possible.

Some jellybean parts from AliExpress, a box, and some soldering later

With all these factors taken into account, the requirements are as follows:

  • I want to use a ATX power supply from an old computer.
  • I want all the voltages from the ATX standard available for use.
  • I want an adjustable regulator that can do both Buck and Boost, so I can get a wide range of voltages.
  • The regulator must have both constant voltage (CV) and constant current (CC) capabilities.
  • Having two regulators would be nice.
  • The power supply must be at least 150W total.

From my pile of scrap I fished out a FSP 250-60HEN 250W ATX power supply. It’s fairly old, but it has a couple features I like:

  • It has a big fan on the top, which makes it quieter.
  • It has two 12V rails: one for the processor connector, another for everything else.
  • the wire gauges are all fairly similar, which makes it easier to bundle afterwards.

With this, I cut off all connectors and separated the rails: orange is +3.3V, red is +5V, yellow is +12V, the lonely blue wire is -12V, black is ground, and all the status cables (green for power on, gray for power good, purple for +5Vsb, and a ground for making it all work) were separated by color and soldered to ring terminals for connecting to banana plugs on the front. The +12V rail from the processor connector was also kept apart. Some cheap binding post/banana plug combos from AliExpress and a heinous 3D print job that peeled off from the print bed halfway through, and I had some voltages to work with. The power on signal went to a toggle switch that connected it to ground (this is my main power switch), the 5Vsb went to an indicator to show the device has AC power, and the power good lights up another indicator to show the device is ready to be used.

For the regulators, I went for some nifty panel mount regulators I found on AliExpress for cheap: they can handle a decent amount of power, they have a usable interface, and they have an extensive range: they can to 0-36V at 0-5A, and all from the second +12V rail. Pretty cool! Add some banana plug cables, alligator clips, some other accessories, a couple of zipties, aluminum tape, and some swearing later, we have a supply!

Ups and downs

I’m not going to sugar coat this: this is a quick and dirty project. The thing is ugly, it looks like it’s going to kill you, and it very much gives a “rough around the edges” vibe to it, but it works exactly as I had hoped for: the regulators work great, the fixed voltages are no problem, and all the control devices work as they should. There are a few things worth noting though:

  • The regulators have an interesting way of performing constant-current duties: instead of some sort of control loop to keep the current stable along a desired value, the devices just shoves whatever voltage you gave it and then it observes; it changes the output voltage to give a current lower than your target and then measures again, reaching your desired current in steps. This perturb-and-observe model is very much useful for steady-state applications, but if you have sensitive electronics like LEDs or integrated circuits, be mindful to set your voltage to a safe level before activating the CC mode, failing to do so could result in an unsafe voltage in your terminals.
  • The measurements from the regulators are accurate, but not perfect, if you need precision, use a multimeter and short leads.
  • The fixed outputs have no onboard measurement other than what is needed for protection, so be careful about shorting these out.
  • I messed up the settings on my print and it came out really deformed. If I wasn’t lazy, I’d redo them with better adhesion to the bed, but I’m not. Nothing that some tape won’t solve. I might change them later, but the thought of undoing all the binding posts makes me queasy of doing it.

Overall, it’s like having a cheap AliExpress power supply, for about a quarter of the price. Pretty good overall, I’d say.

The tools you have are better than the tools you don’t

I’ve been working with this for about a month now, and I wonder how I made it this far without a bench power supply. Building my own tools gives me tons of satisfaction, and I hope to keep using and improving this device in the future. Sometimes the tools you can build with what you have is the best tool you can possibly get, and it will probably get you farther than waiting for the shiniest gadget.

So yeah, if you have a pile of junk computer parts, build a power supply! you’ll get lots of mileage from it and it will open lots of doors in your electronics adventures, not to mention the money it’ll save you.

Get building!

Leave a Reply

Your email address will not be published. Required fields are marked *