Go Down

Topic: TLC5940 + high current + keep the constant current sink (looking for part) (Read 4215 times) previous topic - next topic

Hi Community!
I'm experimenting with TLC5940 and some LED's. Works great so far (3 chained TLC on 16 RGB-Leds)!
Now the tricky part:
The TLC provides 120mA. Now I'd like to drive a power consuming LED (a Seoul P5 to be exactly http://www.farnell.com/datasheets/615004.pdf).
This hungry piece consumes 350mA per color.
I read about solutions driving the Led via a MOSFET/Transistor/Darlington Arrays http://www.ti.com/lit/an/slva280/slva280.pdf. In my understanding i'm losing the constant current sink with this solution, so my LED is driven via resistor, which i'd like to avoid.
My solution in dreams is a constant current sink providing my led with 350mA/color - and this constant current sink takes its information about dimming (pwm) from the TLC.
I crawled farnell a lot -  but i didn't find any proper part (i also did'n know what i was searching for  XD) Can you help me out?
This problem was discussed on many places here and in some other tinkerforums (GrumpyMike provided a lot of helpful information - thanks a lot) so i feel a little bit awkward asking this again. As said it's important to have a constant current sink when driving such hungry leds...and i think all given solutions break up with this.
Thank you for helping me!


EVP

http://uk.farnell.com/xp-power/ldu0830s350-wd/led-driver-dc-dc-8w-wired/dp/1961526


This will do the job, it has a PWM input. It's at 1.25 volt (the pwm input) i think so you have to sort that out. I used a potential divider on the output's. Other than that it need's no other components. There is a good range of mA if you have a look. This is the link for a 350 mA.

Hi!
Thanks for your advice!
Nice part - but definitly too expensive! I searched for similar parts and found this http://uk.farnell.com/microchip/mcp1640t-i-chy/boost-regler-synchr-500khz-6sot23/dp/1800205  - far cheaper! Are both compareable? Keep in mind that i need 16*3 of those ;) So i also need to care the price....

EVP

dont really know hat that is for, it doesn't say anything about constant currant so i'd guess it might not be what you want.

http://uk.farnell.com/jsp/search/productdetail.jsp?SKU=1898428

This would be more like it i think, there is similar one , don't know if this is the cheapest. it might go down on price if you buy more.

dc42


I searched for similar parts and found this http://uk.farnell.com/microchip/mcp1640t-i-chy/boost-regler-synchr-500khz-6sot23/dp/1800205  - far cheaper! Are both compareable? Keep in mind that i need 16*3 of those ;) So i also need to care the price....


That part is not comparable, it's a step-up switching regulator, not a constant current device.

Unfortunately, there is no easy solution to the problem. What you are looking for is a current mirror with a gain of several times between the input and the output. Such devices exist internally to some integrated circuits, but I'm not aware of any devices you can buy just for this function, certainly not with an output of 350mA.

Here are some solutions:

1. Use PNP transistors to drive the LEDs. As you said, this loses the benefit of the constant current output; so you need either a series resistor for each LED, or else a second transistor and resistor to form a constant current source.

2. Parallel several TLC5940 outputs to drive each LED. For example, use three chains of TLC5940s driven from the same clock, data and latch lines, with the outputs connected in parallel. This gets quite expensive because the TLC5940 isn't cheap.

3. Use plain shift registers and do software PWM (ShiftPWM library) instead of using TLC5940s. Use transistors or constant current drivers as in solution (1).
Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

#5
Dec 10, 2011, 11:14 pm Last Edit: Dec 11, 2011, 12:16 am by OptimusPrime Reason: 1
Thank you for the effort!
dc42:
i think its technically the best way to build up a constant current source by my own.
I found some circuits online and it might look like this in the end:

Im quite unsure how this works - also with this nasty PNP/NPN problem (i always mix up the two). Also i will have to plan it for 350mA and additionally i need a control pin to turn this on and off(do i need special transistors due to pwm?) Isn't it strange that i cant buy this in an ic?

This will make my circuit more complex than expected!

EVP:
I'd like not to change the code (the tlc arduino lib is soooooo nice <3 ) - and also this part is quite expensive. 2,95€ when i take 16 which is 47,5€. Now i pay about 10€ for my tlc's and i guess if i do dc42's solution with 2 transistors i'll end up at about 20€ for the whole circuit.

Thank you both for your input!
I'd be glad if you could drop a few lines about the homemade constant current sink above!

----ADDED----
I just read some interesting things about Constant Current Sources! In this example a voltage regulator is "abused" as ccs. The ic is an LM317 http://www.farnell.com/datasheets/76338.pdf

Here appear some BIG questionmarks! How do i turn it on or off? Simply by transistor at the end? And there is again this PNP/NPN thing...



dc42

That first circuit is OK. If you were driving it direct from an Arduino pin, you would disconnect the right hand end of the 4k7 resistor and connect it to the pin instead. To adjust the LED current, adjust the value of the 30 ohm resistor to give the required current when there is around 0.65v across it. For 350mA, the 4K7 resistor would also need to be reduced to provide sufficient base current.

Since you want to drive it from a TLC5940 output, you'll need to invert it, i.e. use PNP transistors instead of NPN and put it in the high side of the LED supply. You don't need the 4k7 resistor, you can drive the circuit direct from the TLC5940 output, with the TLC5940 set to produce a low current e.g. 15mA.

The circuit using the LM317 is not suitable for PWM applications.
Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Hmm...ok! That is very helpful about the first circuit. At the moment i am creating a eagle file for this  - i hope things become more clear then.
I don't get the second one...why can't i do like him? http://arduino.cc/forum/index.php/topic,80353.0.html
My approach would be similar:
Create an ccs with the lm317 and interrupt it with a FET before the LED's GND. Then drive the Fet with the Tlc.
Thank you so much for helping me (and excuse my stupid questions ;) )! I am learning a lot of new stuff right now!

This is what i planned (attachment) - i have to say that i didn't understand what i was drawing. How do you figuered out the 0.65v? You also said:
Quote
...the 4K7 resistor would also need...

but:
Quote
...You don't need the 4k7 resistor...

In my diagram it misses...

I guess this will f*** me up when it comes to soldering. I need this 48 times. I will also need Common Cathode RGB Leds, right?

EVP

[url]http://www.satisled.com/Wholesale-rgb-full-color_c27[/ur]

I got my led's from here, they were fine and a lot cheaper than anywhere else. You can chooses the common, and get them in diffused or clear. Diffused is best. The odd one's colour is a bit of, depends how picky you are i suppose.

dc42


This is what i planned (attachment) - i have to say that i didn't understand what i was drawing. How do you figuered out the 0.65v?


The PNP transistor and resistor on the left hand side of your circuit needs to be in the emitter circuit of the other transistor, not the collector circuit. The 0.65v is the approximate voltage between a transistor's base and emitter at which it starts conducting. You'll also hear this quoted as 0.6v and 0.7v.


I will also need Common Cathode RGB Leds, right?


Yes, or LEDs that have independent connections for the 3 LEDs (6 pins in all) - such as the ones you said you were planning to use.
Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

EVP:
Best toy store ever :D Quite cheap if i compare them to the planned Seoul P5! Do you know how good colors are mixing for example with this one? http://www.satisled.com/10w-9w-rgb-led-emitter-3w-for-each-color_p236.html Or do you know which diffusers are matching them? I already wrote a question to the shops tech support. I have a 10w white high power led ordered from ebay http://www.ebay.de/itm/120563047449 which looks similar. Very bright and a lot of fun to play around (try strobe effects! ;) )! As mentioned i expect a not very homogenous lighting when using this in rgb without diffuser.

dc42:
I will give it another try! I'm searching for a explanation why this works and where the regulation in current happens (i hate working with black boxes :) ).
Did i calc the resistor the right way? It was like: "Oh, let's take 0.65V, gimme 350mA -> divide ==> 1,8 Ohm Resistor"
The Common Cathode/Anode is all fine - i just need leds which are freely configurable (which all are i mentioned)

I still 'd like to know why the LM317 will not work ;)

Thank you guys! You are great!

dc42


Did i calc the resistor the right way? It was like: "Oh, let's take 0.65V, gimme 350mA -> divide ==> 1,8 Ohm Resistor"


Yes, although the 0.65v is an approximate value (it depends on the type of transistors you use), so you may need to experiment to find exactly the right value it you want to run your LEDs at their maximum current. That voltage decreases with temperature, so the current will be highest at low temperatures.


I still 'd like to know why the LM317 will not work ;)


I guess it would work if the PWM frequency is not too high, but you'd need to use a transistor or mosfet to switch the power somewhere, and the voltage drop would be higher.
Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

#13
Dec 11, 2011, 03:38 pm Last Edit: Dec 11, 2011, 03:53 pm by OptimusPrime Reason: 1
Ok! Fine!
I hooked it up again (attachment). Could it be that there is a mistake in my first try from yesterday with the upper right transistor? Its emitter is facing to Vcc - this is wrong, isn't it?
Also interesting for all german speaking people: http://www.hobby-bastelecke.de/grundschaltungen/konstantstromquelle2.htm
Very "humanreadable" explanation of the constant current source with 2 transistors - just to share this here...

Parallel i was looking for a part that provides many transistors in one package to make manifacturing easier, and i found this transistor array:( http://www.fairchildsemi.com/ds/FF/FFB2907A.pdf <- not available in germany...my bad. Alternative: http://www.nxp.com/documents/data_sheet/PBSS4041SP.pdf )

For the LM317 thing: i planned it in eagle and in comparison with the 2 transistor circuit the soldering effort will be the same (i was assuming that i need fewer parts when using the LM317)


dc42


I hooked it up again (attachment). Could it be that there is a mistake in my first try from yesterday with the upper right transistor? Its emitter is facing to Vcc - this is wrong, isn't it?


Yes it is. See attached sketch.


Parallel i was looking for a part that provides many transistors in one package to make manifacturing easier, and i found this transistor array: http://www.fairchildsemi.com/ds/FF/FFB2907A.pdf


The transistor driving the LED needs to be chosen quite carefully because of the relatively high current you are using. It needs to pass the 350mA while maintaining a good hfe and a low Vce(sat). It also needs to handle the power dissipation. The worst case power dissipation is the red LED because it has the lowest voltage drop (2.6v typical). So the voltage drop across the transistor will be around 5 - 2.6 - 0.65, which comes to around 1.75v. At 350mA current the power dissipated will be 613mW. This is right at the limit for a typical TO92-style transistor such as the BC327. You could put a 2.7 ohm resistor in series with the red LED to bring its voltage drop up to the same as the green and blue LEDs.

The problem with using a transistor array is that the package has to dissipate the total power for all the transistors. Also, the Vce(sat) of that array at 350mA is probably far too high, judging from the values quoted at 500mA. Even with a good transistor, the green LED has a worst case voltage drop of 4.2v, and you lose about 0.65v in the current sense resistor, so you really need a transistor with a Vce(sat) of only 0.15v at 350mA. You may find that a BC327 is not good enough and you need a small power transistor instead. If you are planning SMT manufacturing than that would be your best option anyway, maybe something like http://uk.rs-online.com/web/p/general-purpose-transistor/7114960/.

The other transistor in the circuit is much less critical and could be part of an array.


For the LM317 thing: i planned it in eagle and in comparison with the 2 transistor circuit the soldering effort will be the same (i was assuming that i need fewer parts when using the LM317)


For the LM317, you need one resistor and a capacitor for the LM317 itself, plus a transistor or mosfet and at least one more resistor to switch it. So more soldering effort.
Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Go Up