# Dimmable LED component



## insta (Jan 27, 2010)

Uh, whoa. Sorry to rain on your parade here 

All of those components are tightly-pinpacked SMT components. Next to nobody here is going to be able to use them. They also use a serial communication bus, so you'll have to have a microprocessor to talk to them. At the complexities of LED dimming we'd need, you might as well just use the microprocessor to do it. The 3.5-5.5v is the allowable range for the logic level -- but there's still an entire protocol behind "LED 1, brightness 1330". And it tops out at 2.5W of heat dissipation.

I'm still redrawing the schematics for my LED dimmer (I'd lost them), but it should be easy enough for (most) anyone here to build or use.


----------



## mistergreen (Dec 9, 2006)

No parade rained on.. I clearly stated it uses serial and gave you a link where you can view the schematic. I have a microprocessor.


----------



## PDX-PLT (Feb 14, 2007)

insta said:


> Uh, whoa. Sorry to rain on your parade here
> 
> All of those components are tightly-pinpacked SMT components.


No, it's also available in a PDIP through-hole package (the "NT" suffix).


----------



## Erloas (Dec 14, 2009)

I don't really see the point in this considering the many easy ways of making a PWM circuit with a few very common components.

Also considering that it only drives 16 LEDs, and only the smaller types (none of the 1-3W ones), and the fact that it completely dictates the circuit design and voltage levels then I don't see it as a very great option for most uses.

If you really want a programmable circuit I would just get a PIC chip because they are cheap and easy to find and it would do away with the use of another microprocessor.


----------



## mistergreen (Dec 9, 2006)

I got my nt chip today.. looks like fun.

1 chip drives 16 LED but you can have multiple chips connected in parallel so you can go up to infinity....

the chip requires 3.5v-5v but the LED's max voltage source is 17V. The chip is a drain not a source.



> I don't see it as a very great option for most uses


If you bother to read the pdf, the applications are 'Monocolor, Multicolor, Full-Color LED Displays 2,Display Back-Lighting'


----------



## DarkCobra (Jun 22, 2004)

mistergreen said:


> 1 chip drives 16 LED but you can have multiple chips connected in parallel so you can go up to infinity....


At 17V and 80ma per channel, it can drive more than one ultrabright T1-3/4LED per channel. You might be able to squeeze 96 LEDS on a single chip using serial chains, or even more using serial/parallel chains (trickier).

Do you have plans in mind for this chip, or just playing?


----------



## mistergreen (Dec 9, 2006)

DarkCobra said:


> At 17V and 80ma per channel, it can drive more than one ultrabright T1-3/4LED per channel. You might be able to squeeze 96 LEDS on a single chip using serial chains, or even more using serial/parallel chains (trickier).
> 
> Do you have plans in mind for this chip, or just playing?


wow, thanks for the info.
I have something in mind. I just bought 3 hi-output RBG LED. One LED has 3 channels obviously, ~3V per channel. This is going over a small tank so it might be enough. If not, I'll buy more LED.

So I can play with color instead of regular fading. I want the controller to have an internal clock where in the morning, the light will be orange-yellow; mid-day will be full white; evening will be red-purple; at night will be blue for a moon light situation..

I'll post the experiment. I'll introduce the arduino MC as well.


----------



## Robotguy (Jan 24, 2010)

Looking good *mistergreen*! Can't wait to see how this turns out.

A few questions, if you don't mind:

What LEDs are you using?
Do the RGB LEDs have individual anodes and cathodes for each color?
How are you planning to connect them? 
Are you using the Arduino programming environment (processing, I think it's called) or something else (WinAVR, Codevision, etc.)?
Any plans on utilizing all the leftover processing power of the Arduino?

I don't know if you've run any of the numbers yet, but I was just thinking about it so here goes:

Given 3X RGB @ 80mA
3*Vred*80mA=3*2*80=480mW
3*Vgreen*80mA=3*3.2*80=768mW
3*Vblue*80mA=3*3.2*80=768mW

Total=768*768+480=2016mW

So just a smidge over 2W of LED light (plus the possibility for light shows ;-)


----------



## Im2Nelson4u (Feb 7, 2010)

Uh what kinda LEDs are you using? 

Why not use Cree XP-G LEDs or XR-E? those are like $4-$5 per led and are a lot brighter

The white XR-E uses 3.7V and 1000ma per LED and is really bright.

Also why not use a Meanwell ELN-60-15 LED Driver? Those things put out 15V 4amps and have features such as adjustable +- 25% voltage and amp AND Dimming. 

For dimming they come in 2 flavors D and P type. You can use an arduino to control the D type i think. Its so simple to use just wire it up the a AC prong and series or parallel the leds together and your good to go. The drivers are like $30 each.


----------



## mistergreen (Dec 9, 2006)

Robotguy said:


> Looking good *mistergreen*! Can't wait to see how this turns out.
> 
> A few questions, if you don't mind:
> 
> ...


your project got me thinking about this!

I got the Triple Output High Power RGB LED that you got.. I also bought some cheaper 5mm ones for fun. Thank goodness there are instructions on how to connect the component to the arduino. And I'm using the arduino environment which implements the wiring environment. I have both  There are pre-made libraries to control the tlc5941/tlc5940 (older chip) too so I won't have to spend months coding the thing.

Yes, I'm planning to use every output pins available on the arduino 
It's up to my imagination and wallet.

I think the arduino would be perfect for this hobby. It's powerful, fairly easy to use so people shouldn't be scared of it. Hey, it was made for artists, not engineers. And the price is right at $30. I'll talk more about it in another thread. 

I'm pretty good with processing (java) too so I can build a gui interface for my computer to control these components.


----------



## mistergreen (Dec 9, 2006)

Ok, I've hooked everything up for a test run. 
The LEDs are animated back and forth like the old KITT in Knight Rider.
16 LED of various colored are place on each channels of the tlc5941.










Next step is to have the arduino control RGB LEDs.

All software and how to set up the chip can be found here http://www.arduino.cc/playground/Learning/TLC5940


----------



## Robotguy (Jan 24, 2010)

Looking good!

I ordered my white LEDs from DealExtreme and it looks like they're going to to take forever to get here, so I'll have to live vicariously through you until then.roud: 

Don't forget, we're going to need a video of the flashing led's so we can say "Ooooh! Ahhhh!":icon_bigg


----------



## DarkCobra (Jun 22, 2004)

Sweet! You're well on your way.

I can share some tips on driving LEDs at maximum intensity and efficiency using this chip if you're interested.


----------



## mistergreen (Dec 9, 2006)

DarkCobra said:


> Sweet! You're well on your way.
> 
> I can share some tips on driving LEDs at maximum intensity and efficiency using this chip if you're interested.


yes please!
I was trying to figure it out earlier.
Right now it's drawing 5V from the ardiuno via USB.
Getting the right AMP is important so the chip doesn't blow up.

I want to see if I can hook this guy up.
http://www.sparkfun.com/commerce/product_info.php?products_id=8718
1W per channel so this is a 3W LED.


----------



## DarkCobra (Jun 22, 2004)

Each of the three LEDs in that RGB module requires 350ma to drive at full brightness. Your chip only provides a max of 80ma per channel. So it's not really cut out to drive high power LEDs like that.

However, it may be possible to connect channels in parallel for higher current. Five channels in parallel would give you 400ma, and fifteen channels would drive all three colors. You could also drive up to four of these RGB LEDs by series-connecting each color and using 16-17V drive voltage.

I've read the datasheet, and although it doesn't explicitly say you _can_ parallel channels for higher current, I see nothing that suggests you _can't_.

But I'd advise you test that before proceeding.

Change R(Iref) to 0.48k (for the max of 80ma/channel). Connect two channels in parallel, and connect those to 8 identical standard LEDs in parallel (8*20ma=160ma), each LED connected through a resistor. The resistors help to make sure current is shared evenly across the LEDs, and you can calculate the resistor value here; round down to the nearest value.

Set DOT for both channels to 63 (max power). Make sure you always keep the PWM and DOT for paralleled channels set to the same value, and enable/disable them at the same time; or the channels won't share current evenly. Monitor IC temperature with your finger and be prepared to shut it down if it gets hot; also have your program monitor the Thermal Error Flag and perform auto shutdown if needed. Start at 0% PWM and slowly raise it until you reach 20ma per LED, 160ma total.

If it can successfully power those 8 LEDs @ 20ma each and the chip runs cool with two channels paralleled, it should also do it with more. You could actually test five paralleled channels if you have 18 identical LEDs (18*20ma=360ma) and appropriate resistors, though you might need an external 5V power supply (USB provides 500ma max, on a good day).

Let me know if this works, or if you decide to take a different approach, and we can go from there.


----------



## mistergreen (Dec 9, 2006)

thanks for the write up!

I talked to my dad and he has another option, using transistors to bump up the current and the tlc5941 channel to drive the signal.

it sounds pretty good and leaving all the channels free to control more LEDs.


----------



## DarkCobra (Jun 22, 2004)

mistergreen said:


> I talked to my dad and he has another option, using transistors to bump up the current and the tlc5941 channel to drive the signal.


I'd assumed you wanted to use a minimum of additional components; but that will certainly work!

Although I'm curious, doesn't the Arduino have its own on-chip PWM, either through hardware or an interrupt-driven software library? If so, you may not need the TLC5941 at all. By using external transistors, you're only using it as a PWM signal generator, and not taking advantage of its current drive, current limiting, error detection, etc. (I work with ARM microcontrollers, and don't know much about Arduino.)


----------



## mistergreen (Dec 9, 2006)

The ardiuno does have 6 pins analog out (pwm). I'm looking at the tlc5941 to extend the ardiuno. It's fun trying 

I might use the on board pwm for other things like controlling servos and what not.
The arduino is too powerful to control only LEDs


----------



## Robotguy (Jan 24, 2010)

mistergreen said:


> I might use the on board pwm for other things like controlling servos and what not.
> The arduino is too powerful to control only LEDs


An idea I was thinking about to utilize some of my extra horsepower (I'm using an AVR also) is have my RGBs mimic the moon cycle. I found a pretty simple algorithm for calculating it and you can adjust the brightness depending on the phase of the moon (new=5%, quarter=30%, full=100%):

http://www.faqs.org/faqs/astronomy/faq/part3/section-15.html


----------



## mistergreen (Dec 9, 2006)

Bookmarked!
I know John Conway well 

It's funny how we're using hi-tech to mimic nature.

With the tlc & the rgb led I can tell what color the light would be and even what LED to be on or off. So the light source can move across the tank and doesn't have to be fixed.

I also want to add, I'm a newbie when it comes to electronics. If I can do it, anybody an do it.


----------



## mistergreen (Dec 9, 2006)

ok.. got the transistors from radioshack this afternoon... I had to go twice. I now know the difference between PNP & NPN transistors. I needed PNP transistors to make this work.










a close up.









and the LEDs in action









As you can see, the LEDs are using a 9v battery for power. It's quite bright and the fish looks amazing with the different colors reflecting off them. It was quite a light show. Too bad I don't have a video camera.. I have a web cam somewhere.

The lights will go over the 10G in the picture. Now, before I solder the components together and find reflectors for the LEDs, I'll get working on writing code for the ardiuno to change color and intensity over time.


----------



## insta (Jan 27, 2010)

mistergreen, just curious,

What's the difference between this setup, and a dimmer more like the one I posted a half-page back? This seems like a lot of complexity to begin with, and you're using the chip in a somewhat unusual way to have it drive LEDs it wasn't really meant to drive.

If you're doing it to see if you can, that's one thing and being a fellow engineer/tinkerer I certainly appreciate it  However it seems that a commodity PWM circuit might suit you better ...


----------



## Robotguy (Jan 24, 2010)

mistergreen said:


> I got the Triple Output High Power RGB LED that you got..


Just to let you know, I ended up going with 4X 5W white LEDs from dealextreme, so you're breaking new ground here with high power RGBs as far as I can tell. roud:



mistergreen said:


> So the light source can move across the tank and doesn't have to be fixed.


I can't wait to see this working. It could really make your tank look completely different between morning and afternoon, with all of the shadows in different places. Plus it may allow you to have a longer photo period if some areas are getting somewhat shadowed part of the day, so you can have more time to enjoy the view. I hate it when my lights shut down at 9pm or during the middle of the day on weekends. Hey, with processor controlled lights we can do different photo periods on the weekends when we're home to watch!



mistergreen said:


> I also want to add, I'm a newbie when it comes to electronics. If I can do it, anybody can do it.


You're doing great! And if you need any advice, I do this electronics thing for a living (including the wet stuff) and it sounds like a lot of the others following this thread know their stuff, so feel free to ask questions!


----------



## insta (Jan 27, 2010)

I guess robotguy answered my question.


----------



## mistergreen (Dec 9, 2006)

insta said:


> mistergreen, just curious,
> 
> What's the difference between this setup, and a dimmer more like the one I posted a half-page back? This seems like a lot of complexity to begin with, and you're using the chip in a somewhat unusual way to have it drive LEDs it wasn't really meant to drive.
> 
> If you're doing it to see if you can, that's one thing and being a fellow engineer/tinkerer I certainly appreciate it  However it seems that a commodity PWM circuit might suit you better ...


It's for fun and learning. You'll have to see a video of this in action. My computer died so there will be a bit of a delay. I'm posting from my iPod.

The big grand scheme is to have the arduino control multiple devices and receive data from sensors. And have it interact with an app on my computer. I can write the software easily.


----------



## DarkCobra (Jun 22, 2004)

Looking good!

It looks like you've chosen different resistor values for each color to limit current to a safe value at 100% PWM, correct?

And also, remember what Sparkfun said: "With all three LEDs at 350mA per channel (3W total output), you will need additional heat sinking." So keep your full power tests short.


----------



## mistergreen (Dec 9, 2006)

I wanted 66 ohm resistors for all channels but ran out so I used some 80 ohms 

yeah, not sure how to make the heat sink. It'll have to look nice in the reflector.

Oh and I have a few more channels for 2 more LEDs. Ok off to buy another mac laptop.


----------



## DarkCobra (Jun 22, 2004)

Ah, you're running at a fraction of full power with those resistors. No heat worries yet.

Here's some things I've made custom heatsinks from:

* Blank copper clad PC board
* Aluminum strip, 1" wide by 1/8" thick (hardware store, inexpensive, 3' length cuts with hacksaw)
* Self-adhesive aluminum tape (hardware store, inexpensive, cuts with scissors)
* Heavy-duty kitchen aluminum foil

Attach the LED to the heatsink with heat conductive epoxy; or for something less permanent, heatsink grease and a clamping arrangement. Could be as simple as machine screws, nylon washers, lockwashers, and nuts.


----------



## mistergreen (Dec 9, 2006)

hey, look,
sparkfun sells heat sinks and a lens for the LED.


















do you think the lens is too obtrusive?
I might get it and paint the sides of the lens with a silver paint so it becomes a reflector.


----------



## mistergreen (Dec 9, 2006)

See the light show here. This cycles through all of the available channels. When R, G, B are 100%, white light is produced.

http://s169.photobucket.com/albums/u217/mistergreenphoto/?action=view&current=LED2-Computer.flv


----------



## mistergreen (Dec 9, 2006)

one more movie.
I installed a date/time program into the arduino so it's a fancy timer now. 
I can trigger the LED to fade in or out. The rate on which the channels fade determines the color produced. At some point it's all white.

enjoy.
http://s169.photobucket.com/albums/u217/mistergreenphoto/?action=view&current=Movie.flv


----------



## mistergreen (Dec 9, 2006)

Hi,
I'm looking to buy/forage for parts to complete this. 
I'm looking for a power supply. Is a 9V 600mA ADtoDC power supply enough to power *5* of these LED to their brightest potential?

recap on the LED info.


> 1W per channel, RGB High Power LEDs in one aluminum backed package. These LEDs will blow you away. Light them up then put a coffee cup over the LED to keep your eyes from seeing dots in the periphery. With all three LEDs at 350mA per channel (3W total output)
> 
> Forward Voltage:
> Red: 2.2-2.6V
> ...


thanks,


----------



## Robotguy (Jan 24, 2010)

mistergreen said:


> Hi,
> Is a 9V 600mA ADtoDC power supply enough to power *5* of these LED to their brightest potential?


5X (red AND green AND blue), so 15 actual LEDs? Or 5x (red OR green OR blue), 5 LEDs? 

I am guessing you want 5X (red AND green AND blue) for maximum control and coolness factor? :icon_cool

I'm going to say, no, that power supply won't do it. These things pull up to 350 mA. With 600mA available thats less than 2 strings (sets of LEDs in series), and with 9V available you can only get 3X red or 2X blue or green on a string.

Since you want to control each color separately (for mixing) and each LED separately (for "moving" the light across the tank), you will need a power supply that can put out 15*.35A=5.25A at just over 3.8V if you want all of the LEDs at full brightness at once. With that much power, according to the datasheet you'd be getting 37(R)+13(B)+57(G)=118 Lumens, from each LED, so 590 Lumens total.

I have a power supply (pulled from a micro-pc) that puts out [email protected] and [email protected] I'd be happy to RAOK if you can't find something locally. It's in a metal box 7.5" X 2.25" X 1.75" and takes a standard IEC cord. I can post a pic if you like.


----------



## mistergreen (Dec 9, 2006)

thanks for the analysis.

This brings up another question. Parallel vs Series.
Right now, on my breadboard, the LEDs are laid out in a parallel circuit. Would the power supply change in this setup and not a series?

And what's the advantage of one over the other?
Just from my basic understanding:
Parallel- a component can die but won't take out the whole application
Series- easier to connect and work out


----------



## insta (Jan 27, 2010)

In parallel, every component gets the same voltage applied to it. In series, every component gets the same current.

Be careful when paralleling large numbers of LEDs together. You will want to ensure that each LED has its own current-limiting resistor. I know mathematically it works out to have a single big resistor for all LEDs, but since LEDs are imperfect devices this will eventually lead to one taking slightly more current and burning out ... leading to a spiral where all of them burn out quickly afterwards.

I would suggest seriesing them together to get close-to but under your supply voltage, then use the smallest current limiting resistor you can on each series string. Parallel these strings together as necessary. If your LEDs are 1.7v, 20ma LEDs, and you have a 9v supply, put 5 of them in series. This gives you 8.5v of voltage drop, meaning you need a 25ohm, 1/8W resistor.

Of course, I'm also assuming that your chip can drive an output transistor in PWM fashion to do so. If you're driving the LEDs straight from the chip this is all out the window.

Feel free to PM me with questions -- I do a lot with electronics


----------



## Robotguy (Jan 24, 2010)

mistergreen said:


> Parallel- a component can die but won't take out the whole application
> Series- easier to connect and work out


Additionally, all LEDs in series will get the same current, therefore be at the same 'dim level'*.

Your two main options are "colors in series" where you can control the colors, but all modules show the same color/brightness:








With this option you will need more than 19V (5*3.8) at 1.05A (3*.350). If any of the LED's die, none of the LEDs of that color will work.

or "everything in parallel" where you can control color/brightness individuallt for each module:








Here you will need >3.8V (1*3.8) at 5.25A (15*.35). Any of the LEDs can die without affecting the others.

There is a third option where the three colors from each LED are in series, but you would always get white, and I know you want to control the colors. 


*Not necessarily the same brightness. You can put two different LEDs with different efficiencies in series and while they will receive the same current, the more efficient LED will be brighter.


----------



## mistergreen (Dec 9, 2006)

thanks for info info guys! I hope everybody finds this as interesting as I do.

I think I will keep it 'everything in parallel'. I think I have a 6V @5A power supply somewhere.


----------



## DarkCobra (Jun 22, 2004)

Excellent advice on the series/parallel options.

Some miscellanous thoughts:

Mistergreen, did you get the 15-pk "PNP Amplifying Transistors" Model 2N3906 from Radio Shack? If so, note that they're only rated for a continuous current of 200ma.

Here's a handy guide on using transistors as switches. It's very concise. 

That 6V 5A power supply will work, although 5*3*0.350=5.25A. You might just not be able to light everything simultaneously to max intensity.

I can also RAOK some stuff if you need. I'm pretty sure I have a spare 5V >5A switching regulated wall wart. And some MPSA56 PNP TO-92 transistors rated for 500ma. Quite a few resistors and other stuff too. Let me know.


----------



## mistergreen (Dec 9, 2006)

oh, you're right about the transistors, it's actually rated for 100mA.
RadioShack also sells the big heavy duty one, 10A. It's like $2 for a pack.


----------

