First Project: Comparator Based Power Supply - Page 1
Forum section: electronics / projects

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 12:44:58 am
content: As my first non-repair project I want to make a relatively simple (and hopefully efficient) adjustable power supply. I've decided to go with a semi-switching power supply that uses an op-amp to run the MOSFET. This design in theory would make it easy for myself to produce simple power supplies for old laptops. I only have a few questions:There is a huge power spike at the start of the simulations I've ran. What would the best way to mitigate/remove this?Any good pages for safe circuit designs? I have some common sense but if I ever want to run the thing off mains I'd prefer not to blow up in the process.What is the best way to determine the inductor and capacitor values? Currently I've just been using common plastic capacitor values(.1-10?F) and a lower inductor value(10-100nH) to decrease voltage ripple, but I doubt those values will work in real lifeThanks in advance for the help/criticism in the replies. The simplified schematic is in the attachments

author: ZeTeX
author_rank: Frequent Contributor
timestamp: June 30, 2017, 01:37:47 am
content: Are you just trying to make lab power supply? Do you want current limting? (If a certain current is increased above a set point you choose, the voltage will drop untill the current is what you set)Sent from my Nexus 5X using Tapatalk

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 02:29:56 am
content: Quote from: ZeTeX on June 30, 2017, 01:37:47 amYes, and depending on how well it works use it for other designsQuote from: ZeTeX on June 30, 2017, 01:37:47 amI guess it wouldn't be that hard; measure the voltage drop across a resistor and cut the MOSFET if the drop's too high. It would produce a lot of heat though, making the whole thing in general pretty inefficient. Not even to mention the average power resistor's price.If anything I'll more-than-likely go with some form of fuse (preferably resettable)

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 04:01:04 am
content: As for the spikes I'll just do a timed bleed-off. Wasting a bit of energy but I can't get around it too easily

author: Kleinstein
author_rank: Super Contributor
timestamp: June 30, 2017, 08:53:18 am
content: MOSFETs are a good choice for a switched mode supply. But than it does not make sense to use OPs - there are specialized chips to build a SMPS. A switched mode supply is not that easy - especially if mains connected. For a beginner one should stay away from mains because of the dangers, even if it is only 115 V in the US. Mains levels usually requires a suitable training. There is not much sense to build a supply for a laptop (except maybe a converter from 12 V to around 19 V to run a laptop from car power.It is more like an old laptop supply could be a starting point to build simple / cheap lab-supply and don't have to care much about the mains side.For a lab supply with linear regulation, OPs are good and easy to use, but MOSFETs are generally not such a good choice. Especially modern types are build for switching and not that suitable for a linear operation with high power loss. So for a linear lab supply normal transistors (BJT) are usually the better choice.

author: ZeTeX
author_rank: Frequent Contributor
timestamp: June 30, 2017, 09:47:47 am
content: https://www.eevblog.com/forum/projects/replacing-parts-from-an-aged-general-purpose-op-amp-psu-schematic-(ti-snoa857)*/msg1245289/?topicseen#msg1245289

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 04:14:47 pm
content: Quote from: Kleinstein on June 30, 2017, 08:53:18 amWhile trying to gather ideas for the design I found a few IC's that would do the job for me. But it's kinda boring when everything's just given to you, so I really don't wish to use an IC for everything.As for mains I agree with you there, I am kinda lacking when it comes to mains experience. Luckily I do have a few transformers salvaged from old equipment I could use; stepping it down to ~36v would make it safer to testQuote from: Kleinstein on June 30, 2017, 08:53:18 amEven if I had a laptop supply I didn't use, it would be far less suitable then an ATX.Quote from: Kleinstein on June 30, 2017, 08:53:18 amWhy wouldn't they be? They would stay open until the op-amp pulled it down due to input capacitance (at least with the crappy MOSFET's I've used in the past), and so long as the MOSFET switches faster than the OP-AMP it sounds like a good plan. It would work almost like a switching power supply but not quite.

author: mikerj
author_rank: Super Contributor
timestamp: June 30, 2017, 04:41:24 pm
content: Quote from: Gip-Gip on June 30, 2017, 04:14:47 pmI'm still not quite sure what you are trying to achieve, your circuits don't look like they'd do very much. You say you want to make a semi-switching supply, do you mean a switching (tracking) pre-regulator followed by a linear regulator? If not what is a semi-switching supply?

author: ZeTeX
author_rank: Frequent Contributor
timestamp: June 30, 2017, 06:08:28 pm
content: Quote from: Gip-Gip on June 30, 2017, 04:14:47 pmToday mosfets are optimized for switching, not linear stuff, it would be harder and expensive to find a suitable MOSFET compare to BJT because most of the companies don't specify real SOA curve.Also, MOSFETs are more fragile and require more protection, there are no advantges to them over BJT expect that they might be a little bit faster.

author: SKHILLBILLYSlures
author_rank: Regular Contributor
timestamp: June 30, 2017, 06:28:58 pm
content: http://everycircuit.com/circuit/4738162763235328Try this circuit with a buck converter and and a boost converter

author: SKHILLBILLYSlures
author_rank: Regular Contributor
timestamp: June 30, 2017, 06:35:12 pm
content: I meant to add that it would work with a smps for LEDs that you can purchase on Amazon that plugs into mains it's case is grounded the circuit is a way to simulate a SMPS with a WIDE voltage and current limiting range it's a great way to play with voltage and current without touching mains

author: Kleinstein
author_rank: Super Contributor
timestamp: June 30, 2017, 06:51:37 pm
content: There is no good way for an intermediate between a switched mode supply and a linear supply. Once the control of the MOSFET gets slow, the efficiency relatively fast approaches that of a linear supply. OPs are usually too slow control MOSFETs in a SMPS. Switched mode and linear operation are so different, that it really does not make sense to somehow find something in between. Even with a suitable SMPS chip, it is not that easy to build a SMPS - it is possible, but not that much learning from this. A linear supply is the easier way - so this is usually the first one to try.As a linear supply is only going down in voltage, it might be more interesting to start with a 19 V laptop supply than with a 12 V ATX. For an initial project very high currents / high power are usually not a good idea. So even 2 A from a weak laptop supply are usually enough.

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 08:08:35 pm
content: Quote from: mikerj on June 30, 2017, 04:41:24 pmQuote from: ZeTeX on June 30, 2017, 06:08:28 pmHere's my basic idea:The charge builds up in the capacitor/inductor until the point given by the op-amp. The op-amp then cuts the MOSFET until the voltage goes back down. This is in essence a switch-mode power supply, but the frequency is based on the op-amp's response time (and in some ways, the load's current draw)The reason I choose a MOSFET is because it will only turn off when it is grounded, and the only time it will be grounded will be when the voltage is above the reference

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 08:30:48 pm
content: The more I think about it the more I realize the MOSFET's capacitance would have to be REALLY low, so failure on my partI still want to give this a shot so I have a somewhat simpler concept in mind; Use two op-amps to flip-flop a MOSFET on and off. It sounds like an idea to me, but I've already proven myself to kinda push out ideas without too much thought.

author: Gip-Gip
author_rank: Contributor
timestamp: June 30, 2017, 09:27:08 pm
content: I know you guys are probably tired of me pulling ideas out of the corner of my mind, so I'll try to get the thing put together on a perfboard sometime within the next two weeks. After that's complete I'll get back to everyone on whether it works and if so how efficient it is.Here's a more/less ugly concept schematic, just replace the 10nH with a 100uH and the 10uF with a 1000uF. It works the way I want in the sims I've put it through, so it should work IRL

author: mikerj
author_rank: Super Contributor
timestamp: June 30, 2017, 11:11:54 pm
content: Quote from: Gip-Gip on June 30, 2017, 08:08:35 pmOk, I remember there was a bench supply project in one of the electronic magazines many years ago (possibly Practical Electronics) that did something similar, basically a low frequency switching pre-regulator.It would be quite easy to use an SCR to do this with relatively few components, no op-amps would be needed.

author: ZeTeX
author_rank: Frequent Contributor
timestamp: July 01, 2017, 01:24:51 am
content: Quote from: mikerj on June 30, 2017, 11:11:54 pmhttps://www.eevblog.com/forum/projects/very-low-noise-preregulator-for-benchtop-power-supply/

author: rstofer
author_rank: Super Contributor
timestamp: July 01, 2017, 05:19:52 pm
content: If you Google for 'op amp based power supply', you will get 1,170,000 hits.Here's one:http://www.play-hookey.com/analog_experiments/preparations/ps_op_amp_control.html

author: Gip-Gip
author_rank: Contributor
timestamp: July 01, 2017, 07:19:11 pm
content: Quote from: rstofer on July 01, 2017, 05:19:52 pmFor this project I did want something of my own design, so I didn't think to google it.I should also point out that's a design for a linear power supply, which is really inefficient and would burn out if I ever put it on line voltage

author: Kleinstein
author_rank: Super Contributor
timestamp: July 01, 2017, 07:38:12 pm
content: Running of mains needs isolation. So neither a simple linear nor a buck converter would be an option. It would need a more complicated isolated converter (like a flyback).A mains powered SMPS is definitely not a project for a beginner - so forget it.If you really want to build a SMPS without using a suitable chip, I would consider at least something like an NE555 or a comparator. But without a specialized chip a switched mode regulator is considerably more effort than a linear regulator.

author: ZeTeX
author_rank: Frequent Contributor
timestamp: July 01, 2017, 07:47:18 pm
content: if are worried about the power dissipation, use apre-regulator.you could use for example LT1074 as a pre-regulator but because of the high frequency the supply might be a little bit noisy (not sure how much) but very small without a big heatsink and large components.you could use a low freq pre-regulator like the one Blackdog showed in the thread I posted above.you could modify a transformer and add some taps, this will be the best performance. and then you just switch them using a MOSFET or something between the taps (1V 4V 7V 10V 13V 16V 19V...)

author: Gip-Gip
author_rank: Contributor
timestamp: July 01, 2017, 08:53:44 pm
content: Quote from: Kleinstein on July 01, 2017, 07:38:12 pmStep-down transformers will do the trick for now.Quote from: Kleinstein on July 01, 2017, 07:38:12 pmI've been using an op-amp in place of a comparator the entire timeI was trying to make a comparator with two op-amps but I could've just used a comparator by itself. Rookie mistakeHopefully now my goal is a little clearer

author: mikerj
author_rank: Super Contributor
timestamp: July 01, 2017, 09:03:02 pm
content: Quote from: ZeTeX on July 01, 2017, 01:24:51 amYep, that looks like the one I remember, thanks!