![MSI WindBOX MS-9B05 Manual Download Page 56](http://html1.mh-extra.com/html/msi/windbox-ms-9b05/windbox-ms-9b05_manual_1847262056.webp)
A-3
GPIO WDT Programming
MS-9B05
General Purposed IO
1. General
Purposed
IO
–
GPIO/DIO
The
GPIO
port
configuration
addresses
listed
in
the
following
table:
Name
IO
Port
IO
address
Name
IO
Port
IO
address
N_GPI0
0xA05
Bit
3
N_GPO0
0xA05
Bit
0
N_GPI1
0xA05
Bit
4
N_GPO1
0xA05
Bit
7
N_GPI2
0xA05
Bit
5
N_GPO2
0xA05
Bit
2
N_GPI3
0xA05
Bit
6
N_GPO3
0xA05
Bit
1
1.1
Set
output
value
of
GPO
1. Read
the
value
from
GPO
port.
2. Set
the
value
of
GPO
address.
3. Write
the
value
back
to
GPO
port.
Example:
Set
N_GPO0
output
“high”
val
=
Inportb
(
0xA05
);
//
Read
value
from
N_GPO0
port.
val
=
val
|
(1<<
0
);
//
Set
N_GPO0
address
(bit
0)
to
1
(output
“high”).
Outportb
(
0xA05
,
val);
//
Write
back
to
N_GPO0
port.
Example:
Set
N_GPO1
output
“low”
val
=
Inportb
(
0xA05
);
//
Read
value
from
N_GPO1
port.
val
=
val
&
(~(1<<
7
));
//
Set
N_GPO1
address
(bit
7)
to
0
(output
“low”).
Outportb
(
0xA05
,
val);
//
Write
back
to
N_GPO1
port.
1.2
Read
input
value
from
GPI
1.
Read
the
value
from
GPI
port.
2.
Get
the
value
of
GPI
address.
Example:
Get
N_GPI2
input
value.
val
=
Inportb
(
0xA05
);
//
Read
value
from
N_GPI2
port.
val
=
val
&
(1<<
5
);
//
Read
N_GPI2
address
(bit
5).
if
(val)
printf
(“Input
of
N_GPI2
is
High”);
else
printf
(“Input
of
N_GPI2
is
Low”);
Summary of Contents for WindBOX MS-9B05
Page 1: ...i MS 9B05 WindBOX Industrial Data Machine...
Page 16: ......
Page 18: ...2 2 Getting Started System Internal View...
Page 43: ...3 16 BIOS Setup ME Debug Configuration Anti Rollback SVN Configuration...
Page 53: ......