Bluetooth Framework C++ Edition

◆ Connect()

int Connect ( const __int64  Address,
const bool  ConnectOnRead,
const bool  ForceNotifications 
)

Connects to a remote device.

Parameters
AddressA remote device MAC address.
ConnectOnReadA Boolean indicates whether a connection should made during Connect call or on first services read. True indicates that the connection should be executed on first services read on when OS decided to do that.
ForceNotificationsA Boolean indicates that the notifications (and/or indications) should be forced. This should be set to True for some boards (such as Bluno, Bluno Mega and some others) that do not have Characteristic Client Configuration Descriptor.
Returns
If the function succeed the return value is WCL_E_SUCCESS. Otherwise the method returns one of the WCL error codes.

The method starts a connection operation to a remote device. If the method success that does not mean that the connection was established. That just means that the connection operation was started. The real connection result will be passed to the OnConnect event handler.