Skip to content

Commit 9acd005

Browse files
committed
Merge branch 'feat/get_ble_resolve_address_status' into 'master'
feat(ble/bluedroid): Support resolve BLE address for interval usage Closes BLERP-1054 See merge request espressif/esp-idf!33741
2 parents 814d583 + b88b511 commit 9acd005

File tree

3 files changed

+14
-2
lines changed

3 files changed

+14
-2
lines changed

components/bt/host/bluedroid/btc/core/btc_main.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,12 @@ uint32_t btc_get_ble_status(void)
141141
status |= BIT(BTC_BLE_STATUS_CONN);
142142
}
143143

144+
// Address resolve status
145+
extern uint8_t btm_get_ble_addr_resolve_status(void);
146+
if (btm_get_ble_addr_resolve_status()) {
147+
status |= BIT(BTC_BLE_STATUS_ADDR_RESOLVE);
148+
}
149+
144150
#if (SMP_INCLUDED == TRUE)
145151
// Number of recorded devices
146152
extern uint8_t btm_ble_sec_dev_active_count(void);

components/bt/host/bluedroid/btc/include/btc/btc_main.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ typedef enum {
4040
BTC_BLE_STATUS_GATTC_APP, // GATTC application exist
4141
BTC_BLE_STATUS_GATTS_SRVC, // GATTS service exist
4242
BTC_BLE_STATUS_PRIVACY, // Privacy enabled
43+
BTC_BLE_STATUS_ADDR_RESOLVE,// Address resolution status
4344
} tBTC_BLE_STATUS;
4445

4546
future_t **btc_main_get_future_p(btc_main_future_type_t type);

components/bt/host/bluedroid/stack/btm/btm_main.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,10 +134,15 @@ uint8_t btm_acl_active_count(void)
134134

135135
return count;
136136
}
137+
#if (BLE_INCLUDED == TRUE)
138+
// address resolution status
139+
uint8_t btm_get_ble_addr_resolve_status(void)
140+
{
141+
return (uint8_t) btm_cb.addr_res_en;
142+
}
137143

138144
void btm_ble_addr_resolve_enable(bool enable)
139145
{
140-
#if (BLE_INCLUDED == TRUE)
141146
btm_cb.addr_res_en = enable;
142-
#endif
143147
}
148+
#endif /*BLE_INCLUDED*/

0 commit comments

Comments
 (0)