Frequency Counter

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Frequency Counter

765 次查看
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by santner on Wed May 16 05:48:28 MST 2012
I'm trying to setup a counter using TIMER0.  I have the LPC4350 Hitex board and I'm using pin 1.17 as my external clock input (this is coming from a function generator set at 100kHz, 3.3v, 50% duty cycle).  In the code I first setup the pin as an input configured for FUNCTION4 (T0_CAP3 Input).  I then configure the GIMA to route this pin to TIMER0.  I also set TIMER0->CTCR = 0xd.  Finally, I enable the timer.  After some analysis what I find is that there is a scale factor of 1/8.  So rather than seeing 100,000 ticks per second, I'm seeing 100,000/8 ticks per second.  Any ideas or examples which show how to accomplish this?
标签 (1)
0 项奖励
回复
0 回复数