Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

What is key debounce and how to eliminate it?

Status
Not open for further replies.

saudrehman

Member level 1
Member level 1
Joined
Dec 20, 2005
Messages
40
Helped
1
Reputation
2
Reaction score
0
Trophy points
1,286
Activity points
1,697
hi fuys
can any explain what is key debounce and
steps to eliminate it in keys???
 

Re: Key debounce

Hi

key bouncing can be sean on oscliscope or Logic analyzer .
if you press a key -just once- you will see on the Logic analyzer more than one pulse.
to over come this you had to use a low pass filter , you can just out a capacitor to gound to filter the small pulses wich follows the main pulse.

In SW you can make a time window after the 1st pulse in which stop reading.

Salam
Hossam Alzomor
 

Re: Key debounce

hai
from the above answer,i hope that u understod what a key debounce is.it happens due to the mechanical aspects of the key.
what we normaly do to eliminate this(in software) we check the key status first,then will provide a delay of 20 ms (normaliy we keep pressing the key for more than 20 ms), and again read the key status.if we are getting the same value,we will take it as the key is pressed.this way we can eliminate the key debounce.
 
Re: Key debounce

As explained above, In a digital circuit, You need to have a better or let me say accurate pulse for triggering, clocking etc. the switch being a mechanical device has a tendency of bouncing several times when you push or press it. This can cause noise which is a problem in digital circuits so you have to come up with a method to stop this unwanted "spikes" caused by the switch.
You can use an RS- FLIP FLOP also called(SR-Flip Flop) to eliminate such problem. You can use the '279 "quad SR latch" It gives you four of them into one package.


Hope this answers your question.


Rickylo
 

Re: Key debounce

saudrehman said:
hi fuys
can any explain what is key debounce and
steps to eliminate it in keys???

This is the best reference I have seen.

Pop
 

Key debounce

One of the simplest techniques that I use is the following:

while(read_key()==NO_KEY_PRESSED)
;
delay_20_ms();
read_key();

As you can see we wait until a key is pressed.Then we wait some msec in order to avoid bouncing and then we read the actual value of key.
 
Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top