EEVblog #90 - Linear and LDO regulators and Switch Mode Power Supply Tutorial - Page 1
Forum section: electronics / general

author: migsantiago
author_rank: Frequent Contributor
timestamp: May 29, 2010, 02:54:23 pm
content: HiI just saw this tutorial and there's something I didn't understand. In the step-down regulator, how does the diode provide current from GND? There's no negative source, how come the current can flow in that way?Another question, in the linear regulator an ampop is shown configured as a comparator. If REF is greater that the voltage at the resistor, the ampop will output a Vss voltage (Vss as in +V supply). If the voltage at the resistor is greater than REF, the ampop will output 0V. How can the NPN transistor be regulated if there are only 2 different voltages that the ampop can output?Thanks!!

author: jahonen
author_rank: Super Contributor
timestamp: May 29, 2010, 03:16:15 pm
content: In the step-down regulator, it is the inductor which provides the continuous current when the switch is off. Current is continuous in the inductor. Of course, the current will slowly decay to zero. Diode just provides the path for the current. You can see that arrow in the diode schematic symbol is in the same direction than the current in the loop, pointing to the inductor.In linear regulator, opamp does not behave as a comparator, it "finds" linear operation point (assuming that loop is stable). Another way to say is that linear power supply is just error amplifier followed by high-current follower.Regards,Janne

author: s3c
author_rank: Contributor
timestamp: May 29, 2010, 03:50:05 pm
content: QuoteWhen the transistor switches off there is some energy stored in the inductor, this energy can't just dissipate and has to go somewhere, recall that an inductor tries to avoid changes in current so it will try and up the voltage till current can flow in the direction it was flowing in before the transistor turned off. This will create the needed voltage drop across the diode to put it in the forward active region and complete the loop.QuoteRecall that real op amps can't change their output instantaneously (look up slew rate), it would be more accurate to say that when REF is greater than the feedback voltage it increases it's output and decreases otherwise, this is a continual process that stabilizes around the output point that gives equilibrium.

author: s3c
author_rank: Contributor
timestamp: May 29, 2010, 03:52:08 pm
content: I'm new to switching regulators so could anyone comment on the frequency and waveform shape used by the oscillator? I'm assuming the frequency has something to do with the LC circuit?

author: migsantiago
author_rank: Frequent Contributor
timestamp: May 29, 2010, 04:01:18 pm
content: Inductors have always been a mistery to me. I quite don't understand how they can store energy just by being a single cable assembled into a loop. But science is science and I believe it heheThanks Janne and S3C for your explanations!

author: jahonen
author_rank: Super Contributor
timestamp: May 29, 2010, 05:28:07 pm
content: Energy storage in the inductor is just like in the capacitor, but current and voltage change roles. Capacitor stores E=½CU^2 in electric field and inductor E=½LI^2 in the magnetic field, so no difference thereEnergy stored in the magnetic field can be huge for given inductance if you have enough current. If you know the LHC, its main magnets used to bend the beam around the ring store about 11 gigajoules of energy in the magnetic field at maximum current, and magnets are nothing but suitably arranged inductors (superconducting wire but nevertheless inductors). To put that in perspective, the house where I live, consumes in winter coldest time about 100 kWh of electricity per day (direct electric heating). 11 gigajoules could supply the house for 30 days! That would make a nice batteryBut back to the subject, my favorite 1 A switch-mode step-down regulator has beenNational LM2675. It is really easy to use and works quite stable even with poor layouts. If you look inside the datasheet, you'll find quite comprehensive block diagram. There are several ways to do the modulation. One which Dave represented in his blog episode is a burst mode, where fixed duty cycle oscillator is switched on and off. Other types are available, like hysteretic controllers or fixed-frequency PWM. The LM2675 uses fixed-frequency PWM-modulation. Burst mode yields better efficiency at low loads, but has higher output ripple. There are also ones which change modes according to the load.Regards,Janne

author: migsantiago
author_rank: Frequent Contributor
timestamp: May 29, 2010, 06:26:06 pm
content: Capacitor - Electric field.Inductor - Magnetic field.Got it!!Thanks again Janne and Shafri.I have used the TL2575HV-05 to reduce a 60V supply to a 5V supply and it also works great. It uses a 330uH inductor.http://mexico.newark.com/texas-instruments/tl2575hv-05in/dc-dc-converter-ic/dp/27M1040?Ntt=tl2575hv-05in

author: Simon
author_rank: Unknown
timestamp: May 29, 2010, 06:37:47 pm
content: I'm quite interested in the LDO regs as I'm planning on using some, how does temperature affect stability ?

author: jahonen
author_rank: Super Contributor
timestamp: May 29, 2010, 06:55:51 pm
content: Quote from: Simon on May 29, 2010, 06:37:47 pmThat is usually via capacitor capacitance/ESR change via temperature so if you use decent caps, that should not be a problem. If you use ceramic caps, then do not use Y5V ceramics. That has terrible voltage and temperature dependency of the capacitance. Y5V looses something like 80% of specified capacitance when used at rated voltage. However, not all LDO regulators accept ceramic capacitors, for example otherwise nice LP2951 does not like low ESR caps at all.Electrolytic capacitors have tendency to have rising ESR when temperature drops. That might in some cases lead to instability. Using "high-ESR" tantalums might work in such cases, if you can use them.Regards,Janne

author: Simon
author_rank: Unknown
timestamp: May 29, 2010, 07:00:25 pm
content: well I'm working with high temps

author: jahonen
author_rank: Super Contributor
timestamp: May 29, 2010, 07:04:19 pm
content: Quote from: Simon on May 29, 2010, 07:00:25 pmCan you specify the temp range you need? Ceramic capacitors are recommended anyway if you want longevity.Regards,Janne

author: Simon
author_rank: Unknown
timestamp: May 29, 2010, 07:07:08 pm
content: well not sure but maybe 70C

author: allanw
author_rank: Frequent Contributor
timestamp: May 29, 2010, 07:09:30 pm
content: Thanks for this episode. I've always wanted to know why one wouldn't just always use a LDO. It was difficult for me to find disadvantages laid out clearly.

author: EEVblog
author_rank: Unknown
timestamp: May 29, 2010, 10:34:22 pm
content: BTW, I forgot to mention in this tutorial that the displayed technique for the SMPS control is just one example of many. There are many other techniques that can be used for the gate control like fixed frequency PWM, and more exotic techniques and combinations. And that's just for the buck!But I wanted to KISS and dumb it down.Dave.

author: mikeselectricstuff
author_rank: Super Contributor
timestamp: May 29, 2010, 11:26:24 pm
content: A quick tip on inductors for SM regs.The inductance is really not critical in most cases. DC resistance is often at least as important as it affects efficiency.The inductance value is typically a tradeoff betwen two things :1) The inductance needs to be high enough to not have any saturation issues at the lowest operating frequency.2) For a given physical size, a lower inductance value will have a lower DC resistance and hence lower losses.Datasheets often quote 'odd' values like 68uH, but you will usually find that availability & choice of parts is better for E3 series values (10,22,47,100 etc,).Rounding up the datasheet/calculated value up to the nearest E3 value will rarely impact efficiency too much and usually gives a wider choice of parts.

author: Simon
author_rank: Unknown
timestamp: May 30, 2010, 05:47:47 am
content: Dave what effect does a variable frequency have on the inductor and efficiency ? I think the main issue for people is choosing the values for the inductor

author: EEVblog
author_rank: Unknown
timestamp: May 30, 2010, 08:15:01 am
content: Quote from: Simon on May 30, 2010, 05:47:47 amThere are usually far too many variables to give a clear cut answer to those sorts of questions when it comes to switchmodes. The golden rule is follow the datasheet and app notes to get a ballpark value and then test'n'tweak.As a general rule, the higher the switching frequency the smaller the value and size of the inductor (which is usually cheaper), but the higher the switching losses and greater the demand on the output caps. It's a never-ending battle.Dave.

author: mikeselectricstuff
author_rank: Super Contributor
timestamp: May 30, 2010, 09:55:48 am
content: Quote from: EEVblog on May 30, 2010, 08:15:01 am..or lower DC Resistance for a given package sizeQuoteAlthough as you get into really high frequencies, ceramic output caps become very viable, reducing size and cost significantly over electrolytics or tants.There are many switchers up in the >1MHz range these days, some up to 4MHz, with pretty decent efficiencies. Particularly where you're tight on space, the lower inductor DCR at lower inductance values will at least partially compensate for higher switching losses at higher frequencies. High switching frequency also gives faster transient response.A nice example is the Allegro A4403 : 9-46Vin, 3A out, 2x10uf ceramic output caps and only costs about GBP1 at 100x.

author: TheWelly888
author_rank: Frequent Contributor
timestamp: May 30, 2010, 10:36:52 am
content: Oh Gawd!SMPSUs! In the mid 1990s, I was unemployed and did 6 month's unpaid work experience for a firm specialising in bespoke PSU manufacturing. My job was to test them before they left the factory and fault find any customer returns.The firm ( since gone under and the factory site now a legal eagle's nest ) had contracts to supply cable TV companies with PSUs for distribution boxes ( at the time all the UK's streets were being trenched for cable TV! ) and high current PSUs for overhead projector ( OHP ) lamps among other things.Even though I had circuit diagrams it was a mystery to me how they worked but I was usually able to diagnose some faults and fix them. One design was absolute shite, the PWM timing capacitors were electrolytic!!! This model was overwhelming sent back to us for repair and I had to drill out the rivets to open the case, replace ALL the electrolytics and cross fingers, test them uncased then once working use the riveting machine - it got to the point I knew the part numbers by heart!The OHP PSUs were interesting, they had no output smoothing capacitors or rectification at all - I think they only had inductors on the output and the waveform was a kind of amplitude modulated rectangular waveform. I think they were 12V 10A output. The size of the units were maybe 100mm by 160mm in area. A separate board with fuse and rectifier was connected to provide DC to the cooling fan and boy, the number of times the fuses were blown thanks to clumsy assembly at the OHP's factory! It was a boring job checking those crappy little boards.Having said all that, the experience I gained in that factory was useful even if it didn't lead to a paid job there.

author: Simon
author_rank: Unknown
timestamp: May 30, 2010, 11:20:39 am
content: Well i have heard on inductor only solutions but for low power to run high output leds, I expect that it is a good tradeoff if you can afford a not so stable output ?

author: logictom
author_rank: Unknown
timestamp: May 30, 2010, 12:49:40 pm
content: Great video as usual!Both designs use a precision voltage references, what is used as a reference and how does it work?After this video I thought I would grab some parts and have a play around, are there any recommended bog standard parts like the equivalent of the LM305/317?

author: Simon
author_rank: Unknown
timestamp: May 30, 2010, 12:56:34 pm
content: you can get precision voltage reference chips try looking on your usual suppliers website.

author: s3c
author_rank: Contributor
timestamp: May 30, 2010, 01:23:22 pm
content: Can anyone point me to a good reference for how voltage references work, using a Zener or normal diode doesn't give results nearly as good as stand alone units which is to be expected but why? How do they work then?

author: Simon
author_rank: Unknown
timestamp: May 30, 2010, 05:10:52 pm
content: As i said above go to your usual suppliers website and see what they have in stock. they will have a range of parts, zeners are not a great reference because they drift with temperature and load (which will vary with input voltage)

author: s3c
author_rank: Contributor
timestamp: May 30, 2010, 05:55:49 pm
content: I'm not particularly interested in getting one that works, I'm interested in finding out how it works, the web seems to be a bit lacking on that front.

author: jimmc
author_rank: Frequent Contributor
timestamp: May 30, 2010, 06:28:01 pm
content: Quote from: s3c on May 30, 2010, 01:23:22 pmConsult this guy!http://www.national.com/rap/Horrible/czar.htmlSeehttp://www.national.com/rap/Application/0,1570,24,00.htmlfor a very good explanation of the intricacies of designing bandgap references.Jim

author: s3c
author_rank: Contributor
timestamp: May 30, 2010, 09:49:53 pm
content: Thanks Jim, exactly what I was looking for.

author: RayJones
author_rank: Frequent Contributor
timestamp: May 31, 2010, 09:01:54 am
content: With regards to the lack of stability of the LDO regulator, it occurred to me whilst watching the Vblog that an emitter follower would have a very low source impedance to the load.The collector based output of the LDO version however would be somewhat higher in impedance.Perhaps this leads to this configuration being more likely to be unstable (more load sensitive)?

author: KTP
author_rank: Frequent Contributor
timestamp: June 02, 2010, 01:58:29 pm
content: I don't know if anyone pointed out to the OP that even though current cannot change instantaneously in an inductor, voltage can. When the transistor switches off, the voltage across the inductor instantly flips polarity across it such that the diode's cathode (negative terminal) is low enough such that current can flow through the diode (so it would be somewhere between -0.6V and -1.0V depending on the diode type and current).hey so interestingly, I had found this simple 3 transistor switching power supply application note a few days ago. It is actually a current regulator but still very nice and simple:http://www.nxp.com/documents/application_note/AN10739.pdf

author: Pyr0Beast
author_rank: Contributor
timestamp: June 26, 2010, 02:46:08 pm
content: Quote from: KTP on June 02, 2010, 01:58:29 pmWooow. That is really a nice find. I just love how you can do switchers with discrete components

author: Simon
author_rank: Unknown
timestamp: June 26, 2010, 03:50:51 pm
content: anything can be done in descrete components, IC's only make it simpler and cheaper and faster to implement, you know we had computers long before IC's but instead of an IC you had a room or more full of panels full of relays or valves

author: NiHaoMike
author_rank: Super Contributor
timestamp: June 26, 2010, 07:18:36 pm
content: Simple switchers that only use a few discrete components are fun to design. I even built one that would "period skip" at low load to increase efficiency.

author: Simon
author_rank: Unknown
timestamp: June 26, 2010, 10:28:25 pm
content: I'd like to see a switcher that ajusts frequency to load but maybe that would have issues with inductor values, but then if your switcher leaves a period dead that amounts to the same thing ? although a fixed frequency

author: NiHaoMike
author_rank: Super Contributor
timestamp: June 27, 2010, 02:58:35 am
content: Period skipping will not cause the inductor to saturate. The basic idea is that in a power supply that never period skips, the pulses become narrower with decreasing load. At some point, the pulse has to be so narrow that a very significant amount of it is turning on and off the transistors. Efficiency drops as a result.Now imagine if every other period is skipped, meaning that the output pulse is suppressed. Now the pulses are twice as large as before and the effective operating frequency halved, reducing losses. The pulses are still narrower than when the power supply is operating at full load, so inductor saturation does not occur. The low output current also means that the filter capacitors will be able to cope with the low frequency.In reality, a 1:2 skip ratio is very low. My discrete design (2 transistors, but I forgot the details) had a skip ratio on the order of 1:1000, since it operates at about 25kHz and slows down to a pulse a few times a second at no load (only the load of the voltage sense circuit). It only pulls a few mW from the rectified AC line in that condition, not bad for a simple circuit! (If designs like that were used in the standby circuit of modern electronics, standby loss would be a lot less significant!)

author: Simon
author_rank: Unknown
timestamp: June 27, 2010, 06:04:48 am
content: sounds like a very good design

author: Pyr0Beast
author_rank: Contributor
timestamp: June 27, 2010, 12:17:07 pm
content: Indeed it does