User manual
Appendix 
- 48 -  EC7-1817LNAR 
outportb(DATA_PORT, 0x01); 
outportb(INDEX_PORT, 0x07); 
outportb(DATA_PORT, 0x09); 
outportb(INDEX_PORT, 0x30); 
outportb(DATA_PORT, 0x04); 
} 
(2)  Configure the WDT operating mode to enable or disable WDT 
/* 
  Description: the function, SetWDT, is used to configure the parameter required 
when configuring WDT to enable or disable WDT. 
  Input: Wmode:   0 - Configure WDT to reset mode 
IRQ_NO - Configure WDT to interrupt mode. Please 
replace the constant IRQ_NO with the interrupt number 
need to be used. The available range of the interrupt number 
has been listed in the beginning of this chapter 
    Wtime:  0 - Configure WDT to time by minute 
         1 - Configure WDT to time by second 
    Timeout: 0 - disable WDT 
  TIME_OUT_VALUE - Enable WDT. Please replace the 
constant TIME_OUT_VALUE with the unit number of 
timeout value (0x01 ~ 0xFF) 
 Note: 
*/ 
SetWDT(int Wmode, int Wtime, int Timeout) 
{ 
 unsigned char oldval, tempval, tempval2;   
outportb(INDEX_PORT,0xe0); 
 tempval2 = inportb(DATA_PORT); 
tempval2 &= 0xef; 
outportb(DATA_PORT, tempval2);  ;Set GPIO24 to output pin. 
 outportb(INDEX_PORT,0xe9); 










