Subscribe to EDN
RSS
Reprints/License
Print
Email

Follow the debouncing flip-flops

Ray Scott and John Stanley, Airport Systems International, Overland Park, KS -- EDN, February 17, 2000

During a recent development effort, we could not find literature detailing how to debounce an spst momentary switch using only logic (no capacitors, Schmitt triggers, or other components). Our application placed the spst switches several feet from the logic board, and both noisy switches and line transients caused false triggers. Many methods simulate a debounce by checking the state of the switch on clock edges and summing the checks over time, but our application required no transitions during the qualification time before acknowledgment of a key press. Thus, the switches can work effectively in noisy environments over reasonably long distances. Figure 1 illustrates a means of debouncing a momentary switch for both the make and the break operations. Designers often use programmable logic to debounce momentary switches used in keypads, in keyboards, or as configuration inputs. Flip-flops are usually precious commodities in programmable logic, whereas logic gates are available in greater abundance. The design in Figure 1 minimizes the use of flip-flops.

The circuitry monitors the state of the Switch input. Once the circuit detects a transition, a "qualifying" time of two Debounce_Clock periods begins. If at any time during the qualifying time the Switch input returns to its original state, indicating switch bounce or an electrical transient, the circuitry returns to its starting state and begins looking for another transition. The Switch input must be completely stable for two positive transitions of the Debounce_Clock input before the Switch_Debounced output will change. A frequency of approximately 15 Hz (or a period of 66 msec) for the Debounce_Clock input works well, even for low-cost, "noisy" switches. You can delete the reset logic if you are unconcerned with the power-on state of the Switch_Debounced output. Following power-on, the output will be correct after two clock periods. (DI #2481)


RSS
Reprints/License
Print
Email
Talkback
Canon Resource Center

Featured Company


Most Recent Resources

Advertisement
Related Content

No related content found.

  • 0 rated items found.
Advertisement

KNOWLEDGE CENTER

Datasheets.com Parts Search

185 million searchable parts
(please enter a part number or hit search to begin)
Engineering Careers
Jobs sponsored by
Advertisement
About EDN   |   Site Map   |   Contact Us   |   Subscription   |   RSS
© 2011 UBM Electronics. All rights reserved.
Use of this Web site is subject to its Terms of Use | Privacy Policy

Please visit these other UBM Canon sites

UBM Canon | Design News | Test & Measurement World | Packaging Digest | EDN | Qmed | Pharmalive | Appliance Magazine | Plastics Today | Powder Bulk Solids | Canon Trade Shows