692Views2Replies

Author Options:

How well can you debounce a switch with a cap? Answered

Comments

The forums are retiring in 2021 and are now closed for new topics and comments.
0
DavidRobertson
DavidRobertson

11 years ago

 Seeing as you have tagged this question with "AVR" and "Microcontroller" I will assume you are going to use an avr. It may be easier just to debounce in software  by checking the value of the input pin, waiting (Experiment with the timing. A starting point could be around 100 milliseconds), and then checking the value again. If they are the same both time, assume that the button has been pressed. 



0
DavidRobertson
DavidRobertson

Answer 11 years ago

 Small error in last sentence, should say "If both readings are logic high(Or low, depending on wether you use a pull up or pull down resistor on the input) then assume that the button is pressed."