Acrosser AR-B8170 Manual de usuario Pagina 34

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 37
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 33
AR-B8170 User Manual
34
if ( argc >1 )
{ Show_Help(); return 1; }
clrscr();
textcolor(WHITE);
gotoxy(1, 1);
cprintf("<>==========================================================================<>");
gotoxy(1, 2); cprintf("|| Vortex86DX GPIO Test Utility v1.0 Acrosser Technology Co., Ltd. ||");
gotoxy(1, 3);
cprintf("<>==========================================================================<>");
gotoxy(1, 4);
cprintf("<>==========================================================================<>");
gotoxy(1, 5); cprintf("|| Model Name : ||");
gotoxy(1, 6); cprintf("|| SIO IO Base : ||");
gotoxy(1, 7);
cprintf("<>==========================================================================<>");
// Show Got Parameter Informat
textcolor(LIGHTGRAY);
gotoxy(18,5); cprintf("%s",Model_Name);
gotoxy(18,6); cprintf("%X",IO_PORT_BASE);
// Set GPIO00~07 to Output
outportb(IO_PORT_BASE,0x4E);
outportb(IO_PORT_BASE+1,0xFF); // bit=1 , output
// Set GPIO10~GPIO17 to Input
outportb(IO_PORT_BASE,0x4F);
outportb(IO_PORT_BASE+1,0x00); // bit=0 , input
// Set GPIO00~07 to AA
outportb(IO_PORT_BASE,0x47);
outportb(IO_PORT_BASE+1,0xAA);
// Read GPIO10~17 Status, if not AA error.
outportb(IO_PORT_BASE,0x4C);
if(inportb(IO_PORT_BASE+1)!=0xAA)
result=1;
// Set GPIO00~07 to 55
outportb(IO_PORT_BASE,0x47);
outportb(IO_PORT_BASE+1,0x55);
// Read GPIO10~17 Status, if not 55 error.
outportb(IO_PORT_BASE,0x4C);
if(inportb(IO_PORT_BASE+1)!=0x55)
result=2;
// Set GPIO10~GPIO17 to Output
outportb(IO_PORT_BASE,0x4F);
outportb(IO_PORT_BASE+1,0xFF); // bit=1 , output
// Set GPIO00~07 to Input
outportb(IO_PORT_BASE,0x4E);
outportb(IO_PORT_BASE+1,0x00); // bit=0 , input
// Set GPIO10~17 to AA
outportb(IO_PORT_BASE,0x4D);
outportb(IO_PORT_BASE+1,0xAA);
// Read GPIO00~07 Status, if not AA error.
outportb(IO_PORT_BASE,0x46);
if(inportb(IO_PORT_BASE+1)!=0xAA)
Vista de pagina 33
1 2 ... 29 30 31 32 33 34 35 36 37

Comentarios a estos manuales

Sin comentarios