System Installation
RUBY-D716VG2AR User’s Manual
3-18
tmp
=
EC_GetRamByte(EC_PIN8_CTL_ADDR);
tmp
=
0x40;
tmp
&=
~0x80;
EC_SetRamByte(EC_PIN8_CTL_ADDR,
tmp);
}
break;
default:
printf("invalid pin number when writing to
gpio\n");
}
return 0;
}
int gpio_setdirection (unsigned char io_direction)
{
unsigned char data;
int
i;
for (i = 0; i < 8; i++)
gpio_setpindirection (gpio_set, i+1, (io_direction & (0x01 <<
i)));
return
0;
}
int gpio_readpindirection (int pin_num, unsigned char *io_direction)
{
unsigned char data;
unsigned char tmp;
switch(pin_num)
{
case
1:
tmp
=
EC_GetRamByte(EC_PIN1_CTL_ADDR);
if( tmp & 0x80 ) /* means in */
*io_direction
=
1;
else if ( tmp & 0x40 ) /* means out */
*io_direction
=
0;
else
printf("unknown
GPIO
pin
direction
in
EC\n");
break;
case
2:
tmp
=
EC_GetRamByte(EC_PIN2_CTL_ADDR);
Содержание RUBY-D716VG2AR
Страница 7: ...System Overview RUBY D716VG2AR User s Manual 1 4 1 3 1 Mechanical Drawing...
Страница 8: ...System Overview RUBY D716VG2AR User s Manual 1 5...
Страница 71: ...BIOS Setup Information RUBY D716VG2AR User s Manual 4 26 SMBIOS Event Log Clears SMBIOS events Choices Enter...
Страница 78: ...Troubleshooting RUBY D716VG2AR User s Manual 5 4...