Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

Timer question to make a driver for TLC59401

 
Post new topic   Reply to topic    www.mcselec.com Forum Index -> BASCOM-AVR
View previous topic :: View next topic  
Author Message
hzz

Bascom Member



Joined: 20 Feb 2007
Posts: 270

spain.gif
PostPosted: Fri Jul 20, 2018 11:52 am    Post subject: Timer question to make a driver for TLC59401 Reply with quote

Hello. I need ideas to do the following (with XMEGA):

A) Clock pulses. Output a 16MHz clock signal. OK, this is easy. I can just use a timer in frequency mode
Code:
Config Tcd1 = Freq , Prescale = 1 , Comparea = Enabled , Resolution = 16
Tcd1_cca = 0                                                ' System Clock  /2*Prescaler(CCA + 1) = 32MHz/2*1(0 + 1) = 32MHz/2 = 16MHz


B) Blank Pulse. Output a short pulse (about 100ns) after 4096 Clock Pulses . Any idea about how to do this?

C) Xlat Pulse. When a variable is =1, output a pulse which should go high after the Blank pulse and should go low before the Blank pulse. (The Xlat pulse is inside the Blank pulse). Again any idea?

PD: Each output uses a different pin (so 3 pins in total)
----------
In https://www.mcselec.com/index2.php?option=com_forum&Itemid=59&page=viewtopic&t=14193&highlight=tlc59401 I posted a driver for TL59401/TL5940 LED/Servo PWM control chips.
But it didn't work. Now I understand why and need to solve what I mention above in order to correct the driver.
Thanks
Hector

(BASCOM-AVR version : 2.0.7.9 , Latest : 2.0.8.1 )
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    www.mcselec.com Forum Index -> BASCOM-AVR All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum