File tree 1 file changed +2
-4
lines changed
1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -1038,18 +1038,16 @@ bool NimBLEDevice::setOwnAddrType(uint8_t type) {
1038
1038
1039
1039
m_ownAddrType = type;
1040
1040
1041
+ # if MYNEWT_VAL(BLE_HOST_BASED_PRIVACY)
1041
1042
if (type == BLE_OWN_ADDR_RPA_PUBLIC_DEFAULT || type == BLE_OWN_ADDR_RPA_RANDOM_DEFAULT) {
1042
- # ifdef CONFIG_IDF_TARGET_ESP32
1043
1043
// esp32 controller does not support RPA so we must use the random static for calls to the stack
1044
1044
// the host will take care of the random private address generation/setting.
1045
1045
m_ownAddrType = BLE_OWN_ADDR_RANDOM;
1046
1046
rc = ble_hs_pvcy_rpa_config (NIMBLE_HOST_ENABLE_RPA);
1047
- # endif
1048
1047
} else {
1049
- # ifdef CONFIG_IDF_TARGET_ESP32
1050
1048
rc = ble_hs_pvcy_rpa_config (NIMBLE_HOST_DISABLE_PRIVACY);
1051
- # endif
1052
1049
}
1050
+ # endif
1053
1051
1054
1052
return rc == 0 ;
1055
1053
} // setOwnAddrType
You can’t perform that action at this time.
0 commit comments