

The TLC5940 is a 16-channel LED driver with built-in PWM (Pulse Width Modulation) control for each channel, enabling precise brightness control for LEDs. It is designed to drive multiple LEDs simultaneously, making it ideal for applications requiring dynamic lighting effects, such as LED displays, signage, and decorative lighting. The component features a serial interface for seamless communication with microcontrollers and is packaged in a compact HTSSOP-28 PowerPAD format, which ensures efficient thermal management during operation.








The TLC5940 comes in a 28-pin HTSSOP package. Below is the pin configuration:
| Pin Number | Pin Name | Description |
|---|---|---|
| 1 | OUT0 | Channel 0 LED driver output |
| 2 | OUT1 | Channel 1 LED driver output |
| 3 | OUT2 | Channel 2 LED driver output |
| 4 | OUT3 | Channel 3 LED driver output |
| 5 | OUT4 | Channel 4 LED driver output |
| 6 | OUT5 | Channel 5 LED driver output |
| 7 | OUT6 | Channel 6 LED driver output |
| 8 | OUT7 | Channel 7 LED driver output |
| 9 | OUT8 | Channel 8 LED driver output |
| 10 | OUT9 | Channel 9 LED driver output |
| 11 | OUT10 | Channel 10 LED driver output |
| 12 | OUT11 | Channel 11 LED driver output |
| 13 | OUT12 | Channel 12 LED driver output |
| 14 | OUT13 | Channel 13 LED driver output |
| 15 | OUT14 | Channel 14 LED driver output |
| 16 | OUT15 | Channel 15 LED driver output |
| 17 | GND | Ground |
| 18 | VCC | Supply voltage (3.0 V to 5.5 V) |
| 19 | IREF | Reference current input for setting output current |
| 20 | SOUT | Serial data output for daisy-chaining multiple TLC5940 devices |
| 21 | SIN | Serial data input |
| 22 | SCLK | Serial clock input |
| 23 | XLAT | Latch signal input |
| 24 | BLANK | Blank signal input (disables all outputs when high) |
| 25 | DCPRG | DC programming input (used for dot correction) |
| 26 | VPRG | Mode selection input (switches between dot correction and grayscale mode) |
| 27 | GSCLK | Grayscale clock input |
| 28 | GND (PAD) | Thermal pad (must be connected to ground for proper heat dissipation) |
Power Supply:
Current Setting:
Iout = (1.24 V / Rref) × 31.5Rref is the resistance in ohms.Serial Communication:
LED Connections:
Daisy-Chaining:
Control Signals:
Below is an example of how to control the TLC5940 using an Arduino UNO:
#include <Tlc5940.h> // Include the TLC5940 library
void setup() {
Tlc.init(); // Initialize the TLC5940
}
void loop() {
// Set brightness for each channel (0-4095 for 12-bit resolution)
Tlc.set(0, 2048); // Set channel 0 to 50% brightness
Tlc.set(1, 4095); // Set channel 1 to 100% brightness
Tlc.set(2, 1024); // Set channel 2 to 25% brightness
Tlc.update(); // Send data to the TLC5940
delay(1000); // Wait for 1 second
// Turn off all LEDs
Tlc.clear();
Tlc.update();
delay(1000); // Wait for 1 second
}
LEDs Not Lighting Up:
Flickering LEDs:
Overheating:
Serial Communication Issues:
Can I use the TLC5940 with 3.3 V logic?
Yes, the TLC5940 is compatible with 3.3 V logic levels.
How many TLC5940 devices can I daisy-chain?
The number of devices depends on the microcontroller's memory and the desired refresh rate. Typically, up to 16 devices can be daisy-chained.
What is the purpose of dot correction?
Dot correction compensates for variations in LED brightness due to manufacturing differences, ensuring uniform brightness across all LEDs.
Can I use the TLC5940 for RGB LEDs?
Yes, the 16 channels can control up to 5 RGB LEDs (with one channel left unused).