
VIO-100(200)/PC100 | User’s Manual
104
GPIO Sample Code
GPI 0 ~ GPI 3
GPO 0 ~ GPO 3
____________________________________________________________________________________
Sample Code:
GPI_REG = 0xA03;
GPO_REG = 0xA02;
GPO_0 = 0x01; //bit0 is 1
#1 : Get GPI 0 status
// Get GPI 0 Pin Status
data=ReadByte(GPI_REG); // data bit4 is GPI 0 status
#2 : Set GPO 0 status to high
// Set GPO 0 Pin to High
data=ReadByte(GPO_REG);
data |= GPO_0;
WriteByte(GPO_REG, data); //data bit0 set GPO 0 status to high
Appendix – WDT & GPIO
GPI 0
GPI 1
GPI 2
GPI 3
IO Address
0xA03
0xA03
0xA03
0xA03
Bit
4
5
6
7
Sample code
#1
GPO 0
GPO 1
GPO 2
GPO 3
IO Address
0xA02
0xA02
0xA02
0xA02
Bit
0
1
2
3
Sample code
#2
Summary of Contents for VIO-100/PC100 Series
Page 1: ...USER S MANUAL VIO 100 PC100 Series VIO 200 PC100 Series Industrial Panel PCs ...
Page 13: ...Chapter 1 Product Introductions ...
Page 44: ...Chapter 2 Switches and Connectors ...
Page 60: ...Chapter 3 Front Panel Controls ...
Page 65: ...Chapter 4 System Setup ...
Page 81: ...Chapter 5 BIOS Setup ...
Page 107: ...Copyright Premio Inc All Rights Reserved www premioinc com ...