PDA

View Full Version : What debouncing technicques do you know?



Humbleworker
- 29th March 2007, 03:18
There are so many ways to debounce a switch or bit so I was just wondering what other ways there are to debounce? If you're willing to share your debouncing technicque then post it here.

skimask
- 29th March 2007, 04:06
There are so many ways to debounce a switch or bit so I was just wondering what other ways there are to debounce? If you're willing to share your debouncing technicque then post it here.

Google gives me over 167,000 hits on switch debouncing.
And the 20 or so that I looked at had a load of good ideas.
Have you checked ANY of them?

Pic_User
- 29th March 2007, 04:22
Hi Humbleworker,

See this post by ErnieM about software debounce
http://www.picbasic.co.uk/forum/showthread.php?p=26715&highlight=debounce#post26715

hth
-Adam-

ewandeur
- 29th March 2007, 11:42
Try this method, I already used in my projects and worked fine.
The only issue is that you will need to use a switch with 2 contacts.


http://www.elexp.com/t_bounc.htm

good luck

mister_e
- 30th March 2007, 15:55
I always use the software method. Polling the pins in a loop or using a Timer interrupt. The timer interrupt will also provide the debouncing delay.

The main advantage of a timer interrupt is that you need ONLY 1 routine, running in background and you button states are available everywhere, when you need.

That's What Ernie suggested too ;)