Go Down

Topic: Library for TLC5940 16-channel PWM chip (Read 35 times) previous topic - next topic

Grumpy_Mike

I've answered my own question and it is yes. There is a very useful application note about programming the chip at:-
http://focus.ti.com.cn/cn/lit/sw/slvc106/slvc106.pdf

It's a large and scary flow chart.

jonb

I've found this thread really useful. Many thanks to jims for the initial coding, the great library by acleone and the responses from the other people working with this chip.

Nima and Syvwlch have both mentioned that they've used the TLC5940 to drive small 3V DC motors. I've been attempting this, carefully following all the advice from this forum - separate regulated power supply for the motors and snubber diodes to prevent any return current damaging the chip.

However, when I try and drive just 6 motors,  the motors run at quite different speeds (one not at all) although one would expect that they get the same voltage and current.

Testing with a multimeter indicates that the motors closest to the power supply are drawing more current than those further away.

I've tested the motors individually and they work fine.

I was wondering if anybody had any tips for driving large numbers of DC motors?

Syvwlch

Interesting... I've only used pager-type vibration motors, and the intensity felt the same to the touch. Also, in my application I only ever have two on at the same time, never the full sixteen.

What value for the current supply setting resistor did you pick, are you sure your motors don't draw more current than you picked that resistor for, and (sorry for the dumb questions) are you sure the datasheet says the chip can provide that current amount under the voltage you are supplying it with (from memory it's 120mA for 5V, but I'd need to check to be sure)?

I'll play around with mine here, see if I can reproduce this behavior.
----------
Mathieu

Grumpy_Mike

Very interesting, I am only driving LEDs but I find that when you set them to very low values (say 0x00f) they vary smoothly in brightness across the chip, with the dimmest being at  output 1 (pin 28) getting brighter as you go through the chip.

That is with the EEPROM or the Dot Correction. However, I have not managed to get the dot correction to work as no matter what values I feed it the brightness spread always comes out the same.

Syvwlch

Ah, so I should be able to reproduce this if I set the entire row to a uniform but low value, then... I'll try that when I have some time.
----------
Mathieu

Go Up