Nexcom EBC 357X Series User Manual page 84

Embedded computing (3.5” cpu board)
Table of Contents

Advertisement

Appendix A: GPI/O Programming Guide
GPIO programming sample code
#define GPO0
(0x01 << 6)
#define GPO1
(0x01 << 5)
#define GPO2
(0x01 << 0)
#define GPO3
(0x01 << 1)
#define GPO0_HI
outportb(0xA03, GPO0)
#define GPO0_LO
outportb(0xA03, 0x00)
#define GPO1_HI
outportb(0xA02, GPO1)
#define GPO1_LO
outportb(0xA02, 0x00)
#define GPO2_HI
outportb(0xA07, GPO2)
#define GPO2_LO
outportb(0xA07, 0x00)
#define GPO3_HI
outportb(0xA07, GPO3)
#define GPO3_LO
outportb(0xA07, 0x00)
void main(void)
{
GPO0_HI;
GPO1_LO;
GPO2_HI;
GPO3_LO;
}
Copyright © 2016 NEXCOM International Co., Ltd. All Rights Reserved.
70
EBC 357X User Manual

Advertisement

Table of Contents
loading

This manual is also suitable for:

Ebc 357x-e3950Ebc 357x-e3930

Table of Contents