Introduction: Building a Super Simple Regulated Bench Power Supply From an Old External Hard Drive
When doing electronics work, a regulated power supply is about the most useful thing one can have (maybe only second to a multimeter). Nice lab ones are in the hundreds of dollars but you can make a perfectly serviceable one with some old computer parts and a few bucks.
Step 1: Supplies
- External hard drive power supply
- External hard drive case (or other suitable enclosure)
- Drill (and drill bits)
- Dremel (with cutting disk)
- Wire cutters and stippers
- (x3) Binding posts (such as these: https://amzn.com/B00NWPGWP2 )
- Hot glue gun (or other suitable adhesive)
- Ruler or calipers
- Marker (fine tip dry erase works well)
Step 2: Regulated Vs Unregulated
Notice that I said "regulated" power supply. An unregulated power supply will change the voltage it is providing based on how much current is being drawn, but a regulated one will internally adjust to keep a constant voltage output over a range of output current. One of the types of power supply we are all familiar with is the "wall wart." Those little black boxes that get plugged into an outlet and are used to charge or power a vast array of consumer electronics.
The picture shows a wall wart I grabbed out of my drawer of old electronics. It notes that the output is "DC 9V 350 mA". But, if I when I measure it with my multimeter I see that the output is actually 14.2 volts! What gives? Well, it turns out that what seems like a straightforward statement of the output is not quite so simple. What the spec is actually telling is is that this wall wart is rated to give an output of 9V when, and only when, there is 350 mA of current being drawn. When less current is being drawn, the output voltage will be more than 9V and when more current is drawn it will be less than 9V. This is definitely not what we want when it comes to powering various circuits at the same voltage but different current draws, as is often the case.
When it comes to regulated power supplies, there are two types: "switching" and "linear." I won't get into the details of each type right now. Probably the most common place people use regulated switching power supplies are laptop chargers and the power supply inside desktop computers (which many instructables have shows how to "convert" to a bench power supply). It turns out that the power adaptors for external hard drive enclosures are also regulated switching power supplies, as you can see in the third picture. And, as an added bonus they have a +5 V and a +12 V rail, since the hard drive motor needs 12 volts and the control electronics need 5 volts. I have an old enclosure which stopped working but the power supply is just fine, so, it's hacking time!
Step 3: Prepping the Case
This case is especially convenient because the whole bottom panel comes off. Of course if you don't have a good case to use you can just use the power supply and build it into any case of your choosing!
The power supply consists of the cord going from the wall to the "brick" and a cord going from the brick to the case. I'm just hot glued the whole brick inside the case and cut a hole to access the connection the wall cord plugs into. The brick has a power LED on it so I drilled a small hole positioned to show the LED once the brick was glued in place. After making some careful measurements to determine where to cut, I used a dremel to make a hole for the power connection, and a drill to make the LED hole, three holes for binding posts, and some vent holes for cooling.
Step 4: Prepping the Power Supply
Cut the cord that had been used to go from the brick to the case, it's the one that can't be unplugged from the brick. Cut it just a few inches from where it connects to the brick, but long enough to reach wherever you plan to put your binding posts. Strip off the outer insulated and you'll probably find three insulated wires and one bare wire. Just cut off the bare wire. The black wire should be ground, and in my case the white wire is 12 V while the green wire is 5 V (I don't know how standardized those colors are). Check these with your multimeter.
Strip off a bit of insulation at the end of each, twist the strands together and form a partial loop to fit around the binding post.
Step 5: Put It All Together
In the second picture you can see how each wire should attach to the binding post, but when actually building it be sure to fasten the binding post to the case FIRST and then connect the wire. Put all three binding posts through their holes and fasten them down. Then loop the wire around the threaded section and tighten down the second nut on each.
That's it! Put the case together and now you have a 12 V and 5 V regulated power supply.
Step 6: How Good Is It?
Remember that I said a regulated supply should have the same voltage output for any current draw? I connected up my variable current load and tested the behavior of each rail when drawing between 0 and 1 amp of current. I also tested the wall wart we talked about at the beginning to show how it compared.
The 5 V rail varies from 5.23 V to 5.01 V at 1 amp (pretty decent)
The 12 V rail varies from 12.06 V to 11.26 V at 1 amp (not quite as good)
The 9V adaptor varies from 14.2 V to 8.47 V at 350 mA (doesn't even meet the spec of 9V at 350 mA)
The 5 V rail I'm pretty happy with, the 12 V rail is not wonderful. I think I'll actually run that one through a variable linear regulator to get a variable voltage rail, but that is for a different instructable. These are plenty decent for many of the power needs of electronics hobbyists.
Step 7: Appendix: Output Impedance
The reason an unregulated supply has reduced voltage when more current is being drawn is that it has some "internal" resistance and the greater the current through that resistance the more voltage is dropped internally. This follows Ohm's law: V = IR. The diagram in the first image show how to model this. When zero current is being used, then there is no voltage drop across the internal resistance. As the current draw increases we can compare the voltage under load to the no load voltage and find how much voltage has dropped over the internal resistance.
The second figure shows a graph of this drop plotted vs current. Using linear regression and comparing to Ohm's law we can see that the unregulated adaptor an internal resistance of about 18 Ohms, while the internal resistances of regulated 12 V and 5 V rails are, respectively, about 0.7 Ohms and 0.2 Ohms.
The value is often referred to as the "output impedance." Impedance is a similar concept to resistance but it also incorporates AC signals.
Of course, it reality there isn't just a simple resistor inline with an ideal voltage source, there are many factors at play and this is just a simple model which allows us to get an idea of how the output will behave while not needing to know anything about the internals.
We have a be nice policy.
Please be positive and constructive.