LM317 Simple Constant Current Circuit & Luxeon ??

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
I was going to email my buddy Doug Owen about this, but thought I'd post my questions here so other noobs like me can benefit!

Here is the great and simple constant current circuit Doug gave me which produces a current of 26 ma with "any" voltage provided above 6v (also pictured is the Luxeon I got from Doug):
lm317.jpg


My questions:

1) How do I calculate the value of the resistor X to get a current of Y?
2) Is there anything I have to worry about concerning the resistor wattage rating, or the LM317 rating so I don't "cook" them?
3) I was thinking about using this little Luxeon, but don't know the specs for it. Say I want to run this at the spec values, what size / value of resistor would I use to get what current?

Thanks in advance!
 

Doug S

Flashlight Enthusiast
Joined
Jun 20, 2002
Messages
2,712
Location
Chickamauga Georgia
1. If X=resistance in Ohms, Y=current in amps then
X=1.25/Y

2.That version of the LM317 [TO-92 package] has an internal current limit of 150mA. It is also thermally protected limiting die temp to around 160C. With the 150mA current limit, you don't need to worry much about the resistor power rating. If you need more than 150mA you need to use the LM317 in the TO-220 package which current limits at around 2A. In this case, the wattage rating of the resistor should be at least 1.6/R.

3. The Luxeon is rated at 350mA but see #2 above. If you want to get the maximum out of that LM317 pictured [about 150mA] replace the resistor with a short.
 

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
Doug S.... another great Doug!

Thanks for that great info! So, if I short out the LM317 I've got then it will run the Luxeon I've gor at 150mA?

Do I need to worry about a "max" voltage I'm supplying? I'd like to use this in my car, but when the engine's running I get up to 14 volts.

Thanks in advance.... what a great little circuit! With this circuit and the one Doug Owen did for the Milky Candle I can have LOTS of fun!
 

Doug S

Flashlight Enthusiast
Joined
Jun 20, 2002
Messages
2,712
Location
Chickamauga Georgia
[ QUOTE ]
reviewum said:
Doug S.... another great Doug!

Thanks for that great info! So, if I short out the LM317 I've got then it will run the Luxeon I've gor at 150mA?

Do I need to worry about a "max" voltage I'm supplying? I'd like to use this in my car, but when the engine's running I get up to 14 volts.

Thanks in advance.... what a great little circuit! With this circuit and the one Doug Owen did for the Milky Candle I can have LOTS of fun!

[/ QUOTE ]
Yes, if you want the full 150mA, you do need to worry about the voltage. That TO-92 package can only dissapate about half a watt. If your supply is 14V and your Luxeon is say 3V, then 14-3=11V would be dropping across the LM317. 11Vx0.15A=1.65W. The IC would go into thermal limit and reduce the current to probably less than 50mA. If you need to dissapate that much power, you need to use the TO-220 package and the appropriate resistor to set the current.
 

Justintoxicated

Flashlight Enthusiast
Joined
Dec 8, 2003
Messages
1,151
Location
El Cajon, CA
Re: LM317 Simple Constant Current Circuit & Luxeon

Honestly I would NOT do this mod....Well not if your going to be using 9-volts...The LM317 is Horribly Inefficient, You will need to heatsink the LM317 and the LED (seperately) if your planing on running that luxeon at 350ma.

Now for constant power source like your truck it should be ok, but it would be better to run Multiple luxeons off 1 LM317 if your going to use a 14 V source. Here is why, say your running the luxeon at 350ma, and the luxeons Vf at 350ma is 3.5 volts. 14-3.5 = 10.5 volts that are wasted. 10.5x350 = 6.65 watts that hte LM317 is responsible for disipating. It is going to get HOT!

Now with an LM317T variety this is ok if you have good cooling. But Horribly inefficient, now add 2 more Luxeons to the equation and you will wee that the LM317T does not have to disipate nearly as much power! Weird huh!

Anyways to answer the question wether or not it will be able to handle 14V it really depends on the variety of the LM317 your purchase, the LM317T shoudl be able to do it, Can't rememebr the max V but I think it was like 30 at 1 amp or something (Look it up if you need). Oh and beleive me heat adds up fast, I was gettign readings over 200F when driving a couple Lux III's (at 1 amp! meaning it has even more power to disipate as heat)

Also now you can see why it would be horrible for driving things on batteries.

BTW a 4 ohm 1/2 watt resistor should cover it 1.25/4 = 3.125 ma
 

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
Re: LM317 Simple Constant Current Circuit & Luxeon

This is good stuff! Thanks guys!

Maybe I'll use 5mm LEDs in series / parallel using the LM317 for this application.
 

unclearty

Enlightened
Joined
Aug 26, 2003
Messages
434
Location
Mid-Massachusetts
Re: LM317 Simple Constant Current Circuit & Luxeon

Would you be willing to draw out this regulator circuit for the rest of us? Why series for multiple 5mm leds?
 

Justintoxicated

Flashlight Enthusiast
Joined
Dec 8, 2003
Messages
1,151
Location
El Cajon, CA
Re: LM317 Simple Constant Current Circuit & Luxeon

typicaly it is always better to run leds in series with this circuit because you are limiting the current through all of the LED's to particular value. Bad things can happen when you wire them in Parallel. Think of it this way current is liek a flow, and you want 350ma to flow through one LED and the same current to flow into the other. If you were to wire them in parallel you will probably fry your LED's. Trust me I have killed Luxeons this way before...I forget what exactly happens but perhaps the currents add in some manner and smoke your lights.
 

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
Re: LM317 Simple Constant Current Circuit & Luxeon

Here is the one I'm working on to add two lights to my interior in my car:

lm317_car.gif


I'm not a super schematic guy, so let me know if it is wrong.

I'll take some pics when it is done.

On my test bench I get a constant 40 mA to each LED from 10 to 15 volts supplied without any head to the resistor or the transistor.
 

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
Re: LM317 Simple Constant Current Circuit & Luxeon

Comeon doug... does it really matter? /ubbthreads/images/graemlins/wink.gif

Fixed in the image above!
 

IsaacHayes

Flashlight Enthusiast
Joined
Jan 30, 2003
Messages
5,876
Location
Missouri
Re: LM317 Simple Constant Current Circuit & Luxeon

Check out plans for my car dome light that I will build when I get time. It'll be mounted on a 1/8" thick aluminum plate for heatsinking the luxeons and the LM317T, but the LM317T must be isolated from the plate, as the plate will be tied to ground from the luxeons..
 

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
Re: LM317 Simple Constant Current Circuit & Luxeon

Okay, I give up... I'll let someone else post the CORRECT schematics!

/ubbthreads/images/graemlins/icon3.gif /ubbthreads/images/graemlins/banghead.gif


:)
 

Justintoxicated

Flashlight Enthusiast
Joined
Dec 8, 2003
Messages
1,151
Location
El Cajon, CA
Re: LM317 Simple Constant Current Circuit & Luxeon

The link I gave you not only shows the correct schematics but it explains in detail the entire circuit using the LM317T for Current regulation. (I guess it can do voltage regulation also)
 

evan9162

Flashlight Enthusiast
Joined
Apr 18, 2002
Messages
2,639
Location
Boise, ID
Re: LM317 Simple Constant Current Circuit & Luxeon

Don't worry. Your schematic is correct. Pay attention to the pin designation that he's drawn for the LM317.

Justin might be confused since your circuit isn't drawn in the traditional left--> right manner that most people are used to (power source on left, load on the right).
 

Justintoxicated

Flashlight Enthusiast
Joined
Dec 8, 2003
Messages
1,151
Location
El Cajon, CA
Re: LM317 Simple Constant Current Circuit & Luxeon

edit: N/M I see it now, looks good. I didn't realize the LED's were in the Diagram /ubbthreads/images/graemlins/banghead.gif
 

reviewum

Enlightened
Joined
Jul 22, 2003
Messages
201
Location
Bay Area - CA
Re: LM317 Simple Constant Current Circuit & Luxeon

Okay, I'm looking at the circuit running on my desk and it is working perfectly! I've got 40 mA running through 2 sets of LEDs (20 mA each right?)... when I crank up the voltage the current stays the same.

Here is what the circuit looks like... is this better or worse?

lm317_car_2.gif


Maybe I need to turn on the A/C this heat is cooking my brain!
 
Top