USB-C PD Teensy4.1 Powered LED Strip

Status
Not open for further replies.

jrsmile

Member
Hi,

i am currently trying to get a project going that exceeds the max power requirements of usb2.0 and even 3.0.
i want to use a teensy 4.1 with 120 WS2813 LEDs a keyboard matrix and an 1,3" oled screen from a single usb-c port.
i read a lot and came to a site tindie project that should make it possible https://www.tindie.com/products/clarahobbs/pd-buddy-wye/
the power should come from a usb-c pd trigger board for the leds and the teensy.
the maximum power consumption for a nvidia gforce rtx usb-c port is 27 watts or 3A at 9V. which is my project maximum for compatibility reasons.
i will use a dc-dc power supply module to regulate the 9v down to 5 for teensy and LED Strip.
the ws2813 is 60 ma *120 = 7,2 A * 5V = 36W.

is there any chance this is feasible and can be limited in software to lets say 25Watts?
is it enough to set a brightness limit?
does the teensy work with only usb2 data lines attached,?
 
Sounds like an interesting project. I'm also working on a keyboard with high power requirements (LCD and backlights). vjmuzik's advice is good, that's what I was planning on doing, though I wasn't planning on adding a second power supply and just keeping the LED brightnesses way down (either by dimming the whole panel or only having a few bright LEDs on at once.)

If you do want an always-on external power supply, you can cut the VIN-VUSB jumper on the back of the board and power the teensy via the VIN pin.

Alternatively, you should be able to power just the LEDs from the external supply and leave the Teensy to be powered by its own USB port.
 
Alternatively, you should be able to power just the LEDs from the external supply and leave the Teensy to be powered by its own USB port.
They would have to have a common ground, and the data line from the Teensy has to have a similar voltage to the + terminal going into the LEDs. For example, if you are running the LEDs at 5V and the data line is 3.3V, the signal will not be understood by the LED drivers. (At least, this was true with WS2812, not sure about WS2813. I think I was able to get it to work at something like 4.1 volts using a 5V regulator with a small resistor on the ground pin.)

Since OP wants to limit the brightness, maybe running the whole array at 3.3V would be fine. You don't get max brightness, but it's already eye-wateringly bright at 3.3V.

The other option is to use a level shifter to step the 3.3V on the data line up to 5V.
 
They would have to have a common ground, and the data line from the Teensy has to have a similar voltage to the + terminal going into the LEDs. For example, if you are running the LEDs at 5V and the data line is 3.3V, the signal will not be understood by the LED drivers. (At least, this was true with WS2812, not sure about WS2813. I think I was able to get it to work at something like 4.1 volts using a 5V regulator with a small resistor on the ground pin.)

Since OP wants to limit the brightness, maybe running the whole array at 3.3V would be fine. You don't get max brightness, but it's already eye-wateringly bright at 3.3V.

The other option is to use a level shifter to step the 3.3V on the data line up to 5V.
Agreed, they'll definitely need to share a ground. The WS2813's have a minimum VDD of 3.5v, so I wouldn't run them at 3.3. And at 5v, they'll need 3.5v for the data line, so they'll need a level translator of some kind for the data pin. (It _might_ work, but may not be reliable without the translator.)

As far as the brightness goes, I'd test it and see how many watts is really needed for your application. At full brightness it may be, as you say, eye-waveringly bright. :)

One downside of the running them dimmed is that you lose steps of brightness control (i.e. If you run it at maximum 1/4 brightness, you'll only get 64 steps, which may not be fine enough at low brightnesses.) There is a version of the WS2812 (WS2812C-2020) that has a maximum 15mA per chip, which if bright enough, might be a solution that fixes the power requirements and provide brightness control. This is what I'm looking at for my keyboard design.
 
That's one of the things I liked about running the WS2812s at 3.3V. Each increment in brightness was smaller than it would be at 5.5V. This makes for smoother fades.

If the WS2813s really can't run below 3.5V, I would honestly think about using WS2812s instead. The WS2813s can recover from burnt-out drivers, and the refresh rate is higher, but other than that there's no advantage. They use the same one-wire signaling protocol as WS2812s, and they cost more money.
 
i might have solved my power problems, i will use:

2x https://de.aliexpress.com/item/32948417810.html?spm=a2g0s.9042311.0.0.73bd4c4dP2qqo3
one for the 5v for the teensy.
one for 12v for oled display
https://de.aliexpress.com/item/4001050409152.html?spm=a2g0s.9042311.0.0.73bd4c4dP2qqo3
to split the power and datalines and to have a screw mount for the usb-c socket.
https://de.aliexpress.com/item/4000777481955.html?spm=a2g0s.9042311.0.0.73bd4c4dP2qqo3
in the 5v 5a configuration to supply the leds. connected to:
https://de.aliexpress.com/item/4000139809599.html?spm=a2g0s.9042311.0.0.73bd4c4dP2qqo3
configured to get the best possible wattage from the usb-c cable.

so i end with:
1x5V 1A for teensy
1x12V 1A for OLED
1x5v 5A for LED-Strip.
so this should still be low enough to satisfy the 27w limit from the usb-c port, i have no clue how many losses i will have due to conversion though.

currently waiting for the 5v dc-dc converters .... will leave a reply how it went.

ps: for the problem between the 3.3v teensy and the 5v led data lines i got a 74HCT245 buffer chip
but i tested supplying the voltage directly to the strip and it worked, maybe the ws2813 refresh the signal after the first led with the supply voltage??? not sure though.
 
but i tested supplying the voltage directly to the strip and it worked, maybe the ws2813 refresh the signal after the first led with the supply voltage??? not sure though.
Most WS2812/2813 LEDs indeed seem to work OK when fed with a Teensy pin output voltage of 3V3.
However, it is not guaranteed to work always.
The spec states 0.7*Vdd for High-level Input Vih. That would be 3.5V when the LED is powered by 5V.

Capture.PNG

So better safe than sorry and add the levelshifter chip.

Paul
 
Status
Not open for further replies.
Back
Top