nRF Connect SDK API 0.1.0
|
BT Scanning module. More...
Modules | |
Filter modes | |
Data Structures | |
struct | bt_scan_filter_info |
Filter information structure. More... | |
struct | bt_filter_status |
Filter status structure. More... | |
struct | bt_scan_adv_info |
Advertising info structure. More... | |
struct | bt_scan_short_name |
A helper structure to set filters for the name. More... | |
struct | bt_scan_manufacturer_data |
A helper structure to set filters for the manufacturer data. More... | |
struct | bt_scan_init_param |
Structure for Scanning Module initialization. More... | |
struct | bt_scan_name_filter_status |
Name filter status structure, used to inform the application which name filter is matched. More... | |
struct | bt_scan_addr_filter_status |
Address filter status structure, used to inform the application which address filter is matched. More... | |
struct | bt_scan_uuid_filter_status |
UUID filter status structure, used to inform the application which UUID filters are matched. More... | |
struct | bt_scan_appearance_filter_status |
Appearance filter status structure, used to inform the application which appearance filter is matched. More... | |
struct | bt_scan_manufacturer_data_filter_status |
Manufacturer data filter status structure, used to inform the application which manufacturer data filter is matched. More... | |
struct | bt_scan_filter_match |
Structure for setting the filter status. More... | |
struct | bt_scan_device_info |
Structure containing device data needed to establish connection and advertising information. More... | |
struct | cb_data |
Data for scanning callback structure. More... | |
struct | bt_scan_cb |
Scanning callback structure. More... | |
Macros | |
#define | BT_SCAN_CB_INIT(_name, match_fun, no_match_fun, error_fun, connecting_fun) |
Initializing macro for scanning module. | |
Enumerations | |
enum | bt_scan_type { BT_SCAN_TYPE_SCAN_PASSIVE , BT_SCAN_TYPE_SCAN_ACTIVE } |
Scan types. More... | |
enum | bt_scan_filter_type { BT_SCAN_FILTER_TYPE_NAME , BT_SCAN_FILTER_TYPE_SHORT_NAME , BT_SCAN_FILTER_TYPE_ADDR , BT_SCAN_FILTER_TYPE_UUID , BT_SCAN_FILTER_TYPE_APPEARANCE , BT_SCAN_FILTER_TYPE_MANUFACTURER_DATA } |
Types of filters. More... | |
Functions | |
void | bt_scan_cb_register (struct bt_scan_cb *cb) |
Register scanning callbacks. | |
void | bt_scan_init (const struct bt_scan_init_param *init) |
Function for initializing the Scanning Module. | |
int | bt_scan_start (enum bt_scan_type scan_type) |
Function for starting scanning. | |
int | bt_scan_stop (void) |
Function for stopping scanning. | |
void | bt_scan_update_init_conn_params (struct bt_le_conn_param *new_conn_param) |
Function to update initial connection parameters. | |
int | bt_scan_filter_enable (uint8_t mode, bool match_all) |
Function for enabling filtering. | |
void | bt_scan_filter_disable (void) |
Function for disabling filtering. | |
int | bt_scan_filter_status_get (struct bt_filter_status *status) |
Function for getting filter status. | |
int | bt_scan_filter_add (enum bt_scan_filter_type type, const void *data) |
Function for adding any type of filter to the scanning. | |
void | bt_scan_filter_remove_all (void) |
Function for removing all set filters. | |
int | bt_scan_params_set (struct bt_le_scan_param *scan_param) |
Function for changing the scanning parameters. | |
void | bt_scan_conn_attempts_filter_clear (void) |
Clear connection attempts filter. | |
int | bt_scan_blocklist_device_add (const bt_addr_le_t *addr) |
Add a new device to the blocklist. | |
void | bt_scan_blocklist_clear (void) |
Clear the blocklist of the scanning module device. | |
void | bt_scan_update_connect_if_match (bool connect_if_match) |
Function to update the autoconnect flag after a filter match. | |
BT Scanning module.
The Scanning Module handles the Bluetooth LE scanning for your application. The module offers several criteria for filtering the devices available for connection, and it can also work in the simple mode without using the filtering. If an event handler is provided, your main application can react to a filter match. The module can also be configured to automatically connect after it matches a filter.