Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

Microcontrollers - AVR Atmega32 - Button Debouncing through Software

Loading...

Sign in or sign up now!
Alert icon
Upgrade to the latest Flash Player for improved playback performance. Upgrade now or more info.
3,355
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Sep 18, 2011

Official Page with More Information:
http://newbiehack.com/ButtonorSwitchDebounceinSoftware.aspx

This is the tenth video in a series on programming and simple circuit design for the Avr ATMega32 microcontroller. In this video, I demonstrate one technique to debounce a button's signal through programming rather than hardware.

  • likes, 0 dislikes

Link to this comment:

Share to:
see all

All Comments (7)

Sign In or Sign Up now to post a comment!
  • What is better software or hardware button debouncing?

  • Thank you for these. In debouncing would it be better to reset the confidence level on each counter-event. m not clear sorry.

    eg. looking for a press

    loop: if down then ++ conf else conf=0 if conf > 500 then pressed = true

    goto loop

    this we count the down time since the last up time.

    cheers

  • Amazing tutorials! Truly some of the most complete and concise explanations on any topic that I have looked up. Especially on something with so much depth as embedded programming! This really feels like a high school/early college level class/lecture. Please keep up the great work! Are there any plans on going into some basic circuit design- like sizing diodes, or capacitors, or what they do? What about data logging? Like storing data from the accelerometer to an SD card?

    Thanks again, Keep itup

  • @anajonesr , Yes you did, but only when it's value > 200, I think you should reset both after every successful count, nether pressed or released .

    Thank you, I learned a lot from your tuts

  • @Zanhor Thanks. I actually do zero the two variables you mention at the 7:00 minute mark.

Loading...

Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more