TLC5940 with Common Anode RGB LED strips

Good morning! Long time reader, first time writing in! I'm working on a project that includes multiple RGB LED lighting zones with independent color control over each zone. The overview here is that eventually I will write or find an android app to run on a tablet that will communicate over the home wifi to a Raspberry Pi, which will interpret the commands into macros that will control an Arduino driving a set of TLC5940 LED drivers. It'll allow me to select colors for individual zones or trigger effects like flashing or a randomizer. I'm going in way over my head here, but that's what makes it fun!

So long story short, I made a tiny little mistake reading the TLC5940 spec sheet and thought that it would SOURCE 20ma/channel, but instead it SINKS 20ma/channel! Oops! I already have the TLC5940's, several rolls of RGB LED strips, and a whole pile of STP16NF06L N-Channel mosfets. I think I have a solution to my problem, which is to use a PNP transistor to invert the voltage from the TLC5940 so it can drive the mosfets. I'm just a little hung up on the value of the transistor or if it would be better to use a P-Channel mosfet, or if there's a better solution that I just haven't come across yet. I've attached my circuit, let me walk you through it and issue way too many caveats and apologies:

  • I made this using a website called SystemVision. It's okay, it lets you simulate your circuit so I know that it roughly works.

  • There are two power supplies, a 12 VDC for the LEDs and a 5 VDC for the TLC5940 chips and Arduino.

  • The RGB LED strips are the common ones that seem to be everywhere now, they are common anode so you supply 12 VDC to a single channel and turn individual color channels on and off by shorting them to ground. It's the same product described on Adafruit here: Schematic | RGB LED Strips | Adafruit Learning System

  • I may have 10 or more segments on a single leg, each segment has three channels R, G, and B and each channel can draw 20ma per segment. So each channel has to be able to handle at least 200ma. The RGB LED strips are represented crudely by the 5 diodes across the bottom of the schematic.

  • The digital pulse and switch at the upper right are the closest I could come up with to represent the TLC5940. smh.

  • The values of the resistors shown are place holders, I figure they'll depend somewhat on the value of the pnp transistor and may vary somewhat depending on how many LEDs are on that particular leg. The ratios should be correct though, R2=R1x10 and R4=R3x10. If you want to take a stab at finding values for them you're more than welcome to and thank you.

  • This is NOT the complete circuit, just the portion of the circuit pertaining to the LED control and it's full of placeholders and ugliness. That being said, there should be enough information here to predict a good fit for that pnp_transistor right there in the middle. I've attached the spec sheet for the mosfet and for the TLC5940 the rough circuit, below is the link for the TLC5940 spec sheet which is too large to attach.
    http://www.ti.com/lit/ds/symlink/tlc5940.pdf
    Happy to answer any questions!

STP16NF06L.pdf (274 KB)

You have no current limiting on those LEDs.

Grumpy_Mike thanks for stopping in! I've read your input on many other posts and found your advice to be very helpful! As I mentioned, the attached sketch isn't the complete circuit. The 5 LED's shown are only meant to represent the RGB LED strip that I'll be using. Here's the internal wiring for the RGB strip:

Each channel can draw 20mA, so your maximum total current draw per color channel is 20mA x #sections. All together I'm going to have 72 of these color channels, each drawing anywhere from 20mA to 200mA. When I get a little further along I'm going to dig deeper into how to keep the lines clean from noise and balance it all properly, but right now I'm stuck on how to efficiently use a pwm constant-current sink LED driver to switch a pnp transistor to switch an N-Channel mosfet to turn the lights on and off real fast. :smiley:

but right now I'm stuck on how to efficiently use a pwm constant-current sink LED driver to switch a pnp transistor to switch an N-Channel mosfet to turn the lights on and off real fast.

The constant current limit bit goes right out of the window. Basically you need a pull up resistor to 5V from the output. Then you connect the base of the PNP through a resistor. You seem to have done this but I would change the resistor values and have 10K as the pull up and 1K as the base resistor. Then that collector signal should be fed into the gate of the FET. Again you seem to have done that so I can only suggest that you have not got it wired the way your schematic is.