/******************************************************************************
 Description : This is the header file for the DLL used to interface the MDE8255LPT-1
 
 Date        : 2005Oct20
 Version     : 1.0
 Board       : NA
 Compiler    : GCC 3.4
 Website     : www.ilive4unix.net
 Email       : travis@ilive4code.net
 
 Required files             location
-------------------------------------------------------------
 mdedriverdll.lib           in source file directory
 mdedriverdll.dll           in executable directory
 mdedriver.sys              in windows\system32\drivers directory
 
*******************************************************************************/
 
// The following functions return -1 if there
// is a failure
int MDEOpenDriver();                           // This opens the driver
int MDECloseDriver();                          // this closes the driver
int MDEOutPA(int baseaddress, int value);      // this sends a value to port a
int MDEOutPB(int baseaddress, int value);      // this sends a value to port b
int MDEOutPC(int baseaddress, int value);      // this sends a value to port c
int MDEConfigPort(int baseaddress, int value); // this sends the control word
int MDEInPA(int baseaddress);                  // this gets a value from port a
int MDEInPB(int baseaddress);                  // this gets a value from port b
int MDEInPC(int baseaddress);                  // this gets a value from port c
int MDEOpenLPTPort(int baseaddress);
 
// These defines will assist with the board configuration
#define BaseConfig   0x80                      // all ports out
#define PortAIn      0x10                      // make port a an input
#define PortCUIn     0x08                      // make port cu an input
#define PortBIn      0x02                      // make port b an input
#define PortCLIn     0x01                      // make port cl an input
 
/*
CONTROL WORD (HEX)  CONTROL WORD (DECIMAL)  PORT A  PORT B  PORT C
80                  128                     OUT     OUT     OUT
82                  130                     OUT     IN      OUT
85                  137                     OUT     OUT     IN
87                  139                     OUT     IN      IN
88                  144                     IN      OUT     OUT
8A                  146                     IN      IN      OUT
8C                  153                     IN      OUT     IN
8F                  155                     IN      IN      IN
*/
/var/www/sites/dokuwiki-2011-05-25a/data/pages/projects/libmdedriver/mdedriverdll.h.txt · Last modified: 2009/04/11 22:23 (external edit)
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki