|Shopping Cart Checkout Shipping Cost Download Website|
|Home||MP3 Player||8051 Tools||All Projects||PJRC Store||Site Map|
|You are here: Teensy Teensyduino Libraries Tlc5940|
Tlc5940 LibraryTlc5940, by Alex Leone, interfaces with one of more TLC5940 chips from Texas Instruments. Though expensive, each chip provides 16 PWM outputs with 12 bit resolution, and built in current limiting for directly driving LEDs without resistors.
Tlc5940 works on Teensy 3.6, Teensy 3.5, Teensy 3.2, Teensy 3.1, Teensy 3.0, Teensy 2.0, Teensy++ 2.0, and Teensy++ 1.0.
Tlc5940 does not support Teensy LC or Teensy 1.0.
The special servo motor mode (tlc_servo.h) only works on Teensy++ 2.0, and Teensy++ 1.0.
The TLC5940 chip (PDF) requires only 2 resistors and connects to Teensy using 5 signals.
Several TLC5940 chips may be used. The SOUT signal (pin 17) of each connects to the SIN (pin 26) of the previous chip, and GSCLK, BLANK, XLAT, SCLK are connected in common to all chips.
Example ProgramsTlc5940 includes several examples, available from the File > Examples menu.
File > Examples > Tlc5940 > BasicUse
File > Examples > Tlc5940 > Fades
Peripherals UsedTlc5940 uses the SPI port and 2 timers. The MISO pin is not used. The SS pin may only be used as an output. Timer1 and Timer2 are used on Teensy++. On Teensy, Timer1 and Timer3 are used. Some PWM pins associated with these timers are either used by the library. The others may be used as input or output, but not as PWM (analogWrite).
Wiring and Pinout Info
For development on Tlc5940 for Teensy, please refer to this Github repository: