/******************************************************************************* **+--------------------------------------------------------------------------+** **| **** |** **| **** |** **| ******o*** |** **| ********_///_**** |** **| ***** /_//_/ **** |** **| ** ** (__/ **** |** **| ********* |** **| **** |** **| *** |** **| |** **| Copyright (c) 1998-2005 Texas Instruments Incorporated |** **| ALL RIGHTS RESERVED |** **| |** **| |** **+--------------------------------------------------------------------------+** *******************************************************************************/ /****************************************************************************** * FILE PURPOSE: Watchdog Timer Module Header ******************************************************************************** * FILE NAME: wdtimer.h * * DESCRIPTION: Platform and OS independent API for watchdog timer module * * REVISION HISTORY: * 27 Nov 02 - PSP TII * *******************************************************************************/ #ifndef __WDTIMER_H__ #define __WDTIMER_H__ /* Return Codes */ #define WDTIMER_RET_OK 0 #define WDTIMER_RET_ERR -1 #define WDTIMER_ERR_INVAL -2 /**************************************************************************** * Type: PLA_SYS_WDTIMER_STRUCT_T **************************************************************************** * Description: This type defines the hardware configuration of the * watchdog timer ***************************************************************************/ typedef struct PAL_SYS_WDTIMER_STRUCT_tag { UINT32 kick_lock; UINT32 kick; UINT32 change_lock; UINT32 change ; UINT32 disable_lock; UINT32 disable; UINT32 prescale_lock; UINT32 prescale; } PAL_SYS_WDTIMER_STRUCT_T; /**************************************************************************** * Type: PAL_SYS_WDTIMER_CTRL_T **************************************************************************** * Description: This type defines start and stop values for the timer. * ***************************************************************************/ typedef enum PAL_SYS_WDTIMER_CTRL_tag { WDTIMER_CTRL_DISABLE = 0, WDTIMER_CTRL_ENABLE } PAL_SYS_WDTIMER_CTRL_T ; void PAL_sysWdtimerInit(UINT32 base_addr, UINT32 clk_freq); INT32 PAL_sysWdtimerSetPeriod( UINT32 msec ); INT32 PAL_sysWdtimerCtrl(PAL_SYS_WDTIMER_CTRL_T wd_ctrl); INT32 PAL_sysWdtimerKick(void); #endif /* __WDTIMER_H__ */