PCAL9714HN hardware debouncing

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

PCAL9714HN hardware debouncing

1,131 次查看
Thai
Contributor I

Hello,

I am trying to use this PCAL9714HN to sense some limit switches.

I want to implement hardware debouncing according to section 6.9; however, I don't know which oscillator I should use.

Can I just use a 16Mhz crystal oscillator like this ABM8-16.000MHZ-10-1-U-T

Thank you very much in advance.

0 项奖励
回复
2 回复数

1,118 次查看
ErikaC
NXP TechSupport
NXP TechSupport

Hello,

You can use 16Mhz crystal oscillator, but you should consider the Debounce counter to determinate the qualification period.

For example:

tDP = [PERIOD of EXT CLOCK] * [Debounce counter(5C)] = 62.5 ns * 10 = 625 ns (if external clock = 16 MHz, debounce count
register (5Ch) = 0Ah) 

tDP = [PERIOD of EXT CLOCK] * [Debounce counter(5C)] = 62.5 ns * 255 = 15.94 μs (if external clock = 16 MHz, debounce count
register (5Ch) = FFh)

Hope this helps.

0 项奖励
回复

1,108 次查看
Thai
Contributor I

Hello,

Thank you for your response.

I have two more questions:

1. I want to sense a limit switch for a hard stop for my motor. Which oscillator frequency would you recommend?

2. I plan to use the internal pull-up for the pin, can I just connect the switch (SW1) directly to GND like this to sense when it's being pressed?

Thai_0-1710843305484.png

Thank you for your help.

Best,

 

 

 

0 项奖励
回复