AAEON AEC-6940 User Manual
Page 57
Advertising
E m b e d d e d C o n t r o l l e r
A E C - 6 9 4 0
Appendix A Programming the Watchdog Timer A-5
A.4 F75111 Watchdog Timer Initial Program
#include <stdio.h>
#include <conio.h>
void Chk_Ready();
#define SMBus_Port
0x500
#define I2C_Addr
0x6E
void main (void)
{
//device ID(smbus):6Eh,index:3h data:3h
//Set pin10 as WDTOUT2#
outportb(SMBus_Port+0x04,I2C_Addr);
delay(10);
Chk_Ready();
outportb(SMBus_Port+0x03,0x3);
delay(10);
outportb(SMBus_Port+0x05,0x3);
delay(10);
outportb(SMBus_Port+0x02,0x48);
delay(10);
Chk_Ready();
//device ID(smbus):6Eh,index:37h data:05h
//Set Watchdog Timer Rang
register to //be 5
Advertising