Electronic – Current limiting from a USB supply

current-limitingledpowerusb

I am designing a device which must power a number of RGB LEDs. I am currently looking at WS2812 "NeoPixel" style LEDs, which have a max current draw of 60mA each. I would like to have a large number of these, but running at lower brightnesses.

The problem is that I want to supply this from a standard USB port, and I have more critical functions that run off of the same USB power, so I want some sort of current limiter/protection to ensure that the LEDs don't consume so much current that the USB controller shuts off the device.

  • Would a simple PTC/Re-settable fuse work?
  • Or something like this current limiter from Wikipedia.
  • Or should the supply be cut completely?

I don't need very high accuracy,but I would like to keep current under ~250mA±30mA.

Also since I need >100mA from the USB VBUS should I include a MOSFET or other way to disable the supply while the microcontroller is starting/restarting.

Finally I have seen some people recommend large(100-1000uF) smoothing capacitors to the LED's VCC. Which side of the protection should this be on?

Best Answer

Would a simple PTC/Re-settable fuse work?

PTC's are very slow. This is often used in the host to prevent board damage because they are cheap. If you want any selectivity (eg: your protection tripping first) you'd want something faster.

Or something like this current limiter from Wikipedia.

A current limiter will prevent you from tripping the host protection, but will also cause brownout on the microcontroller or ws2812.

Or should the supply be cut completely?

Yes, you want the power to trip immediately without your microcontroller browning out or the host protection to trip. Prevent the USB connection to be lost.
Luckily you can get current limited power switches. Take a look at mic20xx for example.