Microchip® Advanced Software Framework

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
WDT Example for XPLAIN Documentation

Introduction

This example demonstrates how to use XMEGA WDT module.

Main Files

Device Info

All AVR XMEGA devices can be used. This example has been tested with the following setup:

  • Xplain evaluation kit.
  • XMEGA A1 Xplained evaluation kit.
  • XMEGA A3BU Xplained evaluation kit.
  • STK600/RC044X with ATxmega32A4U.
  • STK600/RC064X with ATxmega64A3.
  • STK600/RC064X with ATxmega256A3.
  • STK600/RC064X with ATxmega256A3U.

Description of the example

The example enables the WDT in both modes, standard and window, and plays with all the WDT features. The LEDs output every 2 seconds the number of the test (states of the example) and can display a WDT failure.

The following LED configuration is used in the example:

  • XMEGA A1 Xplained: LED 0 through 3.
  • XMEGA A3BU Xplained: red on the status LED indicates that LED2 is on, while green on the status LED indicates that LED3 is on.
  • XMEGA B1 Xplained: LED 0 through 3.
  • STK600/RC044X: requires PORTA to be connected to LEDs. Output will be shown on LED 0 through 3.
  • STK600/RC064X: requires PORTE to be connected to LEDs. Output will be shown on LED 0 through 3.

Compilation Info

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

Contact Information

For further information, visit Atmel AVR.