el cheapo power supply, ghetto style - Page 1
Forum section: electronics / projects

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 04:56:27 pm
content: With all this talk about sophisticated power supplies, some of which can brew your coffee and make your laundry, I thought I would take a different approach - make the simplest power supply.My starting point, obviously, is a 3-terminal regulator. It doesn't take lots of current so I would drop in a discrete device there.Power source is to be a 20v laptop power supply. Potentially going higher, depending on the regulators used.Display will be an el cheapo led volt/ammeter sourced from ebay a while ago.Throw in a binding posts and we are ready to go.

author: void_error
author_rank: Frequent Contributor
timestamp: January 16, 2015, 05:00:00 pm
content: A few graphs with load regulation and transient response would be nice.

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 05:20:30 pm
content: Trying out:breadboard the circuit and it worked well, powering a 10ohm resistor.The heatsink is a heat spreader (from a cpu cooler) + the project box (aluminium).

author: void_error
author_rank: Frequent Contributor
timestamp: January 16, 2015, 05:20:42 pm
content: Hmm... what's the minimum required input voltage with respect to the output voltage? My guess is VDROP+VGS... a PNP would yield a lower minimum input-output voltage difference... but then there's the base current not present for the MOSFET.

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 05:22:33 pm
content: Got out my drill and here is the project box, with the volt/ammeter + holes for the binding posts.The box is covered in painters tape.

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 05:26:14 pm
content: Yeah - my first try was actually on a MJE15030.The maximum voltage drop would be 4v (for the irf9540) + 1.5v (lm317). So my output would max out at 19.5v (power supply) - 4 - 1.5 = 14v?My pot is a 1k pot, with a 100ohm resistor between Vout and Vadj, so maximum output would be 1.25 * 11x = 14v.The maximum input voltage for lm317 is 16v. That means you can use regulators like 78xx or 1117, etc.

author: void_error
author_rank: Frequent Contributor
timestamp: January 16, 2015, 05:29:24 pm
content: Any plans for ghetto style adjustable current limiting?

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 05:41:57 pm
content: No. I don't think it would be ghetto enough,

author: pickle9000
author_rank: Super Contributor
timestamp: January 16, 2015, 05:58:56 pm
content: I remember an old one from Radio Electronics Magazine (I think). The Junk Box Special, a 7805 with a ground ref varied through a pot. It gave about 5-15 volts.

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 09:27:36 pm
content: Powering a dummy load.The pot to set output voltage is on the lower left. The 3 sets of binding posts on the right output a series of fixed voltages, from 20v (unregulated, 6amp max, top), to 12v (regulated, 1amp, middle), to 5v (regulated, 5v, 1amp, bottom).

author: dannyf
author_rank: Super Contributor
timestamp: January 16, 2015, 09:30:30 pm
content: Here is the inside of the box - all genuine all 3D construction,The IRF9540/LM317 are still not on a heatsink -> next on my to-do list.

author: Skimask
author_rank: Super Contributor
timestamp: January 16, 2015, 09:35:52 pm
content: You said you used a laptop power supply. Assuming it's one of the more-or-less standard 19V-21V "standard" power supplies with the recessed center pin that seem to be relatively common these days.Got a Digikey type part number for the laptop side of those "standard" connectors?

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 02:00:58 pm
content: Put the IRF9540 on a heatsink and boxed it up.

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 02:01:19 pm
content: With a power resistor.

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 02:02:39 pm
content: No bad for a few hours of work.And it is fairly easy as well.I am sure one can improve it a gazillion different ways but the point I wanted to make is that a power supply doesn't have to be super-duper to be useful.

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 02:04:46 pm
content: One downside to the build:the volt/ammeter I used is an el cheapo one. Its refresh rate is slow, more like 1hz or even worse. Because of that, the output voltage can seem "jumpy" when you turn the pot quickly.A real coil meter here would have been super, but it would increase the cost significantly.

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 03:32:21 pm
content: Total parts cost:I used existing parts so incremental cost for me is nothing.If you have to buy parts to build it, it may look like this:1) semiconductor: $1 for U1, $1 for M1; another $2 if you need other fixed output voltage;2) volt/ammeter: $5;3) binding posts: $5 total;4) pot: $1;5) project box: $5;6) power supply: $10;7) tools used: drill, bits, dremel, discs;hours needed: 2 - 5 hours;9) fun to have: priceless.

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 03:37:27 pm
content: One thing I didn't mention is heatsink. I used a recycled heatspreader from a cpu heatsink + the project box as a heatsink. It can comfortably dissipate 10 - 15 watts -> the box gets fairly warm, but not toasty.This approach allows me the option to bolt on the cpu heatsink and form an active heatsink, in case I need to dissipate more power.To remain fully passive, you will need a large and expensive heatsink to scale power up with this approach.So another approach you may try is to get those LM2596 modules from ebay, and use it as the regulator.

author: Alex30
author_rank: Regular Contributor
timestamp: January 17, 2015, 03:41:43 pm
content: Haha not bad for less than a days work. I guess this is one of those supplies you'd beat with a brick and wouldn't even care about which is sometimes usefulEDITNow to design the coffee warmer on my PSU project...

author: dannyf
author_rank: Super Contributor
timestamp: January 17, 2015, 04:34:04 pm
content: That was one of the primary goals of this projects. The power supply projects you see here are in my view to super-duper, with more focus on the show factor rather than the utilitarian factor of a power supply.I hope this shows people, particularly someone starting out, what is possible with minimum and widely available parts and a few hours.

author: dannyf
author_rank: Super Contributor
timestamp: January 21, 2015, 07:55:45 pm
content: With that behind me, I am going to build another el cheapo power supply, now geared more towards analog work -> meaning variable output, tracking dual rail power supplies.More to come on that later.

author: Kalvin
author_rank: Super Contributor
timestamp: January 21, 2015, 08:16:21 pm
content: Hint for the next project: Adjustable current limit is one of the most useful and most important properties of the power supply targeted for electronics design and testing.

author: hugo
author_rank: Regular Contributor
timestamp: January 23, 2015, 01:40:34 am
content: .dc v2 1.25 15 10m for an LM317... how much current it could supply ?

author: ludzinc
author_rank: Unknown
timestamp: January 23, 2015, 06:05:13 am
content: Nice work!Here's my el cheapo power supply panel with current limiting... and it too a lot longer than a few hours....http://ludzinc.blogspot.com.au/2015/01/psu-console.html

author: dannyf
author_rank: Super Contributor
timestamp: January 23, 2015, 12:26:38 pm
content: Your is a lot more full featured than mine.What are those metal switches / buttons?

author: dannyf
author_rank: Super Contributor
timestamp: January 24, 2015, 06:21:03 pm
content: I can confirm that the latest approach works - I used two blue leds (3.0v Vfwd each) forward connected as D1 and it worked like a charm.The advantage is that when the output current is high, the mosfet is taking the bulk of the dissipation, as the voltage drop over the LM317 is minimum (6v - 4v Vgs = 2v across LM317).

author: dannyf
author_rank: Super Contributor
timestamp: January 27, 2015, 12:50:09 pm
content: I am waiting for some el cheapo, and likely knock off, LT1083 to arrive from China to complete my el cheapo power supply. I intend to couple that el cheapo LT1083 with a genuine FQA27N25 (configured as a pre-regulator). This will likely allow me to go to 7 - 10amp as the voltage drop over the LT1083 is less 4v - assuming my el cheapo knock-off LT1083 is genuine,Will report back when I put it together.

author: Kalvin
author_rank: Super Contributor
timestamp: January 27, 2015, 01:15:53 pm
content: Do you have any interest in trying those dirt-cheap chinese buck-regulators as tracking preregulator? Although the switching-mode buck-regulator is not as simple as the linear MOSFET, the price would be cheap at least.

author: dannyf
author_rank: Super Contributor
timestamp: January 27, 2015, 01:19:00 pm
content: I actually proposed, in one of those power supply threads, to use a smps modules as a pre-regulator, referenced to the linear regulator's output. When I get some time, I will try it out.In the mean time, I am working on the current limiter,

author: dannyf
author_rank: Super Contributor
timestamp: January 28, 2015, 12:45:19 am
content: I am happy to report that the optocoupler approach worked like a charm.But first, my diy opto-coupler, :0I didn't want to find an optcoupler in my parts box so made one myself, from a red led, a photo resistor and a straw:

author: dannyf
author_rank: Super Contributor
timestamp: January 28, 2015, 12:46:27 am
content: What it looks like when they are put together.

author: dannyf
author_rank: Super Contributor
timestamp: January 28, 2015, 12:47:24 am
content: Once wrapped in black tape, they are ready to go.

author: dannyf
author_rank: Super Contributor
timestamp: January 28, 2015, 12:52:03 am
content: Here is the diy opto in action.The circuit is identify to the one posted previously. This particular photoresistor has a dark resistance of 18Mohm and bright resistance of 500ohm.The voltage across the LM317 is 2.2v, constant regardless of load or input voltage. Regulation performance is unchanged - vs. previous zener / led based pre-regulator.Looks to be working as expected.I will wait to try this on a switching voltage regulator module.

author: dannyf
author_rank: Super Contributor
timestamp: January 28, 2015, 12:57:06 am
content: BTW, the black tape isn't necessary for this application: if there is (variable) lighting present, the linear regulator will compensate for it automatically.That issue is further minimized when you put the parts into a box.

author: Alex30
author_rank: Regular Contributor
timestamp: January 30, 2015, 01:02:20 pm
content: Thats an interesting solution dannyf. I like the ghetto style opto coupler too haha. But why use an opto coupler at all? Can't you just hook up a 1-2V zener from the power supply output to a pull down BJT at the mosfet's gate?

author: necessaryevil
author_rank: Regular Contributor
timestamp: January 30, 2015, 01:38:51 pm
content: Nice work, but there 's something I need to say:Most of a (mains powered) supply are in the enclosure, transformer and heat sinks. So it can be worth building a supply with a more fancy circuit. In my opinion, you can save costs by buying a used enclosure/transformer/heat sinks (Or use a fan). You could also save money by using a lower output current/voltage, this makes sure that you can use cheaper versions of the mentioned parts.

author: dannyf
author_rank: Super Contributor
timestamp: January 30, 2015, 03:08:17 pm
content: QuoteYou cannot hold down the mosfet's gate to a fixed voltage -> that will limit the output voltage.Allowing the mosfet's gate to "float" maximizes the output voltage while minimizing the power dissipation over the regulator.QuoteThis one envisions the use of laptop power supplies so no transformers / capacitors. The aluminium box is used so it also acts like the heatsink.

author: Alex30
author_rank: Regular Contributor
timestamp: January 30, 2015, 03:54:57 pm
content: Quote from: dannyf on January 27, 2015, 01:29:31 pmCould you explain this I don't quite understand what you mean?

author: dannyf
author_rank: Super Contributor
timestamp: January 30, 2015, 05:07:43 pm
content: Sure.The issue with using a regular linear regulator here is that their power dissipation is a limiting factor for a power supply with a wide output voltage range. Take LM317 for example. At 20v input, 1.2 - 15v output, and 10w maximum power dissipation, the maximum current output is only 10w/(20-1.2v)=0.5amp, vs. its current limit of 1.5amp.10w is probably the upper limit for a to220 device - the datasheet specifies 20w in pulsed mode.Beyond that, the part goes into protection.So to maximize your output range, you have to shift the power dissipation to something else - in this case, the pre-regulators.In both designs, the pre-regulator was designed so that minimum (and near constant) voltage drop shows up on the linear regulator, and the bulk of the voltage drop over the pre-regulator.That's achieved in the first case with the led / zeners to maintain constant the voltage drop over the linear regulator. That approach has the advantage of simplicity - the led doubles as indicator too. However, its "ground" is referenced to the linear regulator's output, making it not doable with a smps module (whose ground is referenced to the supply ground). BTW, I didn't come up with this approach, Walter Jung used it in a high voltage regulator design in the 1980s/1990s.To solve the ground-reference issue, the 2nd design uses the optocoupler to control the pre-regulator's output (=linear regulator's input): when the voltage drop over the linear regulator goes up, the led in the optocoupler goes up, which opens up the phototransistor in the optocoupler, which brings down the pre-regulator's output (=linear regulator's input), thus reducing the voltage difference across the linear regulator.The pre-regulator can be implemented linearly (as shown, for example), or via a smps module. The linear solution requires extensive heatsinking: 20v in, 1.25out at 1.5amp -> ~30w on the pre-regulator, that's the practical limit of a to247 package with good heatsink. And more if you intend to use LT1083 as the linear regulator.Fortunately, if you use a smps (those $1 ones from ebay for example), they are good for 3amp max, 80%+ efficiency, so minimum heat dissipation even at full load.Hope it helps.

author: dannyf
author_rank: Super Contributor
timestamp: January 30, 2015, 05:09:13 pm
content: Note: I used a 20v6amp laptop power supply for my build.If you get one of those variable 24v/36v/48v smps supply, you can build a pretty powerful power supply without spending a fortune.

author: Alex30
author_rank: Regular Contributor
timestamp: January 31, 2015, 02:51:51 am
content: Quote from: dannyf on January 30, 2015, 05:07:43 pmI understood all that except this bit. The smps's output ground is referenced to supply ground aswell isn't it? When you say the led's ground, do you mean the anode? I really don't see the problem with the first design you had before the optocoupler. Do those ebay smps modules create a virtual ground at the output or something?

author: dannyf
author_rank: Super Contributor
timestamp: January 31, 2015, 01:48:56 pm
content: In the first pre-regulator, the gate of the mosfet sits at Vout + Vzener, so that its gate goes up and down with the output, maintaining a constant voltage drop over the linear regulator.That's not doable for a typical ebay smps module - but is doable if you were to design your own.Thus, a different approach has to be taken to float the gate of the pre-regulator while the pre-regulator is referenced to ground.

author: Kalvin
author_rank: Super Contributor
timestamp: January 31, 2015, 02:03:51 pm
content: Quote from: dannyf on January 31, 2015, 01:48:56 pmHow about using the opto-coupler's led across the linear regulator which will adjust the smps's output voltage with the opto-coupler's transistor connected to smps's feedback loop? As the voltage across the linear regulator increases, the opto-coupler's led start emitting, and the opto-coupler's transistor start conducting which will decrease the smps's output voltage, keeping the constant voltage across the linear regulator. Even a PNP transistor connected across the top FB resistor with the base connected to linear regulator's output through a zener or a LED might work?

author: dannyf
author_rank: Super Contributor
timestamp: January 31, 2015, 02:53:58 pm
content: QuoteYes, that is the way intended.The phototransistor of the opto-coupler would be on the upper arm of the divider feedback so as the voltage drop over the linear regulator goes up, the smps's output would go down.Kind of opposite, connection-wise, to what we have now, with a linear pre-regulator but the same principle.