Issue 1.4
18/06/98
Page 3
LIBRARIES FOR PROGRAMMING IN MICROSOFT WINDOWS 95 / 98 ENVIRONMENTS
2.3.
Windows LIB/DLL Functions
2.3.1.
Files
PREG_95.exe
WRtDev0.VXD
Driver registration application
BlueWater Systems WinRT driver
\cpp\PICA_C95.H
\cpp\PICA_C95.LIB
\cpp\PICA_C95.DLL
"C++" function prototypes
I2C "C++" library
"Dynamic link library"
\vb50\PICA_95.BAS
\vb50\PICA_95.H
\vb50\PICA_95.LIB
\vb50\PICA_95.DLL
"Visual Basic 5.0 declarations"
"C" function prototypes
I2C "C" library
"Dynamic link library"
2.4.
Introduction
Each utility is documented in a standard format which lists its name, usage, function and effect on the
adapter is given. The adapter should be setup prior to any data transfer.
2.5.
C++ functions
-
Function Prototypes
To ensure the prototypes are added correctly copy the file PICA_C95.H) into the directory containing
your project and add the line:
#include "PICA_C95.H
The following functions are implemented in the windows libraries:-
extern __declspec(dllimport) int setup (int, int, int, int);
extern __declspec(dllimport) int sendaddress (int, int );
extern __declspec(dllimport) int restart (int, int);
extern __declspec(dllimport) int getstatus (void);
extern __declspec(dllimport) int writebyte (int );
extern __declspec(dllimport) int readbyte (int );
extern __declspec(dllimport) int sendstop (void);
extern __declspec(dllimport) int recover (void);
extern __declspec(dllimport) int slavelastbyte (void);
extern __declspec(dllimport) int dllversion (void);
These are implemented in the CPP
library
2.6.
VB5.0 functions
-
Function Declarations
To ensure the prototypes are added correctly copy the file PICA_95.BAS into the directory containing
your project and add the file to your project line:
The following functions are implemented in the windows libraries:-
Public Declare Function setup Lib "pica_95.dll" (ByVal baseaddress As Integer, ByVal ownaddress As
Integer, ByVal sclk As Integer, ByVal statuswait As Integer) As Integer
Public Declare Function sendaddress Lib "pica_95.dll" (ByVal slaveaddress As Integer, ByVal setnack
As Integer) As Integer
Public Declare Function restart Lib "pica_95.dll" (ByVal slaveaddress As Integer, ByVal setnack As
Integer) As Integer
Public Declare Function writebyte Lib "pica_95" (ByVal wrdata As Integer) As Integer
Public Declare Function readbyte Lib "pica_95.dll" (ByVal setnack As Integer) As Integer
Public Declare Function sendstop Lib "pica_95.dll" () As Integer
Public Declare Function getstatus Lib "pica_95.dll" () As Integer
Public Declare Function recover Lib "pica_95.dll" () As Integer
Public Declare Function slavelastbyte Lib "pica_95.dll" () As Integer
Public Declare Function dllversion Lib "pica_95.dll" () As Integer