ULN2003 - PWM led driver & 3 watt LED's

I made a nano board attached to ULN2003, runs at 12v into transistor array. If I calculate correct, 12v @ 250 ma = 3 watts [3 watts = (3) led modules, 1 watt each wired in parallel]. If I read the data-sheet correctly my notes for the ULN2003 are 500 ma for EACH SIGNAL output which puts me about the 1/2 way mark for comfortable safety purposes.

Please correct me if I am wrong. For testing CURRENT purpose: I hook up my cheap hand-held DMM, inline with the +12v, out from DMM to LED+, and LED- goes to the transistor lead. I trigger my PWM arduino to mimum pulse width. I extend width pulse until my DMM can read about 250 ma. Whatever that pulse width is when reading "250" is my maximum limit I should consider safe use. If an unpredicted event happens, my Arduino locks up - and transistor locked high, I just expect my 3-watt LED should burn out, and cancel the circuit.

By limiting the width of that pulse is how I limit my current - correct?

By limiting the width of that pulse is how I limit my current - correct?

No. That will control-limit the average current which affects perceived brightness. And, most DMMs won't read pulsed voltage or current accurately. DMMs work with DC or AC sine waves. If you have an old electro-mechanical meter (with a needle indicator), the inertia is pretty-good at averaging.

If your "LED modules" are rated for 12V at 250mA, they should draw 250mA when you apply 12V. ...That's for something like an LED strip with current limiting resistors built-in.

If you have "raw" high-power LEDs, they require a constant-current source, which is usually a switching-type of circuit with an inductor and feedback-control. (Simple PWW voltage switching will not work.)

The led modules are just little 1-WATT CREE (or generic) led's, 3 of them mounted in parallel on a board (module). There is no limiting circuitry. I thought the limit was the width of the PWM going to the module. I figured my controller simply limits a 15% duty cycle - in an open loop.

DocStein99:
If I read the data-sheet correctly my notes for the ULN2003 are 500 ma for EACH SIGNAL output which puts me about the 1/2 way mark for comfortable safety purposes.

Current is not the only limitiation.
3250mA generates about 3250mA*1volt dropout in the ULN = 750mW of heat in the ULN.
Chip temp could rise 50C above ambient (~75C).

PWM is switching between off and 100% on, so can't be used for current limiting.
I would suggest a 4.7ohm resistor in series with each LED.
Leo..

Forget about driving those things with a '2003. I've tried it - there is a huge gulf between the impression of the capabilities of those that you get from a naive read of the datasheet, and what they can actually do. I tried this myself, and it was very disappointing. Don't use them for more than 100mA per channel and expect to walk away happy.

Get some logic level mosfets, and use series resistors or better yet a constant current driver like the amc7135.

The AMC7135 is linear, so also gets hot. And supply limit is 6volt.
Two supplies are needed if the LED (Vf~10volt) is powered from 12volt.
Good solution though if you want to power a single 1watt LED from a 5volt supply.
Leo..

Wawa:
I would suggest a 4.7ohm resistor in series with each LED.
Leo..

Ok I have those, in 1/4 watt. If I'm passing 3+ watts, I need larger wattage?

If... you use COB LEDs with three white/green/blue (not red) LEDs in a string (Vf ~9.5v-10v) and the ULN drops ~1volt, and the supply is 12volt, then the remaining 1.5-2volt will drop across the resistor.

1volt/4.7ohm = 212mA = 10.212A = 0.212watt.
1.5volt/4.7ohm = 319mA = 1.5
0.319 = 0.478watt.

If you only have 1/4watt resistors, use two 10ohm/1/4watt in parallel to make a 5ohm/0.5watt resistor.

You see that voltage and parts variation have a big influence on linear LED drive.
Switching LED drivers are immune to voltage variations, and are much more efficient (less heat).
Leo..

Ok WaWa thanks for helping me clear up the current-limit resistor mystery. I'm too cheap for (2) $14.00 buck-down converters - but that was interesting to learn about.

The amc7135 works for higher voltages - just use a 1k resistor and 5v zener, and switch the whole low side and they work like a charm. Or use a 7140

Linear LED drivers have their place, but I like to use the switching types for efficiency.
See my latest fully stand-alone 16-channel (3-7 LEDs per channel) LED driver design.
Includes 3.3volt Pololu supply and ESP8266-12 WiFi Arduino mounted underneath.
Leo..

Wawa: The board is impressive. I know the transistors are not the best thing to use. I just want to get these lights in my ceiling and replace the dumb incandescent bulb fixture out of there. I do not have time to re-do my whole board, and learn about designing a switched regulated power supply - before my patience runs out with the terrible lighting in this room.

The datasheet for "amc7135" explains - "Supply voltage range 2.7V ~ 6V". This is not high voltage. "AMC7140" datasheet explains - "Wide Supply Voltage Range: 5V~50V. ". Neither of these come up when I quick search "AMC7135" or "AMC7140" in Digikey, Mouser, or Jameco. They DO on eBay, and cost for each AMC7140 is about $1.00.

Is there a reason to place a current limiting coil circuit on EACH channel? Why not pulse output one channel at a time? If only one channel is active at any given time - it should only draw the power for one coil.

No muxing, because each channel has individual 12-bit dimming.
This board, and a slave board connected to it, controls all the LED downlights in my basement/workshop.
About 300watt of downlights, fully automated with timers daylight sensors and movement sensors.
Leo..

You can drive all those channels from a single constant current supply and PWM them all separately...

Its not a very practical technique due to the high voltages and risk of interference, but for constant current
you PWM by shorting across the load with a switching device. You'd need opto-isolation of course, and the
large voltage swings would be a nightmare, but its probably possible to do a small number of channels that
way (2 or 3) without big issues, and reduce the number of supplies needed.

On that same sparkfun site, there's a 16-channel constant current driver up to 17v for $13 whole dollars. The hidden details must be looked up in that datasheet, 120 ma current limit per channel :frowning:

When powered from 5volt, with 16* ~3.3volt LEDs @120mA each, (5-3.3)0.1216 = 3.26watt is lost in the chip. 1/3 of the power supply is lost in heating up the chip (to stinking hot). 60mA seems ok though.
Leo..

Yea the VIDEO on that page makes it out that they guy lights up the conference room with it. I know it's not true - but thanks SPARKFUN for misleading newbie's.

They are using several LED driver boards, and maybe 10watt worth of LED light can give a nice effect.
Not suitable for general lighting though.
Leo..

I just found in my box of stuff, a whole bunch of these:

eBay 10w constant current led driver

The chips are BLEACHED out on mine. So I dug around the interwebs, after 20 minutes I discovered the chip on the driver is:

PT4115

The modules are big enough for me to modify. According to the document, there's a "dim" pin where I can control a pulse externally.

I drive +12v in from my power supply, voltage out is 10.5v. DIM pin tests HIGH. I put 10k resistor from chip's "GND-A" pin to "DIM" - and my test 10w COB LED shuts off.

My multi-meter was current reading 650ma output between the positive pin and the led positive.