Introduction: DIY Small Bench Power Supply

Picture of DIY Small Bench Power Supply

This is a small bench power supply that I made some time ago, and because I was very busy I couldn't do the instructable for it. I do apologise for taking so long, I hope it was worth the wait :).

After making my Mini Adjustable Power Supply I was very happy with it, but I was missing a more accurate control of the voltage and current. So I decided to make this slightly bigger (but still small) bench power supply.

The heart of the unit is basically the same as on the other power supply. It is based on the LM2596S. This IC can handle up to 3A with a good heat sink. I would use it only for 2A to be on the safe side.

There is a video of the unit working on the last step of this instructable.

Enough talking about it... let's make it...

Step 1: Materials and Tools

Here is a list of materials and tools I used for this project. Many of them can be replaced with other components that you may have already, but I would definitely use an aluminium enclosure, as I used it as a heat-sink as well. I have tried to find the cheapest components, but double check that the price has not changed, you may find it cheaper somewhere else.


-Aluminium Enclosure (link)

-DC-DC Bulk Converter (LM2596S) (link)

-6 Pin Headers (link)

-10k Multi turn Potentiometer x2 (link)

-Potentiometer knobs(link)

-Volt, Amp Metter (link)

-Heat sink paste.

-Toggle Switch(link)

-Rocker Switch(link)

-Nail Polish.

-Nail Polish remover or Acetone.

-Power Panel Mount Connector (link) Check the power supply connector to get an appropriate connector.

-Banana sockets (link) (You may get cheaper ones, but I like the ones on the link because they are smaller)

-Banana test leads (You may have already one, I won't put a link as it may be worth getting a decent one)


The rest of the components are only necessary if you want to have LEDs to let you know if you limiting the current or the voltage, and to let you know if the output is set to on.

-attiny85 (link)

-2x Generic PNP transistors

-500R resistor x4 (or a close one)

-10k resistor x2

-100nf ceramic capacitor x2

-5V regulator L7805CV

-Heat-sink for the voltage regulator

-3mm Red LED x2

-5mm Two Colours LED and Panel mount for it.

-Etching Solution (Ferric Chloride) It is also used for PCB etching.

-Two containers for using the etching solution. One should fit inside the other and the inner one has to be big enough so the aluminium enclosure fits inside. (See step 2 for photos). They also need to be heat resistant.



-Cutting disk

-Drill and various drill bits

-Heat glue gun

-Solder and soldering iron

For the optional upgrade of warning LED's you will also need:

Household iron

Laser Printer

Step 2: Design and Etching the Enclosure

Picture of Design and Etching the Enclosure

After taking measurements of the enclosure and all the components, I designed the layout of the front of the unit with Photoshop. I added the file so you can modify it to your needs. If you are designing it in another enclosure, just make sure you take into account what's inside the enclosure and fitting points.

Print the design on photo paper and with a good quality laser printer.

Place the front of the aluminium enclosure on top of the photo paper, printed side facing the aluminium. Use the iron to heat as evenly as you can the other side while applying pressure. Do this for about two minutes, or when you see the back looking like the one on the photo.

Wait for it to cool down, and peel the paper off. If everything when well your design will be left on the enclosure.

Inspect the printed area to see bright spots, and paint them with nail polish. Anything that is not covered will be etched.

Use tape to protect the rest of the front of the enclosure so you don't damage it with the etching solution.

Put some hot water in the bigger container and place the other one inside.

WARNING!! Wear gloves and eye protection when handling the etching solution. Use the solution only in a well ventilated area. The etching solution will stain yourself as well as pretty much everything it touches, and it will damage anything metal, especially be careful with the sink if is the metal type, when washing the enclosure.

Pour some of the etching solution in the smaller container and leave for a few minutes to warm up. Place the front of the box in there. Agitate for about two minutes and a half. (Time will depend on the temperature of the etching solution).

Once it has been etched, wash with cold water. I use some etchant neutraliser to stop the etchant reaction, but it is not necessary if you keep applying cold water for some time. Apply nail polish and let it dry. Carefully remove the excess to leave nail polish only on the etched area. This may take a few attempts, but I didn't want to sand the aluminium

Step 3: Drilling and Fixing Components

Picture of Drilling and Fixing Components

I always cover the enclosures with decorators tape to protect it while drilling and cutting it. It also helps the marking procedure as it is a lot easier to mark on the tape than on the aluminium.

I measured all the components during the design process, so it was a matter of just drilling and cutting where the marks were. Just make sure your components will fit before this step.

I placed all the components on the aluminium where they will stay so I could access everything to solder the cables.

Step 4: Heat-sink for the DC-DC Converter

Picture of Heat-sink for the DC-DC Converter

I decided to use an aluminium enclosure so I could use it also as a heat-sink. I cut a small piece of aluminium and after applying heat paste, I glued it to the back of the regulator. Then I applied heat paste on the back of the enclosure and hot glued the regulator to the back.

Step 5: Schematic and Diagrams

Picture of Schematic and Diagrams

These schematics are self explanatory. The first one is without the LEDs, the second has the option of LEDs for the output and to let you know if you are limiting the voltage or the current.

The colours on the voltage and current meter may change on your model, so please check your wiring with the meter provider.

Here you can see the schematic bigger.

Step 6: LEDs On/Off and Limiting Warning (Optional)

Picture of LEDs On/Off and Limiting Warning (Optional)

For the CC/CV LEDs I used the dremel to sand a bit of the top of the LED to avoid it being too bright on that area. I drilled an opening on the top of the meter and placed both of the LEDs inside as per photo.

For the On/Off LED I used some heat shrink, but some tape will do.

Here is the code for the Attiny85, It is very simple, and I'm sure there are ways to do the same without a microcontroller, but I have a few of then around and I love to use them.



int LED = 1; //LED for CC
int LED2=2; //LED for VC
int Signal=0;
int SignalYN;

void setup() {

pinMode(LED, OUTPUT);




void loop() {


if (SignalYN==HIGH){ // Limiting the Current
}else {
digitalWrite(LED2,HIGH); //Limiting the Voltage


Step 7: Testing

Here is a video of a test of the power supply. I hope you enjoy this instructable. I will be happy to answer any questions or help you out to build your own.


powpher made it! (author)2016-04-30

Thank you your very good porject.

Inspiered by your posting, I've started very similler DC supply by tracing your project and just finished.

Thre are several changes from your original design.

First diffrence is front panel design.

I substitute just to stick printed label paper on the enclosure.

(This is useful also marks for drilling the case. But easy to dirt lol.)

Next difference is limiting warning circuit.

I substitute the same circuit as your output on/off circuit.

(PNP circuit has VCC -0.7V threthold. then I changed to NPN.)

Lastly, I used 1mm gel silicon sheet instead of alminium for heat sink.

When testing, unfortunately one of chinese potentiometeres are broken.

As you also know, it needs a few weeks to get replace parts, then I substituted usual volume pod.

It works fine for current limting porpose, but I don't recommend for Voltage Control because it was very critical to adjust.

Anyway, thank you very much for your posting.

I'm very satisfied your Tiny DC supply project !! (^u^)

I'm now testingand aging the Tiny DC supply and waiting another pottentiometers

delivery from China!

BTW If you can, could you tel me how to shorten pottentiometers knob?

powpher made it! (author)powpher2016-05-04

Hi, there?

I would like to explain PNP circuit converted to NPN circuit.

Attached LTSpice schematic is both NPN and PNP.

Next pics are both PNP and NPN LED switching circuit simulation results.

They would show you threshold difference.

The PNP circuit has Vcc-0.7V(=Vbe) threshold. If Vcc is 5V, the thresh is 4.3V.

If this case, the voltage of CV/CC LED on voltage is approx.3.3V then it wouldn't turn off.

The voltage of CV/CC LED off voltage is approx. 0V, therefore NPN circuit is better for this application. ( I guess Load on/off switch sensing circuit is also same situation. )

When load circuit is connected, Sense voltage begin from lowest 1.25V.

If output voltage was set under threshold voltage, load on sensing doesn't work.

Therefore NPN circuit which has +0.7V threshold would be better when you would replace Tiny 85 to transistor circuit.

I suppose another solution for this problem is to choose lower Vcc like 3.3V.

How about that ?

powpher (author)powpher2017-04-11

Hi, there

Long time no see.

Someone asked me correct circuit for amendment.

Then I would like to past it.

I hope it will help.

Especially Output ON/OFF detect application, it will be better to use NPN transistor circuit for lower (0.7V) threshold.

If you use original circuit, when you output lower than 4V this circuit

doesn't detect output is on state because threshold of original PNP circuit is apparently 4.3V.

If you have further question, please feel free to ask me.


powpher (author)powpher2017-04-11

I forgot to add one information.

You should be use anode common two color LED instead of original cathode common LED.

powpher made it! (author)powpher2016-05-15

Hi, Folks good evening !

I would like to explain silicon gel type heat sink.

I attached a silicon gel seat under the PCB to the case.

It has soft thin seat and adhesive both side then it is easy to cut and stick.

There are many vendors producing such seats in Japan. ( pls google it)

But I geuss it is gradually getting easy to get them because the some heat sink for recent CPUs or GPUs are adopting those gel seat now.

The advantage is easy to attach and easy to settle the case becase it is soft

then just tighten by nut and screw like my posting photo !

It is actually good heat conductive even if contact is not so accurate.

(I recomend 1mm to 1.5mm thick type to tighten by screw.)

And I would llike to show you LED control pwb, too.

It is dirty wiring as you see it but it works!

Best regards,

DénesM2 (author)2017-03-24

Hi newtonn2,

Great instructable. I plan to use the
original the original CC/CV led output by replacing the original smd led
with a panel mountable one. What do you think, is there any reason why
shouldn't it work?

AlexB542 (author)2017-03-16

Hi i browsing ebay for laptop chargers and all over 3amp mine is 3.2 is it ok or too much?

newtonn2 (author)AlexB5422017-03-17

That should work just fine!

mad_jack34 (author)2016-09-29

Please help, I know this is an old project but I'm just about ready to start building this and need a couple of questions answered to a few things that don't add up or look right to me. On the optional components list I see 2 10K resistors, I'm not seeing them at all on the schematic? Also I see 5 500K resistors on the schematic and not 4 like the components list? I'm a complete NOOB at this and wondering if I'm not reading the print right or if it is mislabeled somewhere, or some revisions didn't get documented or changed? Does anyone have a drawing of this ALL laid out on a perfboard?

Arduineer (author)mad_jack342017-01-13

There are 5 500Ohm resistors.

jakeson (author)2016-04-12

Mine isn't as pretty as all of yours, but I love it, and more importantly when I teach kids robotics it comes in SO HANDY! This is great, I will make a few more so that all the kids can use them when needed. This is my favorite instructable! Thank you.


pepy (author)jakeson2016-10-13

what enclosure do you use?

RobertC2 (author)jakeson2016-08-30

Enclosure it VERY nice!

awnisharma (author)2016-09-11


Can anyone suggest equivalent for BC327? I am unable to find them in my country.



zugan2. (author)awnisharma2016-09-17


Regarding PNP transistor, any general perpose small transistor is OK.

In our country, 2SA1015s(PNP) or 2SC1815s(NPN) are easy to get.

I'd like to paste substitute list below.!topic/aus.electronics/_aXrv4hJ6ko

or google it by 2sa1015 substitute.

But I mentioned before, I recommend you to use NPN circuit substitution

for lower threshold.


JeffP82 (author)2016-08-05

can you use a substitute for the attiny85

KlebersonT (author)2016-07-23


iqlogic (author)2016-07-02

Very nice instructable and interesting idea to built just a box with DC-DC converter :) You can connect almost every kind of power source (i.e. LiPo) to it which is awesome!

And this is why I think that "step-up/step-down" module will be more useful. I'm building power supply based on this module:

JeffP82 (author)2016-06-24

how do you program the tiny85 with your code and i have a single potentimeter dc board and will that work for this project

dudeist_funk (author)2016-05-25

This is probably an unreasonable question, but is there a reference for resistance values for set voltages. I'm wondering if a rotary switch with appropriate resistors on each output could be used to give the power supply a few static voltage settings (i.e. 5v, 6v, 9v, 12v, 18v, 24v).

Thanks in advance!

gkal made it! (author)2016-05-07

I have finally made it using an old psu case. For power I have used a 2A 32v led power supply bought from banggood for 6$ which I trimmed it's lower voltage. Also I used the attiny for both displays CC/CV and output power on of using a voltage divider and sensing from A3 of attiny. Again thank you very much.

gkal (author)2015-04-08

Hi. I am following your projects for a while and i am very pleased for the quality and completeness of your work. For this one i have a couple of questions.

1. Why you haven't used the onboard leds for CV and CC as in your other project and used an Attiny instead?

2. What is the purpose of the dual led ( i guess it changes color when there is power to the output but i am not sure)

3. Should i use a 3A fuse to the output to protect the LM2596 or it has internal protection?

Thank you for the excellent job.

newtonn2 (author)gkal2015-04-11

Hi there, Thank you very much.

1) I used the Attiny because the other LED's dim a bit and it was not as accurate. I thing there is only one LED for whenever you limit the current, but I wanted to have to LED's like a standard power supply.

2) Yes! It changes color when the output is on.

3) I'm not sure if there is a protection on the LM2596, but it is always a good idea.

I hope you can have it working soon. Please share some pictures once you'r done.

gkal (author)newtonn22016-01-03

Hi again. I have programmed the attiny and on the breadboard works as it should. But on the actual circuit it is stuck on showing CV (constant voltage even if the led on the lm2596 board gets on. I have checked the voltage and pin 5 on attiny gets 3.1+ volts when the led is on. Also while i was measuring with the multimeter the voltage on pin 5 the leds CC and CV from pins 6 and 7 of attiny toggle. If i manage to turn CC on then when the led on lm2596 turns off the attiny gets that we are in CV and lights the correct led. But it never again lights the CC led. I have tried using a pull down resistor of 10K between pins 5 and ground on attiny with no luck. Also i have measured the VCC on attiny and it is 4.95V. Do you have an idea why this is happening? Thank you in advance.

powpher (author)gkal2016-05-06

Hi, gkal-san

How are you doing ?

I've just finished this project and now I probably answer your question.

Usually, CMOS circuit like atttiny85 has basicaly 1/2Vcc threshold.

Pls refer to sparkfan learning site regarding TTL and Arduino threshold.

It describes usual AVR CPU using 5V Vcc has 3.0V Vih, therefore 3.08V

is very critical to sense as "H" level. (it means sometime OK, but sumotime NG, unstable. no margin)

The simple solution is to ochange Vcc to 3.3V, then Vih is going down to 2V.

The other solution is to use analog input (I don't sure attny has analog input.).

But I chose NPN trangister circuit instead that has 0.7V Vih.

Best regards, and enjoy your DIY life!

gkal (author)powpher2016-05-07

Hi powpher.

As you can see from the following solution i used the Analog input A2 . Also to power the Green/Red led i used the analog pin A3. Finally i used pin 1. To do so i changed the flags of reset pin so i can use it as output.

#include <Arduino.h>
#include <WProgram.h>



int LEDConstCurr = 1;
int LEDConstVolt = 2;
int LEDPoweron = 0;
int LEDPoweroff = 5;
int SignalConst = A2;
int SignalConstYN;
int SignalPower = A3;
int SignalPowerYN;

void setup() {

pinMode(LEDConstCurr, OUTPUT);


void loop() {


if (SignalConstYN >= 300){

} else {

if (SignalPowerYN >= 40){ //minimum voltage =1.17V with voltage divider 1:5, thus ((1.7/5)/5)*1023

} else {


powpher (author)gkal2016-05-07

Hi, gkal-san

Good day to you.

I'm so sorry that I didn't read your previous comment carefully.

You already understood threshold toggle voltage problem.

And I think your amendment is very good solution.

One attiny85 for both CC/CV sensing and Load on/off sensing is very simple.

(//minimum voltage = 1.17V at Load on/off sw on. CC/CV=3.06V to aprox. 0V )

Oppositely,I solved it both by +0.7V NPN analog circuit.

Anyway, It will be better if a little original idea was added to a base design.

I hope that our struggle will be some help for other guys try.

Best regards, and your good DIY life !

gkal (author)newtonn22016-01-04

Do you think the following code will work using pin 3 (A2) as input?

#include <Arduino.h>
#include <WProgram.h>



int LEDCC = 1;
int LEDCV = 2;
int Signal = A2;
int SignalYN;

void setup() {



void loop() {


if (SignalYN>=256){

} else {


gkal (author)newtonn22016-01-03

I finally figured it out. The led that switches on when CC gives output 3.06 V. In order for attiny to understand high state needs almost 3.3V so it never switches to CC. Now i have two options. First use analogread, but i have to desolder attiny and second use a transistor. What do you suggest?

FreeW (author)2016-04-27

I just would like to make a note that Volt, Amp Metter is
useless. I bought 5 of those and find out that when you adjust voltage
lest say to 1 volt and increase voltage to 15 it show 13-14 volts so it
go off by 1-2 volt. I would guess if you go to 30 volt the error would
be even bigger.

pranav098 made it! (author)2016-04-17

very nice project. mine is little bit different with only volt amps. I have enclosed it in a plastic box.

EionTinker (author)2016-03-21

I'm working on making one of these myself, and in my digging I found some good details: some specs on the buck converter: (input volage 7-35VDC, 2v higher than output V)

and the size of the enclosure listed here (I mean, you could follow the link, but here it is): 102mm long, 70mm wide, 64mm high

fth6111111 (author)EionTinker 2016-03-26

EionTinker (author)fth61111112016-03-28

Heads up, the one in your eBay link, LM2596, is different than the one used by newtonn2, in that it only has one trim pot, whereas the LM2596S has three, two of which, if I've read this correctly, are replaced with header pins to be wired to the 10K ohm pots used in the power supply to give the user an easy place to place knobs to adjust the output voltage and current.

fth6111111 (author)2016-03-26

Hey dear,

i didn't get, what you use as power source for the power supply. Would be very happy if you can answer.

fth6111111 (author)2016-03-26

Hey dear,

i didn't get, what you use as power source for the power supply. Would be very happy if you can answer.

sk74 (author)2016-03-18

Can I use single input source to make multiple outputs?

KugelFanger (author)2016-02-26

i got one (stupid) question, i do not have a lot of electronic's experience. But what do you use as a power source??

thanks for the answer

jali17 (author)KugelFanger2016-03-08

I think he's using a laptop charger for input

jali17 (author)2016-03-08

Great Instructable! btw what changes I have to make for a max output of 24v

telmor1 (author)2016-01-21

I starting this project, very cool and handy by the way, and i fresh at this . And i dont know what type of power brick ou tranformer to power this power suply. i need to get 3A on this or close . please help !!!!

SpenserM1 made it! (author)2016-01-09

Thanks for the instructable! I managed to pick up all the parts for 65 bucks. sure beats the 225 that my local electronics store sells their cheapest model for! I also couldnt find any affordable source for transfer paper so I just ended up using a homemade CNC router. Thanks again Newton (: , really enjoyed making this one!

newtonn2 (author)SpenserM12016-01-10

Thank you very much for sharing a photo of your unit. Donyou have a homemade CNC router? I will love to see it!

BatuqueLP made it! (author)2015-12-10

cool . It^s work?

mrcreosoate (author)2015-12-02

i have made it and i love it when purchasing the dc to dc converter you need to get a boost and buck one or a 35 volt supply

AlbertoG3 (author)2015-10-24

can I have negative voltages in this?

JimmyR4 (author)2015-10-05

does the ground on the voltage regulator mount to the case housing ? or do you need a 3 prong power supply?

ioanniskar (author)2015-09-21

What software did you use to design the schematics with the voltmeter and the LM2596 module images? (not the iCircuit app)

goldrake (author)2015-08-28

Nice really, but
What are that green paint dots on the box during etching ?

ioanniskar (author)2015-08-27


Really nice project. I will definetely build one myself in the next weeks.

Does the potentiometers' resistance value matter? Could I use 4,7K or 22K?

Is a current shunt unnecessary?

About This Instructable



Bio: Always loved electronics. I like to reuse parts or componets and I Love to be part of the Instructable community.
More by newtonn2:Makerbot Replicator Dual Auto ShutdownDIY Small Bench Power Supply Small DIY Bench Power Supply
Add instructable to: