syswdog.h

来自「au1500开发的应用程序」· C头文件 代码 · 共 56 行

H
56
字号
/* sysWdog.h - hardware watchdog header file */

/* Copyright 2002-2005 Founder Communications, Inc. */

/*
modification history
--------------------
01a,3feb05,fhchen  written
*/

/*
DESCRIPTION

Head file for hardware watchdog driver. On V100R001CHB board MAX706
is connected to IRQ0 and PD12 of 8260.

*/

#ifndef __INCsysWdogh
#define __INCsysWdogh

#ifdef __cplusplus
extern "C" {
#endif

#include <vxWorks.h>
#include <sysLib.h>    
#include "m8260IOPort.h"

/* constants */

#define WDG_PORT                PORT_D       /* port watchdog WDI connected to */    
#define WDG_PIN_WDI		PIN12        /* pin used to feed the watchdog */
#define WDG_LOGIC_FEED		LOGIC_LOW    /* logic level to feed */
#define WDG_TIMEOUT		(160 * sysClkRateGet() / 100) /* timeout value of MAX706 */

#define WDG_TASK_NAME		"tWatchdog"  /* watchdog task name */
#define WDG_TASK_PRIO		20           /* watchdog task priority */
#define WDG_TASK_STACK_SIZE	500       /* watchdog task stack size in byte */
    
/* interface */
    
extern STATUS sysWdgDisable(void);                    /* disable the hardware watchdog */
extern STATUS sysWdgEnable(void);                     /* enable the hardware watchdog */
extern STATUS sysWdgStart(void);                    /* enable the watchdog and start the feeder */
extern void wdgTaskEntry(UINT32 interval);             /* task feeding the watchdog */
/* extern void sysWdgFeed(void); */
#define sysWdgFeed()	(m8260IOPortWrite(WDG_PORT, WDG_PIN_WDI, WDG_LOGIC_FEED)) /* routine to feed once */

#ifdef __cplusplus
}
#endif

#endif	/* __INCsysWdogh */    

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?