![background image](http://html1.mh-extra.com/html/premio/vio-100-pc100-series/vio-100-pc100-series_user-manual_1596728104.webp)
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
Содержание VIO-100/PC100 Series
Страница 1: ...USER S MANUAL VIO 100 PC100 Series VIO 200 PC100 Series Industrial Panel PCs ...
Страница 13: ...Chapter 1 Product Introductions ...
Страница 44: ...Chapter 2 Switches and Connectors ...
Страница 60: ...Chapter 3 Front Panel Controls ...
Страница 65: ...Chapter 4 System Setup ...
Страница 80: ...VIO 100 200 PC100 User s Manual 3 Lock the below 6 screws M4X5L to finish assembly 80 Chapter 4 System Setup ...
Страница 81: ...Chapter 5 BIOS Setup ...
Страница 102: ...Appendix WDT GPIO This appendix provides the sample codes of WDT Watch Dog Timer and GPIO General Purpose Input Output ...
Страница 107: ...Copyright Premio Inc All Rights Reserved www premioinc com ...