Table of Contents

Advertisement

Technical Manual

7.3. Watchdog

Programming:
The system BIOS makes it very easy to use the watchdog. Just activate the Watchdog in the Setup menu and
type in the cycle time.
As an additional feature the Watchdog on the ePanel-mgx can be triggered in a faster way.
The following sample code describes the procedure for fast Watchdog trigger:
#define GEODE_CONFIG_BASE
#define GEODE_WDTO
#define GEODE_WDCNFG
#define WDT_ENABLE
#define WDT_DISABLE
#define WATCHDOG_FREQUENCY
int command,
timeout;
char usage[] = "Usage: SC12xWdt <options> <time>\n"
"
"
"
"
void ProcessArgument (int argc, char *argv [])
{
int
cnt, flag = 0;
char *arg;
command = 0;
for (cnt = 1; cnt < argc; cnt++)
{
arg = argv [cnt];
if (*arg == '/')
{
for (arg++; *arg; arg++)
{
switch (toupper (*arg))
{
case 'A': command = 1;
case 'D': command = 2;
case 'R': command = 3;
default : printf ("Unknown option %s\n\n", arg);
}
}
}
else
{
if ((flag++) == 0)
{
timeout = atoi (arg);
timeout *= WATCHDOG_FREQUENCY;
}
else
{
printf ("Invalid time specification %s\n\n", arg);
printf (usage);
exit (EXIT_FAILURE);
}
}
}
ePanel-mgx
9000h
0000h
0002h
00FCh
0000h
8
options:
/A
Activate Watchdog\n"
/D
Delete Watchdog\n"
/R
Reset Watchdog (start new timeout)\n"
<time> :
Timeout in seconds (only /A and /R)\n\n";
break;
break;
break;
printf (usage);
exit (EXIT_FAILURE);
Page 34 of 45 Pages
// Activate
// Delete
// Reset
Hardware description

Advertisement

Table of Contents
loading

This manual is also suitable for:

22201

Table of Contents