LM317 as LED driver with two constant output current selection

ElectricSpidey

Joined Dec 2, 2017
2,757
You are welcome, glad I could help.

EDIT:

Careful how you place any diodes, the fog lamp voltage must remain high enough to divert the current from the base of Q2.
 
Last edited:

ThePanMan

Joined Mar 13, 2020
773
Well, if you like working with transistors then you have a good solution. But if you're going for simplicity then I like @Tonyr1084's solution. Turn the fog lights on and you put one more resistor into the LED circuitry, causing the light output to drop drastically. Turn the fog lights off and your LED's go to full brightness. Seems simple to me. Am I missing something?
 

LowQCab

Joined Nov 6, 2012
4,023
Well, if you like working with transistors then you have a good solution. But if you're going for simplicity then I like @Tonyr1084's solution. Turn the fog lights on and you put one more resistor into the LED circuitry, causing the light output to drop drastically. Turn the fog lights off and your LED's go to full brightness. Seems simple to me. Am I missing something?
.
I agree,
as long as he can practically change his Fog-Lights-Switch to Double-Pole, or add a Relay.

But the Resistors really should be in the Feedback-Loop of the 317 in a Current Regulator setup.
It's not unusual for a Car to have ~20% Voltage fluctuations,
a Current-Regulator makes that a non-issue.
.
.
.
 

MisterBill2

Joined Jan 23, 2018
18,167
Can the TS explain the benefit from having the fog lights on when there is no fog? Certainly it does not increase safety by shingmore light into the eyes of oncoming traffic.So please explain the benefit from having the fog lights o when there is no fog??
 

Thread Starter

pravardhan

Joined Jul 30, 2009
10
Hi All,

@Tonyr1084
@ThePanMan

If I were to use an relay then why would I have posted for help in this forum.

@LowQCab
1. Most of the cars have the GROUND connected to CHASSIS & BODY. Hence we need to switch the POSITIVE / HOT in this case.
2. From my experience of working with the LEDs, the LEDs have a "Thermal Runaway". When the LED heats up it's forward voltage drops & there by the LED consumes more current and in-turn gets more heated-up & this cycle continues until the LED blows. Hence we need to supply a constant current for the LEDs and I am against using resistor dropper for high wattage LEDs.

Thanks & Regards,
Pravardhan U.S
 

Thread Starter

pravardhan

Joined Jul 30, 2009
10
Can the TSexplain the benefit from having the fog lights on when there is no fog? Certainly it does not increase safety by shingmore light into the eyes of oncoming traffic.So please explain the benefit from having the fog lights o when there is no fog??
Hi MisterBill2,

The fog lights beam pattern are designed such that it will not to glare the oncoming traffic & have a screw for light height adjustment. The fog light beam will start just below where the headlight beam ends.
I will only switch on the fog lights when it rains or have no street lights to see any pot holes on the road.

Thanks & Regards,
Pravardhan U.S
 

MisterBill2

Joined Jan 23, 2018
18,167
Hi MisterBill2,

The fog lights beam pattern are designed such that it will not to glare the oncoming traffic & have a screw for light height adjustment. The fog light beam will start just below where the headlight beam ends.
I will only switch on the fog lights when it rains or have no street lights to see any pot holes on the road.

Thanks & Regards,
Pravardhan U.S
My observation is that ALL OEM fog lights glare into the eyes of oncoming traffic. I am aware that the intention is otherwise, but the reality is that they do. And my low-beam headlights do show potholes,
 

LowQCab

Joined Nov 6, 2012
4,023
This is all rather silly about Glare and Aiming,
we're only talking about 200ma here.
My Interior-Lights are over 300ma.

pravardhan
Man, you need to get ALL the information You can,
before You decide that You know what you're doing.
This Forum is a great place to learn stuff.

You will find out ....... the hard way,
that the only way anyone can learn new things is to ask and listen.

To specify how this problem is to be solved,
when You don't understand it in the first place,
is a bit insulting to everyone trying to help You.

"" Most of the cars have the GROUND connected to CHASSIS & BODY.
Hence we need to switch the POSITIVE / HOT in this case. ""

"" I don't know why your circuit mentions as "going to" fog lights?

Actually I want the fog lights supply for sensing & make the DRL brightness less.
Hence fog lights have to be "coming in". ""

False.

If You will notice, there is a Diode, and a Low-Value-Resistor on the connection
going to your Fog-Lights.
This usually referred to as a "Switched-Ground",
when the Fog-Lights are "OFF" they provide a Ground-Connection to the Circuit.
When the Fog-Lights are "ON" NO CURRENT TO GROUND flows in, or out, of the Circuit.
This can be very useful in Circuits designed to take advantage of this trick.
General-Motors-Corp. has been doing it for ~60-years, it works great.
-------------------------------------------------------------------------------------------------------

"" From my experience of working with the LEDs, the LEDs have a "Thermal Runaway".
When the LED heats up it's forward voltage drops & there by the LED consumes more
current and in-turn gets more heated-up & this cycle continues until the LED blows.
Hence we need to supply a constant current for the LEDs and

I am against using resistor dropper for high wattage LEDs. ""

If You will notice, both of the Circuits that I provided use a Current-Regulator.
I also made this statement .............
But the Resistors really should be in the Feedback-Loop of the 317 in a Current Regulator setup.
It's not unusual for a Car to have ~20% Voltage fluctuations,
a Current-Regulator makes that a non-issue.

It's fairly evident that You don't understand most of the comments in this Thread.
I would suggest that You ask how and why certain things work, or don't work.

The way that You have presented to accomplish your goal will not function like You imagine,
You will probably just wind-up smoking some LEDs.

A Relay, or more complex Circuit(s),
(possibly similar to the ones I provided),
are your choices.

Hint ...........
The first Circuit that I provided is capable of providing substantially Higher-Current,
if You should decide to up-grade your LED-Lights to more powerful ones.
.
.
.
 

Tonyr1084

Joined Sep 24, 2015
7,852
@Tonyr1084
- - - -
If I were to use an relay then why would I have posted for help in this forum.
Scuse me.
I am against using resistor dropper for high wattage LEDs.
Again, scuse me. I don't recall any data or information on the LED's. One can only assume, and when that happens, often it makes an ass out of you and me.

Since my help is not helpful - I'm outa here. You can build your project any way you want to.

{{{ thread unwatched }}}
 

ThePanMan

Joined Mar 13, 2020
773
Two things strike me, now that I look back again: First, why would you need fog lights during the daytime? DRL's are for improved visibility during the day. If you have fog and fog lights on during the day - what's the purpose in dimming the DRL's?

Second: I looked back as Tony suggested - you don't have any data on the DRL's. How are we to know the specifics about something without having all the information? Are you building your own DRL's or is this something you bought? The forward voltage you give is consistent with 5mm LED's. You show them in series, so maybe this is something you're building on your own. Hence, we don't really know all the details. Only that you insist on using transistors. Well, like Tony said, you can build it any way you want to. I'll be curious to see your final outcome. And if these ARE commercial DRL's - how much current do they draw when lit? Can the 317 handle that much current? And how are you going to manage the heat produced by the regulator? It's not looking like you've thought this all the way through. It also looks like you've made up your mind on a solution regardless of what anyone else advises. If your mind is made up - best wishes to you.
 

ElectricSpidey

Joined Dec 2, 2017
2,757
@ThePanMan

Just for kicks let's assume each DRL is a module consisting of the circuit presented here.

Now let me ask you a question...

If there are 4 modules one each front/left front/right rear/left rear/right how many poles would be needed in Tony's switch solution?

Point? If you are going to worry about unknowns, you might want to consider all of them, instead of cherry picking.
 

LowQCab

Joined Nov 6, 2012
4,023
DRLs in the REAR !!!
That should be an interesting conversation to hear when a Cop pulls him over !!
DRLs are basically High-Beam-Headlights at ~1/4 to ~1/3 Power, operated during the Day.

At 200ma., we are dealing with a ridiculously low Light-Output,
so they are not really DRLs in the first place.

The atmosphere in this Thread is getting rather tiresome.
.
.
.
 
Last edited:

ElectricSpidey

Joined Dec 2, 2017
2,757
@pravardhan

Ok, here is the revised schematic, and again sorry for any inconvenience.

AAC_CC_3.jpg

Now you are probably thinking...what about Q1, well their shouldn't be a need for one there, if you pop in an ammeter in your sim you should just see a nominal current there. (between the Q1 base and Q2 collector)

I don't think 3mA will be enough to even dimly light the fogs, but you could remove R5 and make R4 10k if you want, but leaving R5 will keep the DRLs bright even if the fogs goes out.

I made this mistake because I didn't consider the path to ground thru the fogs in my original schematic, a dumb mistake I tend to make when I don't include all of the components.
 

Ian0

Joined Aug 7, 2020
9,667
I thought I'd add my twopenceworth.
Screenshot at 2021-07-13 22-10-55.pngPin 2 = ADJ
When the fog light signal (V2) is on, the Q1/R3 constant current source causes 2mA to flow through R2, dropping about 0.9V across it. The 0.9V is added to the voltage across R1, making the output current equal to (1.2V-0.9V)/R1.
When the fog light signal is off, Q1 is off, and only the normal adj current of 100uA or so flows through R2, so the LM317 operates as normal and Iout = 1.2V/R1
 

Thread Starter

pravardhan

Joined Jul 30, 2009
10
Hi All,

I thank everyone for their time & contribution here.
I have got what I needed from this thread.

Note to Mods: Please close this thread for further reply.

Thanks & Regards,
Pravardhan U.S
 

ThePanMan

Joined Mar 13, 2020
773
@ThePanMan

Just for kicks let's assume each DRL is a module consisting of the circuit presented here.

Now let me ask you a question...

If there are 4 modules one each front/left front/right rear/left rear/right how many poles would be needed in Tony's switch solution?

Point? If you are going to worry about unknowns, you might want to consider all of them, instead of cherry picking.
Two modules - already been stated. But aren't all modules, 1, 2, 4, 22 ? ? ? Aren't they all connected to a single power source? I'm assuming they're being controlled from a single switch. When fog lights come on the DRL's dim. Having a little trouble solving in my mind why you'd have DRL's dim with fog lights in the daytime - but hey! "Build as you desire".

Now, let me turn this around on you - - - are you proposing two controlling systems? Or are the DRL's controlled from a single source?
You show a single DRL. Is your plan for building two of these circuits, one for each DRL or are both DRL's powered from this single circuit?

Cherry picking? Well, perhaps I didn't cover every aspect. But I love to assume the people I'm dealing with are smart enough to figure out the minutia. But hey! The thread starter can build whatever he/she wants, however they want.
 
Top