Appendix A – Watchdog Timer Programming 51Industrial HMI Touch Panel AHP-1154*********************************************************************VOID Main(){// Procedure : AaeonWDTConfig// (byte)Timer : Counter of WDT timer.(0x00~0xFF)// (boolean)Unit : Select time unit(0: second, 1: minute).AaeonWDTConfig(Counter, Unit);// Procedure : AaeonWDTEnable// This procudure will enable the WDT counting.WDTSetBit(TimerReg, PSWidthBit, PSWidthVal);// Watchdog WDTRST# EnableWDTSetBit(DevReg, WDTRstBit, WDTRstVal);}VOID WDTClearTimeoutStatus(){WDTSetBit(TimerReg, StatusBit, 1);}******************************************************************************************************************************************VOID WDTWriteByte(byte Register, byte Value){IOWriteByte(WDTAddr+Register, Value);}byte WDTReadByte(byte Register){return IOReadByte(WDTAddr+Register);}VOID WDTSetBit(byte Register, byte Bit, byte Val){byte TmpValue;TmpValue = WDTReadByte(Register);TmpValue &= ~(1 << Bit);TmpValue |= Val << Bit;WDTWriteByte(Register, TmpValue);}*********************************************************************