Microchip® Advanced Software Framework

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Timeout example 2 for XMEGA A1 Xplained Documentation

Introduction

This simple example shows how to setup a debounce filter on a button using the the Timeout service XMEGA.

Main files

Timeout service

The timeout service can be found here.

Device Info

All XMEGA devices with RTC or RTC32 can be used

Description of the example

This example will demonstrate the effect of a debounce filter on a push button. Button0 includes the debounce filter and toggles LED0 when toggled. Button1 will toggle LED1, but without the debounce filter causing a jittering and unpredictable behaviour.

Compilation Info

This software was written for the GNU GCC for AVR. Other compilers may or may not work.

Contact Information

For further information, visit Microchip.
Support and FAQ: https://www.microchip.com/support/