# Using Microchip CL2 Current limiter



## ncrc5315 (Jan 25, 2014)

I came across these:
http://ww1.microchip.com/downloads/en/DeviceDoc/20005448A.pdf

Would this not be a better choice for powering LED's, then using resistors to limit current?


----------



## wvgca (Jan 21, 2013)

well, yes and no
it drives each led at pretty much full brightness, which you may or may not want
it's a higher cost and limited availability compared to resistors,
to reduce current you have to run multiple leds, again depends on end usage


----------



## gunrunnerjohn (Nov 10, 2010)

I've used those in the past, and they are good for some applications. Remember, with the CL2, you need filtered DC, so you need a filter cap as well as the diode to generate the DC from the track power if you're powering with AC. If you run MTH DCS, you also need a choke to prevent interference with the DCS signal on the tracks.

I like constant current for LED's, so my LED lighting module uses a constant current source, but I also have a pot to adjust the current for intensity control. Here's the modules and the schematic of what's on them. These offer DCS compatibility, flicker-free performance, and intensity control in a nice compact package.


----------



## gregc (Apr 25, 2015)

if you have a varying voltage, you might consider the lm317 in plastic. a resistor sets the current


----------



## ncrc5315 (Jan 25, 2014)

First of all, thank you for your reply's. Here is what I was thinking of doing, creating a PCB board to go inside a HO locomotive, for conversion from bulbs to LED's. I am using DCC.


----------



## Dennis461 (Jan 5, 2018)

Go check out this thread post 21
http://www.modeltrainforum.com/showthread.php?t=21405&highlight=LM334Z&page=3

Build that circuit and let us know how it works out.
I may try it as my LED headlights come on in forward and reverse, tried many things to fix it.


----------



## gunrunnerjohn (Nov 10, 2010)

Dennis461 said:


> Go check out this thread post 21
> http://www.modeltrainforum.com/showthread.php?t=21405&highlight=LM334Z&page=3
> 
> Build that circuit and let us know how it works out.
> I may try it as my LED headlights come on in forward and reverse, tried many things to fix it.


That's the same basic circuit as I use with the LM317T. Note that it requires filtered DC, so if you're running from AC track power, you need a capacitor and diode at the minimum. Even for DC track power, you need a capacitor, and if the polarity reverses, you'd need a bridge rectifier in front of it.

The other difference is that the part you specify is only good for 10ma maximum. The LM334Z is a low power device. Since I use my module to light a whole string of LED's in passenger cars, I need more than 10ma for decent intensity.


----------



## Lemonhawk (Sep 24, 2013)

I used a CL2 to light LED's in a passenger car, but as others have said, it outputs 20 ma so it takes some messing around to dim the LED's. Better to use grj's circuit. I've been experimenting with ws2812 LED drivers since you can really control the color and brightness, but it takes an Arduino to generate the pulse train so you have hide a lot of circuitry. I see putting these LED's all over the layout all connected in series (power is parallel) then programming each one with whatever you want. And you can animate the effects and change your mind.


----------

