19 #ifndef BFSERIALEXPORT 
   20     #define BFSERIALEXPORT __declspec(dllexport) 
   24     #define BFSERIALCC __cdecl 
   27 typedef struct _SerialMutexes
 
   35 typedef struct _SerRefStruc
 
   38     PBFSIGNAL   pCLReadSignal;      
 
   39     PBFSIGNAL   pBFCLReadSignal;    
 
   72 #define BFCL_ERROR_SERNOTFOUND  -1000   // The serial device was not found 
   73 #define BFCL_ERROR_BRDNOTFOUND  -1001   // There are no R2 boards installed 
   74 #define BFCL_ERROR_BRDOPEN      -1002   // Error opening board 
   75 #define BFCL_ERROR_THRE         -1003   // Transmitter Holding Register not empty (THRE) 
   76 #define BFCL_ERROR_TEMT         -1004   // Transmitter not empty (TEMT) 
   77 #define BFCL_ERROR_FIFO_EN      -1005   // FIFO's are not enabled 
   78 #define BFCL_ERROR_RCVRFIFO     -1006   // Error in RCVR FIFO 
   79 #define BFCL_ERROR_BAUDRATE     -1008   // Invalid Buad Rate 
   80 #define BFCL_ERROR_DATABITS     -1009   // Invalid number of data bits 
   81 #define BFCL_ERROR_PARITY       -1010   // Invalid parity parameter 
   82 #define BFCL_ERROR_15STOP5DATA  -1011   // To use 1.5 number of stop bits, 5 data bits must be used. 
   83 #define BFCL_ERROR_2STOP5DATA   -1012   // Can't use 5 data bits with 2 stop bits 
   84 #define BFCL_ERROR_STOPBITS     -1013   // Invalid number of stop bits. 
   85 #define BFCL_ERROR_NOSIGNAL     -1014   // Can't create signal 
   86 #define BFCL_ERROR_NOSTRUC      -1016   // Can't create ref structure 
   87 #define BFCL_ERROR_NULLPTR      -1017   // BFNULL pointer 
   88 #define BFCL_ERROR_BYTES_AVAIL  -1018   // Error getting the number of bytes available in the buffer 
   89 #define BFCL_ERROR_FLUSH_PORT   -1019   // Error flushing the port 
   90 #define BFCL_ERROR_DATA_IN      -1020   // The receive buffer could not be emptied 
   93 #define BFCL_WARN_SIG_CANCEL    -1015   // BFSerialRead signal was cancelled 
  101                  unsigned int dataBits,
 
  103                  unsigned int stopBits);
 
  106 clBFSerialRead(
void* serBFRef, 
char* buffer, 
unsigned int* bufferSize );
 
struct _SerialMutexes SerialMutexes
 
enum _DataBits * DataBitsPtr
 
unsigned long BFU32
Definition: BFTypeNT.h:55
 
BFSERIALEXPORT int BFSERIALCC clBFSerialRead(void *serBFRef, char *buffer, unsigned int *bufferSize)
 
enum _StopBits * StopBitsPtr
 
Definition: BFSerial.h:67
 
BFU32 BFRC
Definition: BFType.h:92
 
Definition: BFSerial.h:48
 
BFSERIALEXPORT int BFSERIALCC clBFSerialSettings(void *serBFRef, unsigned int baudRate, unsigned int dataBits, unsigned int parity, unsigned int stopBits)
 
unsigned long * PBFU32
Definition: BFTypeNT.h:55
 
Definition: BFSerial.h:66
 
BFSERIALEXPORT int BFSERIALCC clBFGetBaudRate(void *serBFRef, unsigned int *baudRate)
 
struct _SerialMutexes * SerialMutexesPtr
 
Definition: BFSerial.h:51
 
Definition: BFSerial.h:59
 
Definition: BFSerial.h:65
 
_StopBits
Definition: BFSerial.h:63
 
_Parity
Definition: BFSerial.h:55
 
BFSERIALEXPORT int BFSERIALCC clBFSerialCancelRead(void *serBFRef)
 
BFSERIALEXPORT int BFSERIALCC clBFGetSerialRefFromBoardHandle(Bd hBoard, void **serBFRefPtr)
 
#define BFSERIALCC
Definition: BFSerial.h:24
 
#define BFSERIALEXPORT
Definition: BFSerial.h:20
 
void *** Bd
Definition: BFType.h:88
 
struct _SerRefStruc * pSerRefStruc
 
_DataBits
Definition: BFSerial.h:46
 
struct _SerRefStruc SerRefStruc
 
Definition: BFSerial.h:57
 
Definition: BFSerial.h:58
 
BFSERIALEXPORT BFRC BFSERIALCC BFSVersion(PBFU32 pMajorVersion, PBFU32 pMinorVersion)
 
Definition: BFSerial.h:50
 
BFSERIALEXPORT int BFSERIALCC clBFGetSerialRef(unsigned int portNum, void **serBFRefPtr)
 
Definition: BFSerial.h:49
 
BFSERIALEXPORT int BFSERIALCC clBFSerialInitFromBoardHandle(Bd hBoard, void **serialRefPtr)