5A Constant Voltage/Constant Current Reg (Prt II)

This is the place for any magazine-related discussions that don't fit in any of the column discussion boards below.
Post Reply
seanacais
Posts: 6
Joined: Fri Aug 27, 2010 9:23 am
Contact:

5A Constant Voltage/Constant Current Reg (Prt II)

Post by seanacais »

I was looking at this thread from a few years ago and would like to try to adapt this circuit but two questions came up in my mind. I was hoping someone could explain if I was looking at this the wrong way.

The first question concerns R3. Being placed between Vout and the Collector of MJ4502 it is only going to sense the current that is going thru the pass transistor. I calculate the current through the LM317 at about 21 mA (0.7/33) which is not alot but could make adding a meter to the circuit somewhat inaccurate. Worse I don't see a way to monitor the actual current without throwing off the voltage regulation.

My second question has to do with the set point of the current limiting.

In operation the Voltage between the Emitter of MJ4502 and the Adj pin of the LM317 will vary between 1.25 and 2.25 V because of the shunt resistor R3. I believe this because the Emitter of MJ4502 has to be above Vout by (0.2 * Iout) which will be 0-1V depending on Iout.

The voltage divider feeding the inverting input made up of R2 and R5 is between these two points. So doesn't that mean that the set point of the current limiting will go UP as I draw more current? Also, since the non-inverting input is always equal to Vout there is no possibility that it should move even as Iout increases.

So it seems to me that this circuit will
1) Not reflect actual current draw if I attempt to meter current across R3. The error will be equal to the difference between current across the regulator and current consumed in the circuit. This could be as much as 15-20 mA.

2) The current limiting will vary with Iout since the response curve across the R2/R5 voltage divider is non-linear as the MJ4502 Emitter Voltage varies.

Can anyone explain if this is correct or where my analysis is incorrect?

Thanks,

Kevin
GREEEEEEEAAAT circuit. . . . as Tony the Tiger would say. . . .

Used it ever since the data sheet came out on it back in the 70-80's, and even using the IC forerunners of the LM 317's, before that time frame..

Consulting the marked up thumbnail you can see that the RED buss is the normal '317 circuitry, but in viewing the orange buss you will see that they have piggy backed in the MJ4502 so that it is sampling the current across R1 and then tracking and performing the bulk of the power handling with the '317 circuitry just loafing . . . .BUT. . . marvelously performing all of its built in overload-over temp-shutoff-functions of the circuitry.

Check the green buss and you will observe that it is merely sampling the loading presented across the R3 current shunt resistor and feeding correction to the negative node of the '301 op amp which then its tailors the output for the current correction action.
REFERENCING:
Image
73's de Edd
sghioto
Posts: 326
Joined: Wed Dec 26, 2007 5:16 pm
Location: Colorado
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by sghioto »

Kevin,
1) Not reflect actual current draw if I attempt to meter current across R3. The error will be equal to the difference between current across the regulator and current consumed in the circuit. This could be as much as 15-20 mA.
Correct! But you could install the meter between the circuit and the 35 volt input. You will still have minimum current reading of what ever the LM317 circuit is consuming but should be more accurate.
In operation the Voltage between the Emitter of MJ4502 and the Adj pin of the LM317 will vary between 1.25 and 2.25 V because of the shunt resistor R3. I believe this because the Emitter of MJ4502 has to be above Vout by (0.2 * Iout) which will be 0-1V depending on Iout.
I believe you mean the Collector of the MJE4502. The Emitter is always at 35 volts or whatever the power supply provides during operation.

Steve G.
User avatar
MrAl
Posts: 3862
Joined: Fri Jan 11, 2002 1:01 am
Location: NewJersey
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt

Post by MrAl »

Hi,


I didnt look at this circuit in great detail yet, but i can see that R3 is not in series with the load so there could be
some small output current that is not seen by this resistor. Since it is supposed to be a 5 amp regulator, it could be
that it was not designed to go down that low. Have you determined what R7 is used for yet? That could have something
to do with a slight compensation.

This is an older circuit anyway, probably back from the 70's or something like that.

A typical way that current is sensed in circuits like this is to put a resistor in series with the load in the ground
path. That means input and output grounds are not the same however, so high side sensing might be used instead.
When it is in the ground path the voltage regulation part has to be connected to the top side of the resistor so it
is possible to have a small error current that way too.

There must be a way to move R3 out to the very output so it senses ANY output current. The problem is that once that
is done you have to find a way to compensate the voltage circuit for that small loss in voltage. One way to do this
(possibly with this circuit too?) is to use an op amp to measure the voltage across the resistor and add that back to
the voltage regulation circuit. That's equivalent to isolating the voltage part completely so that it's bias does not
contribute to the total output current (either adding or subtracting). It may only take a simple op amp set up as a
voltage follower.

I'll be able to take a better look at this over the weekend. I know i must have analysed this circuit before though
because it looks familiar and i've looked at many many regulators like this. The first task is to find out what
R7 does for this circuit. We can talk about this circuit some more.
LEDs vs Bulbs, LEDs are winning.
seanacais
Posts: 6
Joined: Fri Aug 27, 2010 9:23 am
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by seanacais »

you could install the meter between the circuit and the 35 volt input. You will still have minimum current reading of what ever the LM317 circuit is consuming but should be more accurate.
I didn't consider that but it certainly bears consideration. My hope was to display the values on a 3-1/2 digit panel meter so I'll have to use an op-amp to measure the sense resistor and move it into the 200mV range anyway.
I believe you mean the Collector of the MJE4502. The Emitter is always at 35 volts or whatever the power supply provides during operation.

Steve G.
Yes my error. I meant the collector. The emitter is always at 35V as you say!

Kevin
User avatar
MrAl
Posts: 3862
Joined: Fri Jan 11, 2002 1:01 am
Location: NewJersey
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt

Post by MrAl »

Hi again,


Yes you were right about the small output current during full current limit. It ends up being around 15ma.
The problem is that the sense resistor is not in series with the very output, so there's always an error.
We can find a way to do this better using another circuit however. That old circuit was not meant to be adjusted down that low.
As i was saying before, when the sense resistor is in series with the very output it drops some voltage, so that drop has to be conveyed back to the voltage regulation loop so that it 'knows' that the voltage has to go a little higher now. Once that is done it would work better. Also as i was saying, an op amp set up to be a voltage follower can track this voltage and relay it to the voltage regulation loop without an error (very very tiny error). I dont think it would be hard to do.

First question though is can your application stand having different grounds, or do they have to be connected input and output? If this is for a test setup sometimes it doesnt matter. If they must have the same ground it makes it just a little
harder because we have to sense the current in the high side.
LEDs vs Bulbs, LEDs are winning.
seanacais
Posts: 6
Joined: Fri Aug 27, 2010 9:23 am
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by seanacais »

I didnt look at this circuit in great detail yet, but i can see that R3 is not in series with the load so there could be
some small output current that is not seen by this resistor. Since it is supposed to be a 5 amp regulator, it could be
that it was not designed to go down that low. Have you determined what R7 is used for yet? That could have something
to do with a slight compensation.
R7 has bothered me since the very first time I looked at this circuit. I have no idea what it is for. The only current flowing across it should be coming from the total of the current set point voltage bridge and the adjust pin of the LM317. In total we are talking about 10-15 microamps which doesn't seem all that important in the grand scheme.
This is an older circuit anyway, probably back from the 70's or something like that.
Yep. This came from the LM317 data sheet so it's circa 1972 or earlier IIRC.
A typical way that current is sensed in circuits like this is to put a resistor in series with the load in the ground
path. That means input and output grounds are not the same however, so high side sensing might be used instead.
When it is in the ground path the voltage regulation part has to be connected to the top side of the resistor so it
is possible to have a small error current that way too.

There must be a way to move R3 out to the very output so it senses ANY output current. The problem is that once that
is done you have to find a way to compensate the voltage circuit for that small loss in voltage. One way to do this
(possibly with this circuit too?) is to use an op amp to measure the voltage across the resistor and add that back to
the voltage regulation circuit. That's equivalent to isolating the voltage part completely so that it's bias does not
contribute to the total output current (either adding or subtracting). It may only take a simple op amp set up as a
voltage follower.
I was thinking one way to do this is to either measure both paths and sum them or to ensure that the LM317 doesn't provide enough current to feed the circuit so whatever current is going through the shunt is more than what could possibly be going to the load. Playing with the size of R1 should accomplish this easily.

I'll be able to take a better look at this over the weekend. I know i must have analysed this circuit before though
because it looks familiar and i've looked at many many regulators like this. The first task is to find out what
R7 does for this circuit. We can talk about this circuit some more.
I'd love to discuss this some more. I'm really struggling with understanding the set points of the current limiter circuitry.

Thanks for the help!

Kevin
User avatar
MrAl
Posts: 3862
Joined: Fri Jan 11, 2002 1:01 am
Location: NewJersey
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt

Post by MrAl »

Hi again,


Yes i always like talking about these kinds of circuits :smile:

Picture this:

A small current sense resistor 0.2 ohms or maybe even 0.1 ohms in the ground lead of the LOAD itself.
Now the bottom of the voltage sense resistor divider connects to the top of that sense resistor, so that any
changes in sense voltage are immediately sensed by the voltage circuit, which of course then compensates.
That means we've inserted a sense resistor and havent bothered the voltage regulation.

Next, connect an op amp so that it senses the sense voltage and at a certain point the output starts to fall (using say a reference diode as the compare voltage) and that cuts back the current. The voltage loop is still pretty accurate.

Now it works as we want it too, except for one small detail. The sense resistor also senses the 5ma voltage divider current. That means it will cut back 5ma sooner than we want it to. That's not a big deal really, because i think it is a constant value so if we set it for a theoretical 1.005 amps we'll get 1.000 amps, and if 2.005 amps we'll get 2.000 amps.
The simple solution (if one is even needed) is to provide isolation between the sense resistor and the voltage divider bottom. That's pretty easy with an op amp that has it's inverting terminal connected directly to the output, with the non inverting terminal connected to the sense resistor top and the output of the op amp connected to the bottom of the voltage divider. That means the voltage divider stays happy yet it does not draw or provide any current to or from the sense resistor, so now we are close to perfect. I think this is what you are after.

As i also said though, this mod requires sensing in the ground lead of the load, which means the load can not be connected to the same ground as the input. This is very often no problem at all because the power supply operates off the line with a transformer anyway, so who cares about the input/output ground.
If it is of concern however, the same idea is applied but the current has to be sensed in the high side (positive output) of the regulator. It's harder to do that though requiring more resistors.

If you'd like to see a typical circuit, i think i can draw one up say tomorrow.
LEDs vs Bulbs, LEDs are winning.
seanacais
Posts: 6
Joined: Fri Aug 27, 2010 9:23 am
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by seanacais »

MrAl:

I was looking at this with the thought of adding panel meters to the existing circuit to measure set-points and output current. I'm beginning to see that may entail more work than I thought.

While I'm interested in seeing the circuit you describe, I do have a slight preference for high side current monitoring (if it can be done reasonably.)

Having said all that, I was wondering if you could check my thoughts. I've been doing some additional work on the circuit and I see that my earlier thoughts on the current limiting were incorrect. I do however think there may be a problem with the value of R5 (330K). I think that this supply will never achieve the 5A specified.

Since the non-inverting input is tied to Vout, the op-amp will start to bring the Vadj terminal down when the voltage across R2 exceeds the voltage across R3 which is the same as saying that the voltage across R5 exceeds 1.2V. This will always be when the current across R5 exceeds 1.2/R5 (3.63 uA).

At 5A Vr3 = 1.0V so R2 has to drop 1.0 V but at 3.63 uA, 250K can only be 0.9091. So even if I crank the pot all the way to the right, I can never get more than 0.9091V/0.2ohm = 4.54A before the current limiting will kick in.

Saying this another way:

R2max = ((Vr3 + 1.2) * R5) / 1.2 - R5 (*where Vr2 = Vr3)

plugging in the numbers ((1+1.2) * 330K) / 1.2 -330K = 275KOhm.

So either R2 needs to be made bigger or R5 needs to be made smaller.

Can anyone comment of if this analysis correct?

Thanks,

Kevin
User avatar
MrAl
Posts: 3862
Joined: Fri Jan 11, 2002 1:01 am
Location: NewJersey
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt

Post by MrAl »

Hi again Kevin,


I think you are on the right track, except usually we use 1.25v as the internal reference, not 1.2v.

Using 1.25v as the reference, if we want to use a 250k pot (and we get adjustment to the full value) we can figure the current as 1/250k because with a 0.2 ohm sense resistor and 5 amps that puts 1v across the 250k pot. With the 1.25v reference we need a resistor 1.25/R=1/250k, or working in k ohms, 1.25/R=1/250 and solving for R we get 312.5 which is 312.5k as the correct value of R5. However, we may want to err slightly on the low side or on the high side. Erring slighly on the low side we might use 330k, but if you want to err slighly on the high side (to make sure we can get 5 amps out) then you might go with 300k instead. 300k will give us roughly 5.2 amps out, so we should be able to get at least 5 amps out in the real circuit.

Does that help at all?

Question: What year were the 1N457 diodes first used in?
Answer: 1970, but that's 1970 BC (chuckle) :smile:
LEDs vs Bulbs, LEDs are winning.
User avatar
Bob Scott
Posts: 1192
Joined: Wed Nov 20, 2002 1:01 am
Location: Vancouver, BC
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by Bob Scott »

If you guys drift into the idea of using a floating shunt resistor on the + side of the load to sense the circuit's current, it might be a good idea to read this link. The precision of resistors needed to sense the current need to be way better than 1%.

Look for the keyword "Howland" for Howland Current Pump.

http://www.cirrus.com/en/pubs/appNote/Apex_AN13U_D.pdf

I don't think you'll find this info in Wikipedia.
-=VA7KOR=- My solar system includes Pluto.
seanacais
Posts: 6
Joined: Fri Aug 27, 2010 9:23 am
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by seanacais »

Using 1.25v as the reference, if we want to use a 250k pot (and we get adjustment to the full value) we can figure the current as 1/250k because with a 0.2 ohm sense resistor and 5 amps that puts 1v across the 250k pot. With the 1.25v reference we need a resistor 1.25/R=1/250k, or working in k ohms, 1.25/R=1/250 and solving for R we get 312.5 which is 312.5k as the correct value of R5. However, we may want to err slightly on the low side or on the high side. Erring slighly on the low side we might use 330k, but if you want to err slighly on the high side (to make sure we can get 5 amps out) then you might go with 300k instead. 300k will give us roughly 5.2 amps out, so we should be able to get at least 5 amps out in the real circuit.
That helps alot! It confirms to me that I'm not going crazy! :-)

Thanks!!!!

Kevin
seanacais
Posts: 6
Joined: Fri Aug 27, 2010 9:23 am
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt II)

Post by seanacais »

As i also said though, this mod requires sensing in the ground lead of the load, which means the load can not be connected to the same ground as the input. This is very often no problem at all because the power supply operates off the line with a transformer anyway, so who cares about the input/output ground.
If it is of concern however, the same idea is applied but the current has to be sensed in the high side (positive output) of the regulator. It's harder to do that though requiring more resistors.

If you'd like to see a typical circuit, i think i can draw one up say tomorrow.
So the idea of high side current sensing has been bugging me since the weekend.

The current sensing itself is very simple. Put a sense resistor into the output side of the LM317 and capture the voltage drop with a instrumentation amplifier to feed a panel meter. However if you sense the voltage at the output then your voltage is going to vary based on the current draw of the load. Not an optimal solution.

I cannot seem to wrap my head around how to compensate for the drop of the sense resistor in the output of the LM317.

I'm thinking of using a MOSFET in the linear region as a very precise variable resistor placed in series with resistor between Vout and the adjust pin. The MOSFET will drop the same voltage as that of the sense resistor. The instrumentation amplifier will either drive the mosfet directly or thru an op-amp if some gain is required. I think this will compensate for the sense resistor at any current load but I'm not sure how to prove it to myself short of bread boarding the entire thing.

So the short answer is yes. If you can draw up a high-side current sense I'd be very interested.
If you guys drift into the idea of using a floating shunt resistor on the + side of the load to sense the circuit's current, it might be a good idea to read this link. The precision of resistors needed to sense the current need to be way better than 1%.

Look for the keyword "Howland" for Howland Current Pump.

http://www.cirrus.com/en/pubs/appNote/Apex_AN13U_D.pdf
Bob:

I will read this with great interest!!!

Kevin
User avatar
MrAl
Posts: 3862
Joined: Fri Jan 11, 2002 1:01 am
Location: NewJersey
Contact:

Re: 5A Constant Voltage/Constant Current Reg (Prt

Post by MrAl »

seanacais wrote:
As i also said though, this mod requires sensing in the ground lead of the load, which means the load can not be connected to the same ground as the input. This is very often no problem at all because the power supply operates off the line with a transformer anyway, so who cares about the input/output ground.
If it is of concern however, the same idea is applied but the current has to be sensed in the high side (positive output) of the regulator. It's harder to do that though requiring more resistors.

If you'd like to see a typical circuit, i think i can draw one up say tomorrow.
So the idea of high side current sensing has been bugging me since the weekend.

The current sensing itself is very simple. Put a sense resistor into the output side of the LM317 and capture the voltage drop with a instrumentation amplifier to feed a panel meter. However if you sense the voltage at the output then your voltage is going to vary based on the current draw of the load. Not an optimal solution.

I cannot seem to wrap my head around how to compensate for the drop of the sense resistor in the output of the LM317.

I'm thinking of using a MOSFET in the linear region as a very precise variable resistor placed in series with resistor between Vout and the adjust pin. The MOSFET will drop the same voltage as that of the sense resistor. The instrumentation amplifier will either drive the mosfet directly or thru an op-amp if some gain is required. I think this will compensate for the sense resistor at any current load but I'm not sure how to prove it to myself short of bread boarding the entire thing.

So the short answer is yes. If you can draw up a high-side current sense I'd be very interested.
If you guys drift into the idea of using a floating shunt resistor on the + side of the load to sense the circuit's current, it might be a good idea to read this link. The precision of resistors needed to sense the current need to be way better than 1%.

Look for the keyword "Howland" for Howland Current Pump.

http://www.cirrus.com/en/pubs/appNote/Apex_AN13U_D.pdf
Bob:

I will read this with great interest!!!

Kevin

Hi again Kevin,


You see that pot R8 right? The bottom end is connected to ground right?
Well, disconnect the end that connects to ground and connect a battery from there to ground with the positive side of the battery to R8 bottom and the negative side of the battery to ground. Now the only thing different is the battery is in series with the ground side of R8. So what happens to the output voltage now? Well, if the output voltage is 10.000 volts BEFORE we connect the battery (R8 goes directly to ground) then AFTER we connect a battery who's voltage is 0.100 volts, the output voltage goes up to 10.100 volts. That means whatever voltage we connect at the bottom of R8 (after breaking the connection to ground) gets added to the output. In other words, VoutNew=VoutOld+Vbattery.
Of course in real life we dont want to use a battery. Instead of a battery, we simply connect the output of an op amp to the bottom of R8. The input (at the very least) is set up as a differential amplifier with the two inputs connected across the small sense resistor. Now when a voltage appears across the sense resistor (a sense resistor that is connected in series with the total output) when a current is drawn that voltage gets subtracted from the output:
VoutNew1=VoutOld1-Vsense

but now the differential amplifier senses Vsense and that same voltage appears at the output of the op amp, so the bottom of R8 gets biased by the Vsense voltage and so it adds that voltage back to the output.

VoutNew1=VoutOld1-Vsense (we loose Vsense volts)
VoutNew2=VoutNew1+Vsense (we gain Vsense back again)
so
VoutNew2=VoutOld1 (which was the original voltage before loading the power supply)

which is the same as without a sense resistor. Thus, the differential amplifier compensates for the loss in voltage caused by the sense resistor being directly in series with the output.

For a real example, say at first we are drawing 0 amps (no load) and the voltage is 10.0 volts. Now we apply a load and it draws 1 amp, and with 0.2 ohm sense resistor that means we drop 0.2 volts across the sense resistor, so the voltage WOULD go down to 9.8 volts. But, the differential amp senses that 0.2 volts and develops 0.2 volts at its output too, and so the bottom of R8 goes to 0.2 volts also, and that adds it back to the output so we get
Vout=9.8+0.2=10.0 volts
which is what we had before we loaded it to 1 amp.
Now if we remove the load, it all goes back to the way it was before with no drop across the 0.2 ohm resistor. If we add more load, the drop increases but the added voltage increases too so it maintains the output at 10.0 volts.
LEDs vs Bulbs, LEDs are winning.
Post Reply

Who is online

Users browsing this forum: No registered users and 56 guests