Atmel Software Framework

classb_wdt_test.c File Reference

Watchdog timer self-diagnostic routine.

Application note:
AVR1610: Guide to IEC60730 Class B compliance with XMEGA
#include "classb_wdt_test.h"
#include "error_handler.h"
#include <wdt.h>
#include <rtc32.h>
#include <sysclk.h>

Functions

 classb_wdt_test (void)
 Perform self-diagnostic test of watchdog timer (WDT). More...
 

Variables

Non-initialized Variables

These variables need to be preserved between resets, and are therefore not initialized upon device reset.

NO_INIT volatile
classb_preinit_teststate_t 
classb_wdt_teststate
 WDT test state. More...
 
NO_INIT volatile uint16_t classb_rtc_count
 Number of RTC periods in a WDT period. More...
 

Internal functions

#define rtc_is_busy()   rtc32_is_busy()
 Compatibility macro for RTC32. More...
 
static __always_inline bool rtc32_is_busy (void)
 Check if RTC32 is busy synchronizing. More...
 
static void udelay (uint16_t us)
 Delay for us microseconds. More...
 
static void vbat_init (void)
 RTC32 Initialization. More...