LM317 CC/CV circuit not working

I built this circuit (Simple Lithium-ion / Lipo Battery Charger) about a year ago and I remember that it worked fine. Recently I built it again but this time I'm having some problems. No matter what value resistor I use for R1 and R2 (currently combined into a 1 ohm resistor), the constant current always kicks in at about 7mA. In the attached picture, good.bmp, ch.1 is output voltage and ch.2 is the reference pin on the TL431. The output load is 1000 ohms and as you can see, it works as it should. In the picture, bad.bmp, the output load is 500 ohms and obviously something isn't right. I've tried 3 different LM317's and TL431's (actually 2 of them are KA431's) and I get the same results with all of them. R5 is a 50k potentiometer and R4 is 56k resistor. I have 100uF on input and output. Any idea what could cause these results? The input voltage stays at a steady 16v and nothing gets warm.

good.bmp (219 KB)

bad.bmp (219 KB)

7ma * 1000ohm = 7v.

It is working. You just applied it to the wrong kind of load.

At 1000 ohms it's still in constant voltage mode... Go take your wisdom elsewhere please. And I get the same results with a battery instead of a resistor.

Measure from the LM317 output pin to the battery connection, it looks like something is open.. R1 or R2 or the connections to between and from them and the '317 and the load. That isn't really a good Li-Po battery charger as I don't see any CV function just CC with the 2 1/2 ohm resistors.

Bob

I get 4.2 volts either side of the resistor with no load. I even tried various values from .1 to 47 ohms and got the same results. I'm no master at LM317 circuits, but if I remember correctly, voltage is controlled by the amount of current going into the adjust pin. I believe the voltage divider (R4 and R5) allow the TL431 to conduct or not conduct depending on output voltage, therefore regulating the voltage if R1 and R2 don't drop it enough (ie. if the current is lower than that set by R1 and R2).

Maybe that means that the TL431 isn't allowing enough current to flow into the adjust pin? What I'm really confused by is R3. What does it do? Removing it makes no noticeable difference.

Is this a common failure mode of the LM317? I tried the simple 1 resistor CC circuit and also got about 7 mA no matter what. To be fair, I'm pretty sure all three of these LM317's have been soldered in backwards before in other circuits... I'm not good when it comes to checking the orientation.

EDIT: I'd appreciate it if someone built a simple CC circuit with a 47 ohm resistor and used a 1k resistor as the load. What voltage do you get across the 1k? current through it? I should be getting 26 volts (higher than my supply voltage) instead of 4 volts, and 26 mA instead of 4 mA.

FWIW: with adjust grounded, I get 640mV on the output. Not good?

bobthebanana:
Is this a common failure mode of the LM317? I tried the simple 1 resistor CC circuit and also got about 7 mA no matter what. To be fair, I'm pretty sure all three of these LM317's have been soldered in backwards before in other circuits... I'm not good when it comes to checking the orientation.

Well then I would wire them up as simple voltage regulators on a breadboard and see if your working with functional parts. :wink:

Lefty

Hmm, they did work when I first tested them after noticing the problem. And I was pulling 500 mA from all of them. Now 2 of them give 6v when set to 5v and one gives 4.8v. I can only pull, guess how much, 7 mA now. Do they usually die this quick or did I get fakes? Who knows. I guess I'll include some in the next Digikey order.

bobthebanana:
Hmm, they did work when I first tested them after noticing the problem. And I was pulling 500 mA from all of them. Now 2 of them give 6v when set to 5v and one gives 4.8v. I can only pull, guess how much, 7 mA now. Do they usually die this quick or did I get fakes? Who knows. I guess I'll include some in the next Digikey order.

I don't think anyone would go to the trouble to sell 'fake' LM317s, but some might sell you 'rejects' from someone's production run. I once ordered ten 3.3volt regulators 78L33 from a seller in Thailand. Everyone one of them worked but not one of them had an output voltage between 3.1 to 3.7, all were at, below or above those values, as if they were out of tolerance rejects from someone's production run.

Lefty

2 things, Quickly
@ OP The 317 works by adjusting the output voltage so that there is a 100 uA current to ground from the adjust pin, in practice the adj pin will be 1.25 V less than the output.
@ lefty... The 'fakes' and 'counterfeits' theory bothers me because it is my impression that the 'chips' are tested and sorted prior to packaging and the appearance of the counterfeits is unusual in it's variety.. just like they were real and seem to cover a very wide 'swath' through the 'industry'. It is the degree of professionalism that is seemingly involved that really bothers me. I know directly of several different "counterfeits" but these were obvious rip-offs that were visible in the labeling and I don't hear much about that from any source that might be credible... There is also the fact that really I know little and the cases may well be true.. But Voltage regulators and other pedestrian parts? No... Where is the money?, Substantial enough to engender this kind of fraud? from a few K parts at a time? and across the areas that it is supposed to appear?
Likely it is the muleheadidness I was born with.. But somehow it speaks to a degree of organization that smacks of conspiracy from many involved on the supply side and I find that thought or concept most difficult to buy stock in. I also balk at 'something for nothing' I don't buy "Pure Unobtanium".. There is a reason why it is Unobtanium..

Bob

In point of fact, dhenry spotted one of the significant problems right off. You cannot
put a 4.2V/1000 = 4.2 mA load on a 1.2A "constant-current" supply and expect to read
correct values. It will drive operation to some boundary condition [unusual operation].

Secondly, I hope you have a truly MASSIVE heatsink on the 317s, as in normal operation
they would be dissipating (16V - (4.2V + 1.2V)) * 1.2A = 13W. This'll cook your 317s
good.

Thirdly, since 317s have the "other" pinout numbering from 7805s, it's easy to wire
them in backwards if not paying attention. These may have all been cooked already
sometime in the past ["I'm not good when it comes to checking the orientation" <- be
more careful, sheesh].

Fourthly, 317s are not biased via driving current into the adjust pin, they are biased
by having 1.2V between Vout and Adjust, and won't regulate unless you have that.

Fifthly, R3 is in the ckt to avoid dumping the entire 1.2A "constant" output current
down the throat of IC2. It limits this current to roughly 4 mA max.

Sixthly, in response to doc's comment, the "constant voltage" aspect comes from the
output voltage feeding back through R5,R4 to shutdown the regulator whenever
Vout goes above ((6.8K + 10K) / 10K) * 2.5V = 4.2V, via IC2 pulling the Adjust pin
to ground, and therefore the Vout pin will be pulled to 1.2V.

Seventhly, this a very common feedback regulator ckt, but I sure wouldn't use it to
charge Li batteries, I'd get a real Li charger for that - one that takes into account
battery chemistry and proper charging cycles.