6
.
Appendix
PT-S959W10 User’s manual
71
Watch-Dog-Timer
The watchdog timer serves as a safeguard against possible system lock-up in your industrial computer
system. In most industrial environments, there are heavy equipment, generators, high-voltage power lines,
or power drops that have adverse effects on your computer system. For instance, when a power drop
occurs, it could cause the CPU to come to a halt state or enter into an infinite loop, resulting in a system
lock-up.
The application software created by user with the watchdog timer enabled, a RESET automatically
generated unless the software periodically triggers the timer within the setting time-out interval. That is,
while the system gets hung up, the running program can’t trigger the timer periodically. The timer will
generate a reset signal to reboot the system. This feature allows a running program to restart in an orderly
way when a power glitch or any abnormal condition occurs.
The watchdog timer comes with 255-level time-out interval, 1 - 255 seconds per interval, which can be
adjusted by software setting. There is a tolerance of 2 second for this time-out interval. To maintain
normal system operation, consider allowable error and create a program to re-trigger the watchdog timer.
CONTEC’s Web site [IPC-SLIB-01], which is bundled with this product, contains a sample program for
the watchdog timer. To view the sample program for the watchdog timer, decompress
“HWMandRTCut.zip”, which is found under \RasUtility\Samples\Module.
For example, if the time-out interval has been set to 30 seconds, your program should trigger the
watchdog timer before 28 seconds are escaped. Otherwise, after 28 - 32 seconds are escaped, the system
will automatically reboot.
The I/O port is defined at address 2e/2fH. You can trigger/enable disable the timer by writing address
2e/2fH.
Here is an example for flow chart and programming how to use the watch-dog-timer.
(1) Example flow chart
WDT
Restart?
END
START
No
WDT Stop
WDT Initial
WDT Start
Yes
If [WDT Stop] is not performed within the limit time set up
by [WDT Start], system reset occurs.
}
When performing the re-start of WDT, it repeats [WDT Start] and [WDT Stop].
*
It is also possible not to perform [WDT Stop] instead of performing [WDT Stop] to [WDT Start], but to perform [WDT
Start] continuously at the time of a re-start.