datasmith
Well-known member
Hi all. New forum member here, and working on a new Picaxe project.
I'm working on a piece of animated artwork that has eight multi-color glowing spheres driven by RGB LEDs.
I wanted to keep the electronics as simple as possible, and found this shift-register RGB-LED controller that I hoped would fit the bill.
It's the Texas Instruments TLC5947 on an Adafruit break-out board... cost me about $20 US on Amazon.com, but I just found a clone from Comimark also on Amazon for only $7.50 US which also comes with header pins. A much better deal, so I just picked up two more for future projects.
I took the minimalist approach and wired an 08M2 to the controller with a minimum of parts; two resistors (for the programming interface), two capacitors and a 5V voltage regulator. This allows me to run it with any DC power supply up to the break-out board's max voltage of I think is 24V. I'm using a 9V power supply.
I have attached pics of my schematic and associated breadboard, and I've actually got this thing working.
Here are some caveats.
1. The TLC5947 has12 bits of resolution per color (RGB) per LED. That's 12x3x8=288 bits that must be shifted out to the controller each and every time you want to change a color on any(or all 8) LED(s) connected to the controller.
2. The 08M2 apparently does not support hardware shiftout, so I had to use a modified version of the shiftout sub-procedure provided on page 238 of the picaxe programming manual to get data out to the controller. MSB first.
3. To get any smooth color animation out of the TLC5947 I had to crank the 08M2 clock speed up to 32MHz. This kills any multitasking capabilities and I had to write my program as a single thread.
Regardless, I was able to get it to work at about 15 updates per second. This gives me a relatively smooth animation, given the minimal parts and costs.
Here are pics of my schematic and breadboard in operation.
In my next post I will provide my program concept and base code for sending colors to the TLC5947.
I'm working on a piece of animated artwork that has eight multi-color glowing spheres driven by RGB LEDs.
I wanted to keep the electronics as simple as possible, and found this shift-register RGB-LED controller that I hoped would fit the bill.
It's the Texas Instruments TLC5947 on an Adafruit break-out board... cost me about $20 US on Amazon.com, but I just found a clone from Comimark also on Amazon for only $7.50 US which also comes with header pins. A much better deal, so I just picked up two more for future projects.
I took the minimalist approach and wired an 08M2 to the controller with a minimum of parts; two resistors (for the programming interface), two capacitors and a 5V voltage regulator. This allows me to run it with any DC power supply up to the break-out board's max voltage of I think is 24V. I'm using a 9V power supply.
I have attached pics of my schematic and associated breadboard, and I've actually got this thing working.
Here are some caveats.
1. The TLC5947 has12 bits of resolution per color (RGB) per LED. That's 12x3x8=288 bits that must be shifted out to the controller each and every time you want to change a color on any(or all 8) LED(s) connected to the controller.
2. The 08M2 apparently does not support hardware shiftout, so I had to use a modified version of the shiftout sub-procedure provided on page 238 of the picaxe programming manual to get data out to the controller. MSB first.
3. To get any smooth color animation out of the TLC5947 I had to crank the 08M2 clock speed up to 32MHz. This kills any multitasking capabilities and I had to write my program as a single thread.
Regardless, I was able to get it to work at about 15 updates per second. This gives me a relatively smooth animation, given the minimal parts and costs.
Here are pics of my schematic and breadboard in operation.
In my next post I will provide my program concept and base code for sending colors to the TLC5947.
Attachments
-
123.5 KB Views: 49
-
32.9 KB Views: 48