BthInitiateBonding (Compact 2013)
3/26/2014
This function uses a PIN to make a pair request to a Bluetooth device.
Syntax
BOOL BthInitiateBonding (
BT_ADDR* pBA,
LPCTSTR tszPin
);
Parameters
- pBA
[in] Pointer to the address of the peer device.
- tszPin
[in] The PIN.
Return Value
Returns TRUE on success; otherwise, FALSE. To get extended error information, call GetLastError.
Remarks
This function passes the parameters to the BthPairRequest function and returns TRUE if the pair request succeeds. If the pair request does not succeed, it calls BthRevokePIN and returns FALSE. The PIN passed into tszPin is converted to a multi-byte string before it is passed to BthPairRequest.