AnsweredAssumed Answered

How to debounce switch on PE within KDS

Question asked by Yaran Nan on May 13, 2015
Latest reply on May 14, 2015 by Yaran Nan

Hi,

1. I am connecting a push button on one gpio pin. I am using high level component on Processor expert. I dont see there is an option that i can enable interrupt on.

->In case someone need the info: In order to add interrupt of GPIO, it has to be added as component of 'ExtInt'.

 

2. When i hold down switch really long time. The u Controller detect the states back and force (0,1,0,1...). How would i make sure this doesnt happen?

3. How do i set a threshold for a short key press?

So i still dont understand the logic of debounce below. My current thought would be capture the duration of interrupt, and compare it to a threshold time. However,

i am not confident about this idea.

 

 

Thanks,

 

Yaran

 

Message was edited by: Yaran Nan

Outcomes