mirror of
https://github.com/espressif/esp-nimble.git
synced 2026-10-08 23:57:21 +00:00
BLE Host - Rename parameter for clarity
X-Original-Commit: 03650bcaf55c9d0fec4178f69635b6f7553ae6ac
This commit is contained in:
@@ -556,7 +556,7 @@ int ble_gap_connect(uint8_t own_addr_type, const ble_addr_t *peer_addr,
|
|||||||
int ble_gap_conn_cancel(void);
|
int ble_gap_conn_cancel(void);
|
||||||
int ble_gap_conn_active(void);
|
int ble_gap_conn_active(void);
|
||||||
int ble_gap_terminate(uint16_t conn_handle, uint8_t hci_reason);
|
int ble_gap_terminate(uint16_t conn_handle, uint8_t hci_reason);
|
||||||
int ble_gap_wl_set(const ble_addr_t *addr, uint8_t white_list_count);
|
int ble_gap_wl_set(const ble_addr_t *addrs, uint8_t white_list_count);
|
||||||
int ble_gap_update_params(uint16_t conn_handle,
|
int ble_gap_update_params(uint16_t conn_handle,
|
||||||
const struct ble_gap_upd_params *params);
|
const struct ble_gap_upd_params *params);
|
||||||
int ble_gap_dbg_update_active(uint16_t conn_handle);
|
int ble_gap_dbg_update_active(uint16_t conn_handle);
|
||||||
|
|||||||
@@ -1434,13 +1434,13 @@ ble_gap_wl_tx_clear(void)
|
|||||||
/**
|
/**
|
||||||
* Overwrites the controller's white list with the specified contents.
|
* Overwrites the controller's white list with the specified contents.
|
||||||
*
|
*
|
||||||
* @param addr The entries to write to the white list.
|
* @param addrs The entries to write to the white list.
|
||||||
* @param white_list_count The number of entries in the white list.
|
* @param white_list_count The number of entries in the white list.
|
||||||
*
|
*
|
||||||
* @return 0 on success; nonzero on failure.
|
* @return 0 on success; nonzero on failure.
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
ble_gap_wl_set(const ble_addr_t *addr, uint8_t white_list_count)
|
ble_gap_wl_set(const ble_addr_t *addrs, uint8_t white_list_count)
|
||||||
{
|
{
|
||||||
#if !MYNEWT_VAL(BLE_WHITELIST)
|
#if !MYNEWT_VAL(BLE_WHITELIST)
|
||||||
return BLE_HS_ENOTSUP;
|
return BLE_HS_ENOTSUP;
|
||||||
@@ -1459,8 +1459,8 @@ ble_gap_wl_set(const ble_addr_t *addr, uint8_t white_list_count)
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < white_list_count; i++) {
|
for (i = 0; i < white_list_count; i++) {
|
||||||
if (addr[i].type != BLE_ADDR_PUBLIC &&
|
if (addrs[i].type != BLE_ADDR_PUBLIC &&
|
||||||
addr[i].type != BLE_ADDR_RANDOM) {
|
addrs[i].type != BLE_ADDR_RANDOM) {
|
||||||
|
|
||||||
rc = BLE_HS_EINVAL;
|
rc = BLE_HS_EINVAL;
|
||||||
goto done;
|
goto done;
|
||||||
@@ -1473,7 +1473,7 @@ ble_gap_wl_set(const ble_addr_t *addr, uint8_t white_list_count)
|
|||||||
}
|
}
|
||||||
|
|
||||||
BLE_HS_LOG(INFO, "GAP procedure initiated: set whitelist; ");
|
BLE_HS_LOG(INFO, "GAP procedure initiated: set whitelist; ");
|
||||||
ble_gap_log_wl(addr, white_list_count);
|
ble_gap_log_wl(addrs, white_list_count);
|
||||||
BLE_HS_LOG(INFO, "\n");
|
BLE_HS_LOG(INFO, "\n");
|
||||||
|
|
||||||
rc = ble_gap_wl_tx_clear();
|
rc = ble_gap_wl_tx_clear();
|
||||||
@@ -1482,7 +1482,7 @@ ble_gap_wl_set(const ble_addr_t *addr, uint8_t white_list_count)
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < white_list_count; i++) {
|
for (i = 0; i < white_list_count; i++) {
|
||||||
rc = ble_gap_wl_tx_add(addr + i);
|
rc = ble_gap_wl_tx_add(addrs + i);
|
||||||
if (rc != 0) {
|
if (rc != 0) {
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
@@ -2353,7 +2353,8 @@ ble_gap_conn_create_tx(uint8_t own_addr_type, const ble_addr_t *peer_addr,
|
|||||||
* already in progress;
|
* already in progress;
|
||||||
* BLE_HS_EBUSY if initiating a connection is not
|
* BLE_HS_EBUSY if initiating a connection is not
|
||||||
* possible because scanning is in progress;
|
* possible because scanning is in progress;
|
||||||
* BLE_HS_EDONE if the specified peer is already connected;
|
* BLE_HS_EDONE if the specified peer is already
|
||||||
|
* connected;
|
||||||
* Other nonzero on error.
|
* Other nonzero on error.
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
|
|||||||
Reference in New Issue
Block a user