APPENDIX
MI889 User’s Manual
61
File of the MAIN.CPP
//---------------------------------------------------------------------------
//
// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
// KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
// IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
// PURPOSE.
//
//---------------------------------------------------------------------------
#include <dos.h>
#include <conio.h>
#include <stdio.h>
#include <stdlib.h>
#include "W627UHG.H"
//---------------------------------------------------------------------------
int main (void);
void Dio5Initial(void);
void Dio5SetOutput(unsigned char);
unsigned char Dio5GetInput(void);
void Dio5SetDirection(unsigned char);
unsigned char Dio5GetDirection(void);
//---------------------------------------------------------------------------
int main (void)
{
char SIO;
SIO = Init_W627UHG();
if (SIO == 0)
{
printf("Can not detect Winbond 83627UHG, program abort.\n");
return(1);
}
Dio5Initial();
//for GPIO50..57
Dio5SetDirection(0x0F); //GP50..53 = input, GP54..57=output
printf("Current DIO direction = 0x%X\n", Dio5GetDirection());
printf("Current DIO status = 0x%X\n", Dio5GetInput());
printf("Set DIO output to high\n");
Dio5SetOutput(0x0F);
printf("Set DIO output to low\n");
Dio5SetOutput(0x00);
return 0;
Содержание MI889
Страница 4: ...iv MI889 User s Manual This page is intentionally left blank ...
Страница 5: ...INSTALLATIONS MI889 User s Manual 1 Introduction MI889 MINI ITX MOTHERBOARD MI889 EDGE CONNECTORS ...
Страница 8: ...INSTALLATIONS 4 MI889 User s Manual Board Dimensions ...
Страница 16: ...INSTALLATIONS 12 MI889 User s Manual Connector Locations on MI889 ...
Страница 24: ...INSTALLATIONS 20 MI889 User s Manual This page is intentionally left blank ...
Страница 44: ...BIOS SETUP 40 MI889 User s Manual This page is intentionally left blank ...
Страница 52: ...DRIVERS INSTALLATION 48 MI889 User s Manual This page is intentionally left blank ...