Electronics-Related.com
Forums

LM317 compensation

Started by John Larkin February 15, 2018
On 19 Feb 2018 06:30:05 -0800, Winfield Hill
<hill@rowland.harvard.edu> wrote:

>John Larkin wrote... >> >> LM317's like some ESR in their output capacitors. >> I don't want any electrolytic or tantalum caps in >> my new thing, just ceramics, and the sim sure rings: > > I hate the way LTSpice hides added parasitic > elements, if any, to the passive components. > It's better to manually add these explicitly, > so others (and yourself) can see them, and > evaluate reasonableness of the chosen values. > > John, please be aware that ceramic capacitors > certainly do not have zero esr. I measured > 1210-size Murata, Samsung and Yageo caps, with > an HP 4192A LCR meter, and got values between > 2.5 and 60 m-ohms for 47uF 16V caps at 5V bias, > and 9 to 30 m-ohms for 10uF 35V caps at 15V. > As expected for MLCC, the capacitance dropped > severely with voltage, but esr didn't change. > > These resistances help to stabilize regulators > of all types, but also defeat ideal filtering.
I'm expecting serious fast pulse loads, so I need to parallel a bunch of ceramic caps at the regulator output. The load pulse rate could be anything, so any ringing could explode. Adding the compensation parts is good insurance. Apparently physically bigger (like 1210) caps hold up better with voltage, and may have lower ESR, so I'll use the biggest caps I can reasonably fit. -- John Larkin Highland Technology, Inc trk jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
John Larkin wrote...
> >On 19 Feb 2018 06:30:05 -0800, Winfield Hill ><hill@rowland.harvard.edu> wrote: > >> John Larkin wrote... >>> >>> LM317's like some ESR in their output capacitors. >>> I don't want any electrolytic or tantalum caps in >>> my new thing, just ceramics, and the sim sure rings: >> >> I hate the way LTSpice hides added parasitic >> elements, if any, to the passive components. >> It's better to manually add these explicitly, >> so others (and yourself) can see them, and >> evaluate reasonableness of the chosen values. >> >> John, please be aware that ceramic capacitors >> certainly do not have zero esr. I measured >> 1210-size Murata, Samsung and Yageo caps, with >> an HP 4192A LCR meter, and got values between >> 2.5 and 60 m-ohms for 47uF 16V caps at 5V bias, >> and 9 to 30 m-ohms for 10uF 35V caps at 15V. >> As expected for MLCC, the capacitance dropped >> severely with voltage, but esr didn't change. >> >> These resistances help to stabilize regulators >> of all types, but also defeat ideal filtering. > > I'm expecting serious fast pulse loads, so I need to parallel > a bunch of ceramic caps at the regulator output. The load > pulse rate could be anything, so any ringing could explode. > Adding the compensation parts is good insurance. > > Apparently physically bigger (like 1210) caps hold up better > with voltage, and may have lower ESR, so I'll use the biggest > caps I can reasonably fit.
Yes, I'm simply saying, when doing SPICE modeling with MLCC caps, add some reasonable esr. Your LM317 exercises wold be more compelling if we knew the esr. Maybe with an array of big ceramic caps, it wouldn't matter much, but it's nice to see that parameter. -- Thanks, - Win
Phil Hobbs <pcdhSpamMeSenseless@electrooptical.net> wrote:
> On 02/16/2018 12:19 PM, Tim Williams wrote: >> <bloggs.fredbloggs.fred@gmail.com> wrote in message >> news:d4f2ca9f-ff53-44fd-8877-51c55e3b1f1c@googlegroups.com... >>> 317 needs no such ESR compensation. The ringing looks suspiciously >>> like excitation of the SRF of an output capacitor. Did your model give >>> it any ESL? And your solution merely reduces the shunt resistance by a >>> factor of 20x which probably has more to do with damping than anything >>> else. >>> >> >> The output has an inductive characteristic at higher frequencies.\xc2\xa0 It's >> stable as you can see, but that doesn't mean the impedance is great. >> > See e.g. the Errol Dietz (*) article at > > https://electrooptical.net/www/sed/ErrolDietzRegulatorNoisePeaks.pdf
That good little article just got squirreled away by me on my private website. Dietz more-or-less suggests that designers use a tantalum capacitor. And that's exactly what the wise guys did to the 7805 and 7812 on the PIC thermostat board that recently came under my purview. Another article that got squirreled away (IIRC) argues against the old "10uF and 0.1uF decoupling" rule-of-thumb. But, its exact location eludes me at present. :( You can blame it on my private website's perpetual reorg. But the darned thing won't elude me for long. Thank you, -- Don Kuenz, KB7RPU "To invent, you need a good imagination and a pile of junk" - Thomas Alva Edison
On Mon, 19 Feb 2018 00:07:02 -0500, legg <legg@nospam.magma.ca> wrote:

>On Thu, 15 Feb 2018 17:32:30 -0800, John Larkin ><jjlarkin@highlandtechnology.com> wrote: > >> >> >>LM317's like some ESR in their output capacitors. I don't want any >>electrolytic or tantalum caps in my new thing, just ceramics, and the >>sim sure rings: >> >>https://www.dropbox.com/s/11b3w42nsvpliki/317_nocomp.jpg?raw=1 >> >>But this fixes it: >> >>https://www.dropbox.com/s/9q80heyfbwh5frp/317_comp.jpg?raw=1 >> >>This ain't rocket science, but I haven't seen it done before. > >The original LM117 data sheet shows a 10uF elec cap on the adjustment >pin, with its effect illustrated in the typical performance plots. > >I don't know what the A version is intended to improve, but if you >vary from recommended decoupling, you're bound to see performance that >is non-optimal in some respect.
What, me break rules? I would never do a thing like that.
> >The fact that you're using ceramics simply by preference, may be the >only issue with this circuit. I don't know about the model, or what >you can expect from it, but you should probably suspect anything that >responds to 'tuning'. > >RL
I have a load that goes from 0 to 12 amps in under 100 ns. I need a bunch of ceramic caps to furnish that current without drooping much. The 317 rings like a bell in that circuit. The added damping parts clean that up beautifully. Actually, one 22nF cap from ADJ to ground works great. I don't want to use electrolytics for several reasons. -- John Larkin Highland Technology, Inc trk jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
Don Kuenz <g@crcomp.net> wrote:
> > Phil Hobbs <pcdhSpamMeSenseless@electrooptical.net> wrote: >> On 02/16/2018 12:19 PM, Tim Williams wrote: >>> <bloggs.fredbloggs.fred@gmail.com> wrote in message >>> news:d4f2ca9f-ff53-44fd-8877-51c55e3b1f1c@googlegroups.com... >>>> 317 needs no such ESR compensation. The ringing looks suspiciously >>>> like excitation of the SRF of an output capacitor. Did your model give >>>> it any ESL? And your solution merely reduces the shunt resistance by a >>>> factor of 20x which probably has more to do with damping than anything >>>> else. >>>> >>> >>> The output has an inductive characteristic at higher frequencies. It's >>> stable as you can see, but that doesn't mean the impedance is great. >>> >> See e.g. the Errol Dietz (*) article at >> >> https://electrooptical.net/www/sed/ErrolDietzRegulatorNoisePeaks.pdf > > That good little article just got squirreled away by me on my private > website. Dietz more-or-less suggests that designers use a tantalum > capacitor. And that's exactly what the wise guys did to the 7805 and > 7812 on the PIC thermostat board that recently came under my purview. > Another article that got squirreled away (IIRC) argues against the > old "10uF and 0.1uF decoupling" rule-of-thumb. But, its exact location > eludes me at present. :( > You can blame it on my private website's perpetual reorg. But the > darned thing won't elude me for long.
Oh yeah, it's all starting to come back to me now. :) There's an ancient _Radio Shack, Voltage Regulator Handbook, National Semiconductor_ (1977) on my shelf. Dietz is not mentioned as a contributor, so maybe he hadn't become prominent yet. The book's full of very old school big iron power supplies. Although it neglects to specifically mention tantalum capacitors in its "Capacitor Selection" sub-chapter it does note them on its typical applications circuit diagrams. This is a very interesting thread. The more my mind cogitates on it, the more interesting it becomes. ;) Thank you, -- Don Kuenz, KB7RPU "To invent, you need a good imagination and a pile of junk" - Thomas Alva Edison
John Larkin <jjlarkin@highlandtechnology.com> wrote:

> I have a load that goes from 0 to 12 amps in under 100 ns. I need a > bunch of ceramic caps to furnish that current without drooping much.
> The 317 rings like a bell in that circuit. The added damping parts > clean that up beautifully. Actually, one 22nF cap from ADJ to ground > works great.
> I don't want to use electrolytics for several reasons.
Is that 12 Amps, as in 12,000 mA? If so, the LM317 is only a 1.5 Amp device and won't handle 12 A. You can parallel a number of LM317's, such as in Fig. 22 of the datasheet at http://www.ti.com/lit/ds/symlink/lm317.pdf An alternative is to use an external pass transistor with a PNP driver, such as in Fig. 23 of the same datasheet. In either case, the circuit is different from the single LM317 you are using to show ringing. You need to add the external circuits to show the response. In addition, the circuit you show at https://www.dropbox.com/s/11b3w42nsvpliki/317_nocomp.jpg?raw=1 switches from 30mA to 200mA using a pulse current source. The current source may be giving misleading results because it is a high impedance. You may need to use a switched resistive load to provide some damping. This may have a significant effect on the ringing. Note the load transient response in Figs 3 and 4 of the TI datasheet show a considerably different response than your model. Other manufacturer's versions of the LM317 may have a considerably different response. As in all modeling exercises, the results should be verified in actual hardware.
On Wed, 21 Feb 2018 00:47:56 GMT, Steve Wilson <no@spam.com> wrote:

>John Larkin <jjlarkin@highlandtechnology.com> wrote: > >> I have a load that goes from 0 to 12 amps in under 100 ns. I need a >> bunch of ceramic caps to furnish that current without drooping much. > >> The 317 rings like a bell in that circuit. The added damping parts >> clean that up beautifully. Actually, one 22nF cap from ADJ to ground >> works great. > >> I don't want to use electrolytics for several reasons. > >Is that 12 Amps, as in 12,000 mA?
Yes.
> >If so, the LM317 is only a 1.5 Amp device and won't handle 12 A. You can >parallel a number of LM317's, such as in Fig. 22 of the datasheet at > >http://www.ti.com/lit/ds/symlink/lm317.pdf > >An alternative is to use an external pass transistor with a PNP driver, >such as in Fig. 23 of the same datasheet. > >In either case, the circuit is different from the single LM317 you are >using to show ringing. You need to add the external circuits to show the >response.
The load is pulsed at a fairly low duty cycle, so the average current is a few hundred mA. The ceramic caps provide the peak current and the 317 recharges them.
> >In addition, the circuit you show at > >https://www.dropbox.com/s/11b3w42nsvpliki/317_nocomp.jpg?raw=1 > >switches from 30mA to 200mA using a pulse current source. The current >source may be giving misleading results because it is a high impedance.
Amps are amps. The load step demonstrates the ringing, and the fix for the ringing.
> >You may need to use a switched resistive load to provide some damping. This >may have a significant effect on the ringing. > >Note the load transient response in Figs 3 and 4 of the TI datasheet show a >considerably different response than your model.
They probably use caps with a lot of ESR. And the models differ too.
> >Other manufacturer's versions of the LM317 may have a considerably >different response.
Probably.
> >As in all modeling exercises, the results should be verified in actual >hardware.
Sure, we intend to actually build it. -- John Larkin Highland Technology, Inc trk jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
John Larkin <jjlarkin@highlandtechnology.com> wrote:

> On Wed, 21 Feb 2018 00:47:56 GMT, Steve Wilson <no@spam.com> wrote: > >>John Larkin <jjlarkin@highlandtechnology.com> wrote:
>>If so, the LM317 is only a 1.5 Amp device and won't handle 12 A. You can >>parallel a number of LM317's, such as in Fig. 22 of the datasheet at
>>http://www.ti.com/lit/ds/symlink/lm317.pdf
>>An alternative is to use an external pass transistor with a PNP driver, >>such as in Fig. 23 of the same datasheet.
>>In either case, the circuit is different from the single LM317 you are >>using to show ringing. You need to add the external circuits to show the >>response.
> The load is pulsed at a fairly low duty cycle, so the average current > is a few hundred mA. The ceramic caps provide the peak current and the > 317 recharges them.
>>In addition, the circuit you show at
>>https://www.dropbox.com/s/11b3w42nsvpliki/317_nocomp.jpg?raw=1
>>switches from 30mA to 200mA using a pulse current source. The current >>source may be giving misleading results because it is a high impedance.
> Amps are amps. The load step demonstrates the ringing, and the fix for > the ringing.
Your simulation shows considerably different ringing between current rise and fall. So the currents matter. You need to model the actual currents you are using. I suspect the idle current may be much lower, and the actual charge current may be higher. I'd be happier to see the results with a pulsed 100ns 12 Amp load. But I'd get a more recent model. See the TI PSice model below.
>>You may need to use a switched resistive load to provide some damping. >>This may have a significant effect on the ringing.
>>Note the load transient response in Figs 3 and 4 of the TI datasheet >>show a considerably different response than your model.
> They probably use caps with a lot of ESR. And the models differ too.
You need to model the ESR. Say the caps need to hold 0.1V drop for 100ns. The required capacitance is i = c dv/dt i dt = c dv c = i * dt / dv = 12 * 1e-7 / 0.1 = 12 uf You can now calculate the max ESR for 0.1V drop: R = E / I = 0.1 / 12 = 8.33 milliohms A bunch of parallel caps should do. But you need to specify the ESR in your model.
>>Other manufacturer's versions of the LM317 may have a considerably >>different response.
> Probably.
You can get the TI Unencrypted PSpice LM317 Model at https://webench.ti.com/wb5/download/TI_Models_201802200508_00815.zip Other TI Spice models are at http://www.ti.com/spicerack
>>As in all modeling exercises, the results should be verified in actual >>hardware.
> Sure, we intend to actually build it.
Let us know the results.
On Wed, 21 Feb 2018 01:54:05 GMT, Steve Wilson <no@spam.com> wrote:

>John Larkin <jjlarkin@highlandtechnology.com> wrote: > >> On Wed, 21 Feb 2018 00:47:56 GMT, Steve Wilson <no@spam.com> wrote: >> >>>John Larkin <jjlarkin@highlandtechnology.com> wrote: > >>>If so, the LM317 is only a 1.5 Amp device and won't handle 12 A. You can >>>parallel a number of LM317's, such as in Fig. 22 of the datasheet at > >>>http://www.ti.com/lit/ds/symlink/lm317.pdf > >>>An alternative is to use an external pass transistor with a PNP driver, >>>such as in Fig. 23 of the same datasheet. > >>>In either case, the circuit is different from the single LM317 you are >>>using to show ringing. You need to add the external circuits to show the >>>response. > >> The load is pulsed at a fairly low duty cycle, so the average current >> is a few hundred mA. The ceramic caps provide the peak current and the >> 317 recharges them. > >>>In addition, the circuit you show at > >>>https://www.dropbox.com/s/11b3w42nsvpliki/317_nocomp.jpg?raw=1 > >>>switches from 30mA to 200mA using a pulse current source. The current >>>source may be giving misleading results because it is a high impedance. > >> Amps are amps. The load step demonstrates the ringing, and the fix for >> the ringing. > >Your simulation shows considerably different ringing between current rise >and fall. So the currents matter.
Sure, the output transistor emitter has a very different impedance from 30 to 200 mA. So the pole from that impedance into the ceramic caps is different for the two currents.
> >You need to model the actual currents you are using. I suspect the idle >current may be much lower, and the actual charge current may be higher. > >I'd be happier to see the results with a pulsed 100ns 12 Amp load. But I'd >get a more recent model. See the TI PSice model below. > >>>You may need to use a switched resistive load to provide some damping. >>>This may have a significant effect on the ringing. > >>>Note the load transient response in Figs 3 and 4 of the TI datasheet >>>show a considerably different response than your model. > >> They probably use caps with a lot of ESR. And the models differ too. > >You need to model the ESR. > >Say the caps need to hold 0.1V drop for 100ns. The required capacitance is > > i = c dv/dt > i dt = c dv > c = i * dt / dv > = 12 * 1e-7 / 0.1 > = 12 uf > >You can now calculate the max ESR for 0.1V drop: > > R = E / I > = 0.1 / 12 > = 8.33 milliohms > >A bunch of parallel caps should do. But you need to specify the ESR in your >model. > >>>Other manufacturer's versions of the LM317 may have a considerably >>>different response. > >> Probably. > >You can get the TI Unencrypted PSpice LM317 Model at > >https://webench.ti.com/wb5/download/TI_Models_201802200508_00815.zip > >Other TI Spice models are at > >http://www.ti.com/spicerack > >>>As in all modeling exercises, the results should be verified in actual >>>hardware. > >> Sure, we intend to actually build it. > >Let us know the results. >
-- John Larkin Highland Technology, Inc trk jlarkin att highlandtechnology dott com http://www.highlandtechnology.com
John Larkin <jjlarkin@highlandtechnology.com> wrote:

> On Wed, 21 Feb 2018 01:54:05 GMT, Steve Wilson <no@spam.com> wrote: >>> Amps are amps. The load step demonstrates the ringing, and the fix for >>> the ringing.
>>Your simulation shows considerably different ringing between current >>rise and fall. So the currents matter.
> Sure, the output transistor emitter has a very different impedance > from 30 to 200 mA. So the pole from that impedance into the ceramic > caps is different for the two currents.
>>You need to model the actual currents you are using. I suspect the idle >>current may be much lower, and the actual charge current may be higher.
>>I'd be happier to see the results with a pulsed 100ns 12 Amp load.
I did it for you. The compensation cap is critical and very different from your result. See below.
>>>>You may need to use a switched resistive load to provide some damping. >>>>This may have a significant effect on the ringing.
>>>>Note the load transient response in Figs 3 and 4 of the TI datasheet >>>>show a considerably different response than your model.
>>> They probably use caps with a lot of ESR. And the models differ too.
>>You need to model the ESR.
>>Say the caps need to hold 0.1V drop for 100ns. The required capacitance >>is
>> i = c dv/dt >> i dt = c dv >> c = i * dt / dv >> = 12 * 1e-7 / 0.1 >> = 12 uf
>>You can now calculate the max ESR for 0.1V drop:
>> R = E / I >> = 0.1 / 12 >> = 8.33 milliohms
>>A bunch of parallel caps should do. But you need to specify the ESR in >>your model.
Version 4 SHEET 1 1184 680 WIRE 64 128 -96 128 WIRE 368 128 320 128 WIRE 400 128 368 128 WIRE 512 128 480 128 WIRE 624 128 512 128 WIRE 688 128 624 128 WIRE 752 128 688 128 WIRE 368 144 368 128 WIRE -96 160 -96 128 WIRE 512 160 512 128 WIRE 624 160 624 128 WIRE 192 256 192 224 WIRE 368 256 368 224 WIRE 368 256 192 256 WIRE -96 272 -96 240 WIRE 368 272 368 256 WIRE 512 272 512 224 WIRE 624 272 624 240 WIRE 192 288 192 256 WIRE 192 368 192 352 WIRE 368 384 368 352 WIRE 192 464 192 448 FLAG -96 272 0 FLAG 368 384 0 FLAG -96 128 IN FLAG 512 272 0 FLAG 688 128 OUT FLAG 624 272 0 FLAG 192 464 0 SYMBOL voltage -96 144 R0 WINDOW 123 0 0 Left 2 WINDOW 39 0 0 Left 2 SYMATTR InstName V1 SYMATTR Value 48 SYMBOL res 352 128 R0 SYMATTR InstName R1 SYMATTR Value 200 SYMBOL res 352 256 R0 SYMATTR InstName R2 SYMATTR Value 4.53k SYMBOL LT317A 192 128 R0 SYMATTR InstName U1 SYMBOL cap 496 160 R0 SYMATTR InstName C1 SYMATTR Value 20uf SYMBOL current 624 160 R0 WINDOW 123 0 0 Left 2 WINDOW 39 0 0 Left 2 SYMATTR InstName I1 SYMATTR Value PULSE(30m 200m 1m 1u 1u 4m) SYMBOL cap 176 288 R0 SYMATTR InstName C2 SYMATTR Value 20n SYMBOL res 176 352 R0 SYMATTR InstName R3 SYMATTR Value 20m SYMBOL res 496 112 R90 WINDOW 0 0 56 VBottom 2 WINDOW 3 32 56 VTop 2 SYMATTR InstName R4 SYMATTR Value 1u TEXT 72 -16 Left 2 !.tran 10m TEXT 80 -40 Left 2 ;'LT317A Demo With Capacitive Load