TLC5947 and Hardware SPI

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
Starscream83
 
Posts: 2
Joined: Wed Apr 30, 2014 3:24 pm

TLC5947 and Hardware SPI

Post by Starscream83 »

Hi Adafruit and all,

I recently bought a couple of Adafruit TLC5947 led drivers. The thing is great! The only issue i have is that i'm really missing the hardware SPI support of the Arduino Library because i really do need the plus of the speed.

I realized that the library for the other led driver Adafruit offers (TLC59711) does support the Hardware SPI.

Why is that? Can the TLC59711 library be modified to be useable with the TLC5947 in Hardware SPI mode? Does anybody have a solution to write stuff to the TLC5947 without library?

Thanks for your assistance

User avatar
adafruit_support_mike
 
Posts: 65256
Joined: Thu Feb 11, 2010 2:51 pm

Re: TLC5947 and Hardware SPI

Post by adafruit_support_mike »

Neither chip actually uses SPI, just clocked serial data. You should be able to copy most of the TLC59711 code over for use by the TLC5947.

Starscream83
 
Posts: 2
Joined: Wed Apr 30, 2014 3:24 pm

Re: TLC5947 and Hardware SPI

Post by Starscream83 »

Hi, thanks. I made it without a Library isn't really complex.

Unfortunately it turned out that it is still too slow, i chained 11 TLC5947. Shifting out all 3168 bits to the devices takes 700 Microseconds at busclock 8MHz. With this data rate i cannot achieve sufficient refresh rates with a Led Cube 9x9x9. :(

User avatar
adafruit_support_mike
 
Posts: 65256
Joined: Thu Feb 11, 2010 2:51 pm

Re: TLC5947 and Hardware SPI

Post by adafruit_support_mike »

If you want speed, go parallel.

The TLC5947 uses a clocked data protocol, but it isn't true SPI, so you should be able to bit-bang the communication. Assigning a value to PORTD writes pins 0-7 simultaneously, and PORTB gives you pins 8-13.

Locked
Please be positive and constructive with your questions and comments.

Return to “General Project help”