Part Number:IWR6843ISK-ODS
在MSS工程中,可以使用看门狗功能,既可以看门狗复位,又可以看门狗中断,中断中可以使用软件复位;
看门狗初始化:
Watchdog_init();
Watchdog_Params_init(¶ms);
params.resetMode = Watchdog_RESET_OFF;
params.callbackFxn = watchdogCallback;
params.socHandle = socHandle;
params.esmHandle = esmHandle;
params.debugStallMode = Watchdog_DEBUG_STALL_ON;
params.windowSize = Watchdog_WINDOW_100_PERCENT;
params.preloadValue = 489;
handle = Watchdog_open(0, ¶ms);
if (handle== NULL) {
System_printf("Error: MMWDemoMSS:Watchdog did not open");
return;
}
看门狗回调:
static void watchdogCallback(Watchdog_Handle handle)
{
MmwDemo_CLIResetDevice();
return;
}
软件复位程序:
static int32_t MmwDemo_CLIResetDevice(void)
{
uint32_t* resetAddr = (uint32_t*)0xFFFFE11C;
*resetAddr = 0xAD;
return 0;
}
在DSS工程中,这样使用没有明显效果,求帮助。
Shine:
您可以看一下C:\ti\mmwave_sdk_03_05_00_04\packages\ti\drivers\watchdog\docs\doxygen\html\index.html文档说明。Using the driver on DSSThe watchdog driver CANNOT be configured to be in reset mode. It can only generate an NMI on watchdog expiry.
另外,C:\ti\mmwave_sdk_03_05_00_04\packages\ti\drivers\watchdog\test\xwr68xx中有dss watchdog例程可以参考。
,
fengzhi shao:
好的好的,谢谢您的回复!
,
Shine:
不客气~