ITA-5831 User Manual
78
Example Program
//Wait IBF Empty
unsigned char ECWaitIBFEmpty()
{
unsigned char Status;
do{
Status = inportb(0x29A); //Read back Status
} while (Status & 0x02); //If IBF Set?
return Status;
}
//Write non-data command (no data) to EC
void EcWriteCmd (unsigned char cmd)
{
ECWaitIBFEmpty();//Wait IBF Empty outpor tb(0x29A, (unsigned
char)cmd); //Write command
}
//Write standard command (include data) to EC
void IT8528ECSetData (
unsigned char
Cmd, //command
unsigned char
Addr,//write address
unsigned char
Value,//data
)
{
ECWaitIBFEmpty();
//Wait IBF Empty
outportb (IT8528E_HWM_CMD_PORT, Cmd);
//Write command
ECWaitIBFEmpty();
//Wait IBF Empty
outportb (IT8528E_HWM_DATA_PORT, Addr); //Write address
ECWaitIBFEmpty();
//Wait IBF Empty
outportb (IT8528E_HWM_DATA_PORT, Value);
//Write data
}
//Stop watchdog
void disable_wdt()
{
EcWriteCmd(0x29);
//Write command 0x29 to stop watch dog
}
Summary of Contents for ITA-5831 Series
Page 10: ...ITA 5831 User Manual x ...
Page 14: ...ITA 5831 User Manual 4 1 5 System Diagram Figure 1 1 ITA 5831 System Diagram ...
Page 16: ...ITA 5831 User Manual 6 ...
Page 17: ...Chapter 2 2 H W Installation Introduction Jumpers and Connectors I O Connectors ...
Page 26: ...ITA 5831 User Manual 16 ...
Page 29: ...19 ITA 5831 User Manual Chapter 3 System Setup Figure 3 2 Mini PCIe Installation ...
Page 34: ...ITA 5831 User Manual 24 Figure 3 10 Battery Module ITA BA61 00A1E ...
Page 37: ...Chapter 4 4 BIOS Settings ...
Page 64: ...ITA 5831 User Manual 54 ...
Page 68: ...ITA 5831 User Manual 58 ...
Page 69: ...59 ITA 5831 User Manual Chapter 5 Driver Installation ...
Page 72: ...ITA 5831 User Manual 62 ...
Page 73: ...Chapter 6 6 GPIO Programming Guide ...
Page 84: ...ITA 5831 User Manual 74 ...
Page 85: ...Appendix A A Watchdog Timer ...
Page 90: ...ITA 5831 User Manual 80 ...
Page 91: ...Appendix B B BSMI RoHS Declaration ...
Page 93: ...Appendix C C Chinese Language Safety Instructions and Battery Information ...