Calibre UK UCA93 manual Function Prototypes

Page 8

CALIBRE

3.2.Function Prototypes

If you are using ‘C’ or ‘C++’ copy the file CALUCA.H into the directory containing your project and add the line:

#include " CALUCA.H"

The following functions are implemented in the windows libraries:-

extern __declspec(dllimport) int WINAPI Setup (int, int, int, int, int); extern __declspec(dllimport) int WINAPI SendAddress (int, int); extern __declspec(dllimport) int WINAPI WriteByte(int);

extern __declspec(dllimport) int WINAPI ReadByte(int); extern __declspec(dllimport) int WINAPI SendStop(void); extern __declspec(dllimport) int WINAPI Restart (int, int); extern __declspec(dllimport) int WINAPI GetStatus(void); extern __declspec(dllimport) int WINAPI recover(void); extern __declspec(dllimport) void WINAPI SlaveLastByte(void); extern __declspec(dllimport) int WINAPI DLLVersion(void);

extern __declspec(dllimport) void WINAPI SendAddressNoStatus(int , int, int); extern __declspec(dllimport) void WINAPI RestartNoStatus(int , int, int ); extern __declspec(dllimport) void WINAPI WriteByteNoStatus(int );

extern __declspec(dllimport) void WINAPI ReadByteNoStatus(int ); extern __declspec(dllimport) void WINAPI SendStopNoStatus(void);

extern __declspec(dllimport) int WINAPI SetBlockData(int); extern __declspec(dllimport) int WINAPI BlockWriteStatus (void); extern __declspec(dllimport) int WINAPI BlockWrite(int , int , int ,int, int ); extern __declspec(dllimport) int WINAPI GetBlockData(void);

extern __declspec(dllimport) int WINAPI BlockReadStatus(void);

extern __declspec(dllimport) int WINAPI BlockRead(int , int , int , int, int ); extern __declspec(dllimport) int WINAPI BlockSlaveTransmitterStatus(void); extern __declspec(dllimport) int WINAPI BlockSlaveTransmitter( int ); extern __declspec(dllimport) int WINAPI BlockSlaveReceiverStatus(void); extern __declspec(dllimport) int WINAPI BlockSlaveReceiver(int , int ); extern __declspec(dllimport) int WINAPI Write_IO_Pin (int , int );

extern __declspec(dllimport) int WINAPI Read_IO_Pin (int ); extern __declspec(dllimport) int WINAPI CheckBusVoltage(void); extern __declspec(dllimport) int WINAPI CheckPullupVoltage(void);

Issue 1.0

Page 5

01/07/03

 

Image 8
Contents Calibre Calibre Contents Connecting the Adapter to your System General IntroductionPacking List Bus Termination and ProtectionVariable Voltage Bus Power Supply Bus Capacitance Limitations/Cable ChoiceInstalling the Adapter IntroductionLibraries for Programming in Microsoft Windows Environments Function Prototypes Calibre Int SlaveBlockTimeout Int ownaddressInt ClockSpeed Int BusVoltageInt DataByte SendAddressInt I2CData NoneUsing the Adapter Int I2CstatusInt NoBytesToSend Int NoTriesInt DataVal Returns an unused integerInt NoBytesToTransmit Int TimeoutInt RdData Int NoBytesToReceive Int PullupVoltage Int IOState IntSendAddressNoStatus WriteByteNoStatus Real-Time Bus Monitor StopBit 4 The BER Bus Error Bit Appendix a I2C Communications Adapter Status CodesBit 7 MSB The old PIN Bit Bit 5 The old STS BitUSB Bus Characteristics Polling the Status Register and how to avoid itBlock Functions Block Write FunctionSlave Transmitter Function Slave Receiver FunctionCalibre When the the Most Commonly Asked I2C Questions Question Get corrupted transfers why is this?General Questions Question Do you have software to talk to my........?