eZ430 Chronos 的 eZ430_Chronos_CC.dll 中提供的函数收集

eZ430 Chronos 的 eZ430_Chronos_CC.dll 中提供的函数收集

///////////////////////////////////////////////
// COM Port Management
// 1. Opening the COM port
bool BM_OpenCOM( char * strPortName,
DWORD dwBaudrate = 115200,
WORD wTimeout = 30,
bool bRTS = false,
bool bDTR = false);

// 2. Closing the COM port
void BM_CloseCOM(void);

// 3. Locating the RF access point
bool BM_GetCOM(unsigned char& bPortNb);

// 4. Resetting the RF access point
bool BM_Reset(void);

// 5. Read status from RF access point
bool BM_GetStatus(WORD& wStatus);


///////////////////////////////////////////////
// BlueRobin Functions
// 1. Set BlueRobin Heart Rate
bool BM_BR_SetHeartrate(WORD wHeartrate);

// 2. Set BlueRobin ID
bool BM_BR_SetID(DWORD dwID);

// 3. Read BlueRobin ID
bool BM_BR_GetID(DWORD& dwID);

// 4. Start BlueRobin transmission
// This command starts the BlueRobin transmission.
bool BM_BR_Start(void);

// 5. Stop BlueRobin transmission
// This command stops the BlueRobin transmission.
bool BM_BR_Stop(void);


///////////////////////////////////////////////
// SimpliciTI Functions
// 1. Start SimpliciTI in acc/ppt mode
// This command starts SimpliciTI in acc/ppt mode.
bool BM_SPL_Start(void);

// 2. Start SimpliciTI in sync mode
// This command starts SimpliciTI in sync mode.
bool BM_SYNC_Start(void);

// 3. Stop SimpliciTI
// This command exits the SimpliciTI stack.
bool BM_SPL_Stop(void);

// 4. Read SimpliciTI acc/ppt data
// This command reads the received data from the RF access point buffer.
bool BM_SPL_GetData(DWORD& wData);

/* Parameters
wData
4 byte data (byte3, byte2, byte1, byte0)
byte3 = Acceleration value Z-axis
byte2 = Acceleration value Y-axis
byte1 = Acceleration value X-axis
byte0 = 0x11 → Left mouse click (acc mode)
byte0 = 0x21 → Left mouse double-click (acc mode)
byte0 = 0x31 → Right mouse click (acc mode)
byte0 = 0x12 → Button * (ppt mode)
byte0 = 0x22 → Button # (ppt mode)
byte0 = 0x32 → Button ↑ (ppt mode)
byte0 = 0xFF → Data has been read before
*/

// 5. Read SimpliciTI sync buffer status
// This command reads the buffer status during sync mode from the RF access point buffer.
bool BM_SYNC_GetBufferStatus(WORD& wStatus);

// 6. Read SimpliciTI sync buffer
// This command reads the buffer content during sync mode.
bool BM_SYNC_ReadBuffer(BYTE * bData);


///////////////////////////////////////////////
// Wireless Update Functions
// 1. Start wireless update
// This command starts SimpliciTI in acc/ppt mode.
BR_COMM_API bool BM_WBSL_Start(void)

// 2. Stop wireless update
This command exits the SimpliciTI stack.
BR_COMM_API bool BM_WBSL_Stop(void)

// 3. Get status of update
// This command reads the buffer status during sync mode from the RF access point buffer.
BR_COMM_API bool BM_WBSL_GetStatus(DWORD& wData)

/* Parameters
dwData
Status
1 = linking
2 = linked
4 = error
*/

// 4. Send Data (Text File parts) to the End Device
// This command reads the buffer status during sync mode from the RF access point buffer.
BR_COMM_API bool BM_WBSL_Send_Data(BYTE * data, int len, DWORD& dwData)

/* Parameters
data
Pointer to byte array
len
Array length
dwData
Return value 
*/

// 5. Get status of packet (checks if a new packet needs to be sent from the GUI)
// This command reads the buffer status during sync mode from the RF access point buffer.
BR_COMM_API bool BM_WBSL_GetPacketStatus(DWORD& wData)

/* Return Value
dwData
0x80 = error
0x01 = disabled
0x02 = processing packet
0x04 = send info packet
0x08 = send new data packet
*/

你可能感兴趣的:(eZ430 Chronos 的 eZ430_Chronos_CC.dll 中提供的函数收集)