0
\$\begingroup\$

I have a bunch of LEDs (all the same part number / specification) that I want to light up using a shift register. The trouble is, each output bit should control a different number of LEDs (depending on the bit, any of 2, 3 or 4 LEDs). Regardless, every individual LED should be equally bright.

IIUC, just feeding the LEDs their forward voltage... isn't recommended.

I suppose I could pair every single LED with a resistor and feed them 5V, with a FET to switch each group, but that's a lot of resistors. (And I do need one per LED, because one per group will cause the remainder to cook if one of the group goes open-circuit.) I know constant-current drivers exist, but I'm not familiar with their use, and the amount of current is highly variable. Another (not-ideal) option would be to use the same number of LEDs but "hide" some of them somehow (or maybe use a non-light-emitting diode with the same voltage drop?) so every group needs the same current.

What's the most "efficient" (in terms of power used, cost, and fewest components) way to accomplish this?

I'm not wedded to the shift register if there's an array driver that can cope with different current per channel and provides a way to update 32 channels concurrently¹. I am hoping for something that only needs two wires to drive it, however, and ideally can accept a full array update in 40 bits or less.

(¹ "Daisy-chaining" serial-input 8- or 16-bit controllers is fine as long as the output changes 'all at once'.)

p.s. If your answer involves a driver, please also explain how to either set the per-channel current to 2X, 3X or 4X, or where to find a driver that can handle ~15V (since most recommend no more than ~6V).

\$\endgroup\$
1
  • 1
    \$\begingroup\$ Please keep arguments focused on problems not people. Don't call people out and be nice. Thanks \$\endgroup\$
    – Voltage Spike
    Oct 10, 2023 at 20:00

2 Answers 2

0
\$\begingroup\$

You should use a shift register-type LED driver. These are devices that use a single resistor to program an internal current sink for each channel simultaneously so your LED strings should be fairly equally matched. Interface should be very similar to your shift register setup.

Edit: you can find them in 32-channel models but you might just want to split it up into a few 8- or 16-channel devices to help with fan-out and heat dissipation. You can cascade multiple devices easily and run them all off a common latch signal.

\$\endgroup\$
6
  • \$\begingroup\$ How does that account for each channel needing a different amount of current? \$\endgroup\$
    – Matthew
    Oct 9, 2023 at 22:36
  • \$\begingroup\$ Each LED in the group should be connected in a series string. That's the only way to ensure that they all have the same current through them. You would then use a voltage source that is higher than the forward voltage drop of the largest string to power the LEDs (but not necessarily the driver). \$\endgroup\$
    – vir
    Oct 9, 2023 at 22:43
  • \$\begingroup\$ @Matthew, it would be better if you were not so direct and said "Could you put that comment in the answer". \$\endgroup\$
    – Voltage Spike
    Oct 10, 2023 at 20:02
  • \$\begingroup\$ @Matthew Yeah, that's frustrating. But one does not have to be negative about it. These people are donating time, in addtiion you could just say "Could you improve your answer" instead of demanding that they do so. A good rule of life is not to make demands of those who are trying to help. \$\endgroup\$
    – Voltage Spike
    Oct 10, 2023 at 20:16
  • \$\begingroup\$ Okay, but it would help if that was in your answer instead of buried in a comment. However, what am I supposed to do if I don't have that much voltage? I have 5V. I'm don't know exactly what LEDs I'm going to be using yet, but probably they will have V<sub>fw</sub> 3.0V - 3.7V. IIUC, that means I not only need to get 13V - 16V out of that 5V (okay, I have heard of "boost converters"), but that I need a driver that doesn't mind ≥13V. (Also, how much of that is going to turn into heat when I only need half of it?) \$\endgroup\$
    – Matthew
    Oct 10, 2023 at 20:32
0
\$\begingroup\$

After more digging, I came up with five options, none of which are perfect...

Use a shift-register LED driver instead of a shift register

...and drive each LED separately.

Pros

  • Relatively simple to build.

Cons

  • Programming bits need to be repeated, making programming more complicated and increasing the time needed to transmit an update. (There may be alternatives to programming each LED separately, but none come to mind that don't significantly increase overall complexity.)

Use a boost-ready driver

...and wire each group in series instead of in parallel.

Pros

  • Relatively simple to build.

Cons

  • If one LED dies, the whole group dies.
  • The required voltage increases geometrically with the number of LEDs. Aside from low-voltage (~1V) LEDs which I'm not using, this means the driver needs to be able to handle "high" (>12V) input voltage.
  • Each group needs to dissipate the voltage of a 4-group. That means 2-groups need to drop at least half the input voltage in the driver.
  • While I found drivers that will tolerate the necessary input voltage, I didn't know to check at the time if they'll tolerate how much voltage needs to be dropped in the driver for a 2-group.

Use a lot of resistors

Pros

  • Simple and easy to drive.
  • Each LED is independent; failures don't affect the rest of the group.

Cons

  • Uses a lot of resistors.

Use a lot of single-channel constant current drivers

Pros

  • Simple and easy to drive.
  • Each LED is independent; failures don't affect the rest of the group.

Cons

  • Uses a lot of individual drivers.
  • Current adjustment requires using different drivers.
  • Drivers are around 25¢ each even at volume.

Use multiple, non-programmable 2-4 channel drivers

Pros

  • Easy to drive; equivalent to per-LED drivers or resistors.
  • Cheaper than using separate drivers per LED.
  • Current is adjustable via resistor.

Cons

  • Requires a similar or greater total number of parts as single-component-per-LED solutions.
  • Larger chips result in more difficult board layout.

I'm not sure which way I'm going to go. Using individual drivers is dead simple, but expensive. Using 4-channel drivers makes the boards significantly more complex but reduces BOM cost significantly. Both would allow PWM "dimming".

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.