How to tie the TLC5940's DCPRG Pin High using the DC Register on Arduino

Hello all;

I'm wanting to use several TLC5940 chips to control a bunch of LED's. I found a great video online, but I am a bit confused about how to connect the DCPRG pin on the TLC5940 High.

I'm using the script from the video on YouTube by Kevin Darrah (Youtube, 28:08) as a starting point. At 28:08 he mentions the DCPRG pin on the TLC5940 and says that he connects it High "directly to the registers."

When I reference the data sheet for the chip (TLC5940, 7) it says, "When DCPRG=H, DC is connected to the DC register." Now, I'm pretty sure that indicates that this pin should always be on through a digital pin; however, Mr Darrah never defines a digital pin for the DCPRG pin to be connected to and doesn't set the output for it HIGH anywhere in his script. Ive also checked the Arduino's website information on the TLC5940 (Arduino, ) and it says, "DCPRG: this selects the source of the current limiter register, you could just tie it high."

Can anyone tell me what the DC Register is and how I can tie a pin High without defining it in the script?

My thought on how Mr Darrah was able to connect the DCPRG pin high without defining it in his script has to do with the fact that his circuit is because his Arduino is set up in a "stand alone configuration" with all of the "parts put on a breadboard." Unfortunately he doesn't provide a schematic for his circuit for me to reference.

Thank You for any input, NoisyBear

[u]Links:[/u]

YouTube Video

TLC5940 Data Sheet

Arduino TLC5940 Information

Can anyone tell me what the DC Register is

It is the dot correction register, it is inside the chip. It adjusts the nominal value you sent to the chip to compensate if some LEDs are dimmer or brighter than the rest.

Now, I’m pretty sure that indicates that this pin should always be on through a digital pin;

Normally people have this connected directly to the 5V line (pin 19 on the TLC ) . You only need to control this with an Arduino pin if you want to program the dot correction into the chip.

But also you have to put 22V on the VPGR pin (pin 27) in order to program the EEPROM with your dot correction data. So if you want to do it under control of the Arduino you have to use a transistor and a 22V power supply to be able to switch that pin on the TMS5940 and connect that to another pin.

So you need two more Arduino outputs, it doesn’t matter what two you use. Most sketches do not use this function of the chip.

I was thinking that the VCC pin (pin 21 on the TLC) was connected directly to the 5V pin on the Arduino. Are they both connected to the 5V pin, or am I wrong about the VCC pin. If I’m wrong about the VCC pin, then which pin on the Arduino does it get connected to? Also, you say that it is connected to a 5V line and that I only need to connect it to an Arduino pin if I want to program the dot correction into the chip. Are you implying that I should power it through a separate voltage source, or can I connect them to the 5V pin on the Arduino?

You can connect the Vcc line to the 5V line on the arduino as well as the DCprg Pin. You also need a decoupling capacitor of 0.1 uF ceramic type directly across the Vcc and GND pins of the TLC chip.