
Hercules III User Manual Rev A.2
www.diamondsystems.com
Page
81
21. WATCHDOG TIMER PROGRAMMING
Hercules III contains a watchdog timer circuit consisting of one programmable timer. The input to the circuit is
WDI and the output is WDO, which appear on connector J8. WDI may be triggered in hardware or in software. A
special “early” version of WDO may be output on the WDO pin. When this signal is connected to WDI, the
watchdog circuit is retriggered automatically.
The watchdog timer duration is user-programmable. When WDT is triggered, it begins to count down. Upon
reaching zero, it generates a user-selectable combination of the following events.
•
System management interrupt
•
Hardware reset
The watchdog timer circuit is programmed using I/O registers located at address 0x25C. Detailed programming
information is described, below. The Hercules III watchdog timer is supported in the DSC Universal Driver
software version 5.7 and later.
21.1
Watchdog Timer Register Details
The registers in the following table are used to program the watchdog timer.
I/O Address
Write Function
Read Function
0x25C
WDT trigger
None, write-only
0x25D
WDT, counter
None, write-only
0x25E
Watchdog control
Readback
0x25F
Chip select enable/disable
Readback the last bits written
In the tables, below, a blank bit (-) indicates the bit is unused. A blank bit in the read registers reads back as 0 or
1, unknown state.
I/O Address: 0x25C (Write)
Bit:
7
6
5
4
3
2
1
0
Name:
-
WDTRIG
-
WDTRIG Writing a 1 triggers an immediate software reload of the watchdog timer.
I/O Address: 0x25D (Write)
Bit:
7
6
5
4
3
2
1
0
Name:
WDT3
WDT2
WDT1
WDT0
-
WDT4-7
Writing to bits WDT4-7 loads the watchdog timer with the 4-bit counter value. Use this
register to set the countdown period. Each tick is 145ms, so the period range is 145ms to
2.175 seconds (1 to 15).
I/O Address: 0x25E (Read/Write)
Bit:
7
6
5
4
3
2
1
0
Name:
WDIEN
WDOEN
WDSMI
WDEDGE
-