BIOS Setup Information
WADE-8011/WADE-8012 User’s Manual
3-11
//pin6 =36
//pin8 =37
//pin10=70
//pin12=71
//pin14=72
//pin16=73
Enter_IT872x_SIO();
Set_LDN(GPIO_LDN);
//Enable GPIO
//Or_Register(0xC0,0x46) //11,12,14
//Or_Register(0xC2,0xE0) //35,36,37
//Or_Register(0xC3,0x80) //47
//Or_Register(0xC4,0x01) //50
//Set Output
Or_Register(0xC8,0x06); //11,12
Or_Register(0xCB,0x80); //47
Or_Register(0xCC,0x01); //50
Or_Register(0xCE,0xF0); //74,75,76,77
//Set Input
And_Register(0xC8,0xEF); //14
And_Register(0xCA,0x1F); //35,36,37
And_Register(0xCE,0xF0); //70,71,72,73
//output high
outp(GP0,0x06); //11,12
outp(GP3,0x80); //47
outp(GP4,0x01); //50
outp(GP6,0xF0); //74,75,76,77
result=1;
if ((inp(GP0)&0x10)!=0x10) result=0;
if ((inp(GP2)&0xE0)!=0xE0) result=0;
if ((inp(GP6)&0x0F)!=0x0F) result=0;
if (result==0){
printf("Test fail!!\n");
return 1;
}