ContentsIndex
PreviousUpNext
Connection Manager
Topics | Functions | Structs, Records, Enums | Types
Description

Provides functions for applications to configure, monitor, search Bluetooth connections.

Introduction

An application calls vm_bt_cm_init() to initialize a Bluetooth module and register a callback for various connection events, and calls vm_bt_cm_exit() to exit and release resources from the Bluetooth module. The application can turn on or turn off the Bluetooth by calling vm_bt_cm_switch_on() or vm_bt_cm_switch_off(). It sets the Bluetooth visibility through vm_bt_cm_set_visibility(), so that the Bluetooth device becomes discoverable. It also can search for the Bluetooth enabled device around by calling vm_bt_cm_search().

Limitation

N/A

Group
Functions
Function 
Description 
Exits the Bluetooth Connection Manager and releases the resources. 
Gets the device info 
Gets the device number according to device type 
Gets the host device information. 
Gets the current power status of the Bluetooth. 
This function is to get the BT visibility 
Initializes the Bluetooth Connection Manager and registers the callback. The callback will be triggered when the events occur, as specified by the event_mask. 
Releases all active Bluetooth connections. When it completes, the callback is invoked through the VM_BT_CM_EVENT_RELEASE_ALL_CONN event. 
Searches for the Bluetooth devices.The search process could trigger two events, the VM_BT_CM_EVENT_INQUIRY_IND and VM_BT_CM_EVENT_INQUIRY_COMPLETE, which in turn triggers the callback. 
Aborts the search process. It invokes srv_bt_cm_cancel_discovery_req_hdler. A callback will be invoked by the VM_BT_CM_EVENT_INQUIRY_COMPLETE event, after the cancelling of the search procedure is complete. 
Processes the pairing request and sends the passkey when the VM_BT_CM_PAIR_IND event occurs. 
Sets the Bluetooth pairing type. This function should be called prior to the VM_BT_CM_PAIR_IND event occurs, to properly configure the expected pairing method. 
Sets the host device name. It will trigger the VM_BT_CM_EVENT_SET_NAME event, after the host device name procedure is completed. 
Sets the Bluetooth visibility, so that other devices can detect it. 
Switches off the Bluetooth chipset. It also deactivates the Bluetooth profiles. If there are any active connections, it will disconnect the connections before switching off the Bluetooth chipset. 
Switches on the Bluetooth chipset. It also activates the Bluetooth profiles that are registered to the Connection Manager. 
Structs, Records, Enums
Struct, Record, Enum 
Description 
Event struct for VM_BT_CM_EVENT_ACTIVATE & VM_BT_CM_EVENT_BLE_ACTIVATE. 
Bluetooth address. 
Event struct for VM_BT_CM_EVENT_DEACTIVATE. 
Bluetooth device type 
Device info structure. 
Error code of the Bluetooth 
Event definitions of the Bluetooth 
Event struct for VM_BT_CM_EVENT_INQUIRY_COMPLETE 
Event struct for VM_BT_CM_EVENT_INQUIRY_IND. 
Pairing indication struct. 
Pairing method. 
The power status of the Bluetooth. 
Event struct for VM_BT_CM_EVENT_SET_NAME. 
Event struct for VM_BT_CM_EVENT_SET_VISIBILITY. 
Bluetooth visibility type enum 
Types
Type 
Description 
The prototype of the callback function for event notification from the Bluetooth Connection Manager. 
Bluetooth Connection Manager resource handle 
Links
Created with a commercial version of Doc-O-Matic. In order to make this message disappear you need to register this software. If you have problems registering this software please contact us at support@toolsfactory.com.