Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
87 commits
Select commit Hold shift + click to select a range
91cd08d
feat(usb_device): Update examples to esp_tinyusb v2.0.0
roma-jam Aug 28, 2025
c1bb692
feat(network): Update sta2eth example to esp_tinyusb v2.0.0
roma-jam Aug 28, 2025
b1461ec
docs(ble): Updated NimBLE certification info
weiyuhannnn Oct 10, 2025
a11c5c6
doc(temperature_sensor): Update temperature snesor docs, remove inacc…
mythbuster5 Jul 4, 2025
407068e
docs(uhci): Fix uhci compiling on non-supported target
mythbuster5 Sep 1, 2025
b2816e2
docs(uhci): implementation for uart-dma (uhci) docs
mythbuster5 Apr 23, 2025
dcb4275
bugfix(wifi): Improve FTM Query logging for AP-Sta mode
Jun 9, 2025
2fbfe3b
fix(ble/bluedroid): fix memory leak during deinit when service table …
esp-zhp Oct 17, 2025
cc0aca6
fix(ble): update the example docs for pawr
ChrysalisChenJ Oct 20, 2025
e266f8a
feat(ble): allow a larger sca limit on ESP32-C2
ChrysalisChenJ Oct 16, 2025
854708d
feat(ble): allow a larger sca limit on ESP32-C6
ChrysalisChenJ Oct 16, 2025
3f09e6d
feat(ble): allow a larger sca limit on ESP32-H2
ChrysalisChenJ Oct 16, 2025
cc935d0
fix(bt/btc): Fix array compared against 0 in btc_manage.c
Finney-esp Aug 22, 2025
e3f0e1e
fix(esp_coex): Fix the issue of uninitialized pointer reading in coex…
Finney-esp Oct 20, 2025
6c502bd
Merge branch 'bugfix/ftm_example_issues_v5.3' into 'release/v5.3'
Oct 20, 2025
58116f2
Merge branch 'feature/usb_device_examples_update_v2.0.0_backport_v5.3…
suda-morris Oct 20, 2025
a071716
fix(esp_eth): Fixed W5500 poor performance in 10M mode
kostaond Oct 17, 2025
77126ab
fix(kconfig.cmake): Do not regenerate unnecessary config files
Honza0297 Sep 26, 2025
366f35b
Merge branch 'bugfix/fix_bt_coverity_v5.3' into 'release/v5.3'
Oct 20, 2025
7e13aa9
Merge branch 'bugfix/fix_ble_deinit_memory_leak_v5.3' into 'release/v…
Isl2017 Oct 21, 2025
2f7fbba
ci(github-docker-build): add GH hosted large runner for docker builds
tomassebestik Oct 17, 2025
2348f03
Merge branch 'doc/tsens_uhci_v5.3' into 'release/v5.3'
suda-morris Oct 21, 2025
e0b5b52
fix(nvs): fixed erasing of old values if new data type is not the same
rrtandler Mar 19, 2025
58f98e9
refactor(nvs_flash): Improved Blob performance
rrtandler May 9, 2025
fab1e2e
fix(nvs_flash): Fixed overwrite of V1 BLOB when legacy compatibility …
rrtandler Sep 4, 2025
83fe571
feat(ble/bluedroid): add API to get local BLE IRK
esp-zhp Oct 21, 2025
07990e3
Merge branch 'ci/github-docker-build_v5.3' into 'release/v5.3'
dobairoland Oct 21, 2025
2cc0825
fix: Added check to prevent IDF root directory build failed attempts …
jakub-kocka Sep 18, 2025
4d34845
fix(ble): fix ci power save test connection failure
xiongweichao Oct 16, 2025
c43592c
feat(openthread): add openthread start stop APIs
gytxxsy Jun 11, 2025
a0fbf27
feat(openthread): add common components for openthread examples
gytxxsy Sep 16, 2025
4b7f105
feat(openthread): examples adaptation of new APIs
gytxxsy Oct 21, 2025
909420f
Merge branch 'fix/w5500_10m_mode_v5_3' into 'release/v5.3'
suda-morris Oct 22, 2025
fd0fd24
Merge branch 'feat/add_openthread_start_stop_api_v5.3' into 'release/…
chshu Oct 22, 2025
d53a579
Merge branch 'bugfix/ci_c3eco7_pwr_save_fail_v5.3' into 'release/v5.3'
wmy-espressif Oct 22, 2025
fdbd075
feat(nimble): Add support for HCI commands / events
rahult-github Sep 25, 2025
0c55c77
change(ble): [AUTO_MR] Update lib_esp32h2 to a76948d4
Oct 23, 2025
00feb23
change(ble): [AUTO_MR] Update lib_esp32c6 to a76948d4
Oct 23, 2025
2a872ac
change(ble): [AUTO_MR] Update lib_esp32c2 to 283861b8
Oct 23, 2025
b3c5f70
change(ble): [AUTO_MR] updated rom linker script for ESP32-C2
Oct 23, 2025
a1e7e10
fix(ble): fix ble wakeup causes error on ESP32-C2
Oct 23, 2025
7c9ae1d
fix(ble): fix ble wakeup causes error on ESP32-C6
Oct 23, 2025
8acba30
fix(ble): fix ble wakeup causes error on ESP32-H2
Oct 23, 2025
2dd08b4
feat(ble): add priority level config on ESP32-C6
Oct 23, 2025
c6cf910
feat(ble): add priority level config on ESP32-H2
Oct 23, 2025
5943637
ci(ulp): reset board between ulp-fsm tests
ESP-Marius Oct 24, 2025
b8aa5a6
Merge branch 'feat/support_get_ble_local_irk_v5.3' into 'release/v5.3'
Isl2017 Oct 24, 2025
9d22e7d
Merge branch 'ci/ulp_fsm_reset_between_tests_v5.3' into 'release/v5.3'
ESP-Marius Oct 24, 2025
89a132b
Merge branch 'feature/storage_nvs_perf_blob_v5.3' into 'release/v5.3'
pacucha42 Oct 24, 2025
e53cf77
dma: fixed issue that DMA are not reset when CPU reset
ginkgm Aug 26, 2025
83a296f
Merge branch 'fix/cpu_reset_dma_v5.3' into 'release/v5.3'
suda-morris Oct 26, 2025
8f1ccb8
Merge branch 'change/ble_update_lib_20251022_v5.3' into 'release/v5.3'
Isl2017 Oct 27, 2025
2815a78
fix(test): deley some time to ensure gptimer is stopped
suda-morris Oct 24, 2025
6485db6
test(pcnt): expend assert value to decrease failure ratio
Kainarx Oct 24, 2025
7cc0ea8
feat(openthread): support custom netif config during initialization
gytxxsy Oct 23, 2025
0bf4a8e
feat(openthread): update examples for API changes
gytxxsy Oct 24, 2025
213c318
feat(openthread): update OT upstream to 36b14d3ef
tanyanquan Oct 22, 2025
befb2f8
feat(openthread): support OT upstream dhcpv6 feature
tanyanquan Oct 22, 2025
34e2726
fix(jpeg): Add check for jpeg marker parser in order to enhance safety
mythbuster5 Oct 9, 2025
b7c3085
Merge branch 'fix/dont-regenerate-unnecessary-config-files_v5.3' into…
dobairoland Oct 27, 2025
6c0e3b9
Merge branch 'fix/root_build_error_v5.3' into 'release/v5.3'
dobairoland Oct 27, 2025
814bda6
Merge branch 'feat/read_all_local_remote_sup_feat_v5.3' into 'release…
rahult-github Oct 27, 2025
b6370af
Merge branch 'fix/anacmpr_etm_test_v5.3' into 'release/v5.3'
suda-morris Oct 28, 2025
0b0b59f
fix(bt/bluedroid): fixed potential OOB in AVRCP vendor command compos…
BetterJincheng Oct 9, 2025
450ee33
fix(esp32p4): P4 touch channel 14 failure fix
kabaragoya-loves-you Oct 22, 2025
c1a0caf
ci(touch): add test case for the curr measuring channel
L-KAYA Oct 22, 2025
0c4c585
Merge branch 'fix/update_pawr_example_docs_v5.3' into 'release/v5.3'
Isl2017 Oct 28, 2025
01aa513
fix(gptimer): update regex patterns in example test to include non-di…
suda-morris Oct 27, 2025
21bb5fd
Merge branch 'docs/update_nimble_pts_info_v5.3' into 'release/v5.3'
Isl2017 Oct 28, 2025
589e80e
Merge branch 'test/expend_assert_value_v5.3' into 'release/v5.3'
suda-morris Oct 28, 2025
d8b512f
Merge branch 'feat/allow_set_ot_netif_config_v5.3' into 'release/v5.3'
chshu Oct 28, 2025
c459a44
feat(openthread): update thread-lib for new OT upstream 36b14d3ef
tanyanquan Oct 28, 2025
2144266
change(802.15.4): change the default cca threshold to -75dBm
chshu Oct 23, 2025
7ac2454
feat(openthread): add kconfig option for timing optimization
tanyanquan Oct 23, 2025
542dbbb
feat(openthread): enlarge ot_br factory binary size
zwx1995esp Apr 29, 2025
ef2a519
Merge branch 'bugfix/fix_gptimer_premature_match_partial_data_v5.3' i…
suda-morris Oct 29, 2025
8a5b82d
Merge branch 'feat/jpeg_error_check_v5.3' into 'release/v5.3'
suda-morris Oct 29, 2025
998586a
Merge branch 'feat/support_dhcpv6_v5.3' into 'release/v5.3'
chshu Oct 29, 2025
65e2cc3
Merge branch 'bugfix/fix_touch_curr_scan_workaround_on_p4_v5.3' into …
suda-morris Oct 30, 2025
3591e52
fix(nimble): Address compilation issues in nimble examples
rahult-github Oct 13, 2025
89dd237
docs(ble): Added BLE Low Power Guide
weiyuhannnn Oct 30, 2025
bd18f6e
docs(ble): Replaced BLE with Bluetooth LE
weiyuhannnn Oct 30, 2025
a721da9
fix(ble): fixed hci event log when link layer logging is disabled
Oct 30, 2025
2f7a1aa
Merge branch 'bugfix/oob_in_avrc_vendor_msg_v5.3' into 'release/v5.3'
Oct 31, 2025
2575fc5
Merge branch 'fix/hci_log_spi_out_ceva_v5.3' into 'release/v5.3'
Isl2017 Oct 31, 2025
0b56860
Merge branch 'docs/ble_add_low_power_intro_v5.3' into 'release/v5.3'
Isl2017 Nov 3, 2025
e807677
Merge branch 'bugfix/fix_compilation_issues_v5.3' into 'release/v5.3'
rahult-github Nov 3, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
# Disable the job in forks
if: ${{ github.repository_owner == 'espressif' }}

runs-on: ubuntu-latest
runs-on: ubuntu-24.04-X64-large
steps:
# Depending on the branch/tag, set CLONE_BRANCH_OR_TAG variable (used in the Dockerfile
# as a build arg) and TAG_NAME (used when tagging the image).
Expand Down
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
cmake_minimum_required(VERSION 3.16)
project(esp-idf C CXX ASM)

if(CMAKE_CURRENT_LIST_DIR STREQUAL CMAKE_SOURCE_DIR)
message(FATAL_ERROR "Current directory '${CMAKE_CURRENT_LIST_DIR}' is not buildable. "
"Change directories to one of the example projects in '${CMAKE_CURRENT_LIST_DIR}/examples' and try "
"again.")
"Change directories to one of the example projects in '${CMAKE_CURRENT_LIST_DIR}/examples' and try again.")
endif()

project(esp-idf C CXX ASM)

# Variables compile_options, c_compile_options, cxx_compile_options, compile_definitions, link_options shall
# not be unset as they may already contain flags, set by toolchain-TARGET.cmake files.

Expand Down
7 changes: 4 additions & 3 deletions components/bt/common/ble_log/ble_log_spi_out.c
Original file line number Diff line number Diff line change
Expand Up @@ -1365,12 +1365,13 @@ int ble_log_spi_out_hci_write(uint8_t source, const uint8_t *addr, uint16_t len)
return -1;
}

if (source == BLE_LOG_SPI_OUT_SOURCE_HCI_UPSTREAM) {
#if SPI_OUT_LL_ENABLED
if (source == BLE_LOG_SPI_OUT_SOURCE_HCI_UPSTREAM) {
ble_log_spi_out_ll_write(len, addr, 0, NULL, BIT(LL_LOG_FLAG_HCI_UPSTREAM));
#endif // SPI_OUT_LL_ENABLED
}
if (source == BLE_LOG_SPI_OUT_SOURCE_HCI_DOWNSTREAM) {
if (source == BLE_LOG_SPI_OUT_SOURCE_HCI_DOWNSTREAM)
#endif /* SPI_OUT_LL_ENABLED */
{
spi_out_log_cb_t *log_cb;
bool fallback = false;
if (!spi_out_get_task_mapping(LOG_MODULE_TASK_MAP(hci),
Expand Down
27 changes: 15 additions & 12 deletions components/bt/common/btc/core/btc_manage.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,20 @@
#include "btc/btc_task.h"
#include "osi/thread.h"

#if BTC_DYNAMIC_MEMORY == FALSE
void *btc_profile_cb_tab[BTC_PID_NUM] = {};
#else
#if BTC_DYNAMIC_MEMORY == TRUE
void **btc_profile_cb_tab;
#else
void *btc_profile_cb_tab[BTC_PID_NUM] = {};
#endif

void esp_profile_cb_reset(void)
{
#if BTC_DYNAMIC_MEMORY == TRUE
if (btc_profile_cb_tab == NULL) {
#if BTC_DYNAMIC_MEMORY == TRUE
void *p = btc_profile_cb_tab;
if (p == NULL) {
return;
}
#endif
#endif

int i;

Expand All @@ -31,11 +32,12 @@ void esp_profile_cb_reset(void)

int btc_profile_cb_set(btc_pid_t profile_id, void *cb)
{
#if BTC_DYNAMIC_MEMORY == TRUE
if (btc_profile_cb_tab == NULL) {
#if BTC_DYNAMIC_MEMORY == TRUE
void *p = btc_profile_cb_tab;
if (p == NULL) {
return -1;
}
#endif
#endif

if (profile_id < 0 || profile_id >= BTC_PID_NUM) {
return -1;
Expand All @@ -48,11 +50,12 @@ int btc_profile_cb_set(btc_pid_t profile_id, void *cb)

void *btc_profile_cb_get(btc_pid_t profile_id)
{
#if BTC_DYNAMIC_MEMORY == TRUE
if (btc_profile_cb_tab == NULL) {
#if BTC_DYNAMIC_MEMORY == TRUE
void *p = btc_profile_cb_tab;
if (p == NULL) {
return NULL;
}
#endif
#endif

if (profile_id < 0 || profile_id >= BTC_PID_NUM) {
return NULL;
Expand Down
4 changes: 3 additions & 1 deletion components/bt/controller/esp32c2/Kconfig.in
Original file line number Diff line number Diff line change
Expand Up @@ -458,10 +458,12 @@ config BT_LE_LL_DUP_SCAN_LIST_COUNT

config BT_LE_LL_SCA
int "BLE Sleep clock accuracy"
range 0 500
range 0 3000
default 60
help
Sleep clock accuracy of our device (in ppm)
The Bluetooth LE spec requires a Sleep Clock Accuracy (SCA) of < ±500 ppm.
This options allows for a larger value to enable the use of less accurate clock sources.

config BT_LE_LL_PEER_SCA_SET_ENABLE
bool "Enable to set constant peer SCA"
Expand Down
2 changes: 1 addition & 1 deletion components/bt/controller/esp32c2/bt.c
Original file line number Diff line number Diff line change
Expand Up @@ -749,7 +749,7 @@ void controller_wakeup_cb(void *arg)
#if CONFIG_FREERTOS_USE_TICKLESS_IDLE
static bool esp_bt_check_wakeup_by_bt(void)
{
return (esp_sleep_get_wakeup_causes() & ESP_SLEEP_WAKEUP_BT);
return (esp_sleep_get_wakeup_causes() & BIT(ESP_SLEEP_WAKEUP_BT));
}
#endif // CONFIG_FREERTOS_USE_TICKLESS_IDLE

Expand Down
66 changes: 65 additions & 1 deletion components/bt/controller/esp32c6/Kconfig.in
Original file line number Diff line number Diff line change
Expand Up @@ -552,10 +552,12 @@ config BT_LE_LL_DUP_SCAN_LIST_COUNT

config BT_LE_LL_SCA
int "BLE Sleep clock accuracy"
range 0 500
range 0 3000
default 60
help
Sleep clock accuracy of our device (in ppm)
The Bluetooth LE spec requires a Sleep Clock Accuracy (SCA) of < ±500 ppm.
This options allows for a larger value to enable the use of less accurate clock sources.

config BT_LE_LL_PEER_SCA_SET_ENABLE
bool "Enable to set constant peer SCA"
Expand Down Expand Up @@ -913,3 +915,65 @@ endmenu
config BT_LE_DTM_ENABLED
bool "Enable Direct Test Mode (DTM) feature"
default n

menu "Scheduling Priority Level Config"
choice BT_LE_ADV_SCHED_PRIO_LEVEL
prompt "The Adv scheduling priority level"
default BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
help
The Adv scheduling priority level is used for arbitration when internal scheduling conflicts.
config BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
bool "low priority level"
config BT_LE_ADV_SCHED_PRIO_MID_LEVEL
bool "medium priority level"
config BT_LE_ADV_SCHED_PRIO_HIGH_LEVEL
bool "high priority level"
endchoice

config BT_LE_DFT_ADV_SCHED_PRIO_LEVEL
int
default 0 if BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
default 1 if BT_LE_ADV_SCHED_PRIO_MID_LEVEL
default 2 if BT_LE_ADV_SCHED_PRIO_HIGH_LEVEL
default 0

choice BT_LE_PERIODIC_ADV_SCHED_PRIO_LEVEL
prompt "The Periodic Adv scheduling priority level"
default BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
help
The Periodic Adv scheduling priority level is used for arbitration when internal scheduling conflicts.
config BT_LE_PERIODIC_ADV_SCHED_PRIO_LOW_LEVEL
bool "low priority level"
config BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
bool "medium priority level"
config BT_LE_PERIODIC_ADV_SCHED_PRIO_HIGH_LEVEL
bool "high priority level"
endchoice

config BT_LE_DFT_PERIODIC_ADV_SCHED_PRIO_LEVEL
int
default 0 if BT_LE_PERIODIC_ADV_SCHED_PRIO_LOW_LEVEL
default 1 if BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
default 2 if BT_LE_PERIODIC_ADV_SCHED_PRIO_HIGH_LEVEL
default 1

choice BT_LE_SYNC_SCHED_PRIO_LEVEL
prompt "The Sync scheduling priority level"
default BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
help
The SYNC scheduling priority level is used for arbitration when internal scheduling conflicts.
config BT_LE_SYNC_SCHED_PRIO_LOW_LEVEL
bool "low priority level"
config BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
bool "medium priority level"
config BT_LE_SYNC_SCHED_PRIO_HIGH_LEVEL
bool "high priority level"
endchoice

config BT_LE_DFT_SYNC_SCHED_PRIO_LEVEL
int
default 0 if BT_LE_SYNC_SCHED_PRIO_LOW_LEVEL
default 1 if BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
default 2 if BT_LE_SYNC_SCHED_PRIO_HIGH_LEVEL
default 1
endmenu
2 changes: 1 addition & 1 deletion components/bt/controller/esp32c6/bt.c
Original file line number Diff line number Diff line change
Expand Up @@ -799,7 +799,7 @@ IRAM_ATTR void controller_wakeup_cb(void *arg)
#if CONFIG_FREERTOS_USE_TICKLESS_IDLE
static bool esp_bt_check_wakeup_by_bt(void)
{
return (esp_sleep_get_wakeup_causes() & ESP_SLEEP_WAKEUP_BT);
return (esp_sleep_get_wakeup_causes() & BIT(ESP_SLEEP_WAKEUP_BT));
}

static esp_err_t sleep_modem_ble_mac_retention_init(void *arg)
Expand Down
1 change: 1 addition & 0 deletions components/bt/controller/esp32c6/esp_bt_cfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,7 @@ extern "C" {
#define RUN_BQB_TEST (0)
#define RUN_QA_TEST (0)
#define NIMBLE_DISABLE_SCAN_BACKOFF (0)
#define BT_LL_CTRL_PRIO_LVL_CFG ((CONFIG_BT_LE_DFT_SYNC_SCHED_PRIO_LEVEL << 4) | (CONFIG_BT_LE_DFT_PERIODIC_ADV_SCHED_PRIO_LEVEL << 2) | CONFIG_BT_LE_DFT_ADV_SCHED_PRIO_LEVEL)

#ifdef __cplusplus
}
Expand Down
66 changes: 65 additions & 1 deletion components/bt/controller/esp32h2/Kconfig.in
Original file line number Diff line number Diff line change
Expand Up @@ -546,10 +546,12 @@ config BT_LE_LL_DUP_SCAN_LIST_COUNT

config BT_LE_LL_SCA
int "BLE Sleep clock accuracy"
range 0 500
range 0 3000
default 60
help
Sleep clock accuracy of our device (in ppm)
The Bluetooth LE spec requires a Sleep Clock Accuracy (SCA) of < ±500 ppm.
This options allows for a larger value to enable the use of less accurate clock sources.

config BT_LE_LL_PEER_SCA_SET_ENABLE
bool "Enable to set constant peer SCA"
Expand Down Expand Up @@ -917,3 +919,65 @@ endmenu
config BT_LE_DTM_ENABLED
bool "Enable Direct Test Mode (DTM) feature"
default n

menu "Scheduling Priority Level Config"
choice BT_LE_ADV_SCHED_PRIO_LEVEL
prompt "The Adv scheduling priority level"
default BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
help
The Adv scheduling priority level is used for arbitration when internal scheduling conflicts.
config BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
bool "low priority level"
config BT_LE_ADV_SCHED_PRIO_MID_LEVEL
bool "medium priority level"
config BT_LE_ADV_SCHED_PRIO_HIGH_LEVEL
bool "high priority level"
endchoice

config BT_LE_DFT_ADV_SCHED_PRIO_LEVEL
int
default 0 if BT_LE_ADV_SCHED_PRIO_LOW_LEVEL
default 1 if BT_LE_ADV_SCHED_PRIO_MID_LEVEL
default 2 if BT_LE_ADV_SCHED_PRIO_HIGH_LEVEL
default 0

choice BT_LE_PERIODIC_ADV_SCHED_PRIO_LEVEL
prompt "The Periodic Adv scheduling priority level"
default BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
help
The Periodic Adv scheduling priority level is used for arbitration when internal scheduling conflicts.
config BT_LE_PERIODIC_ADV_SCHED_PRIO_LOW_LEVEL
bool "low priority level"
config BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
bool "medium priority level"
config BT_LE_PERIODIC_ADV_SCHED_PRIO_HIGH_LEVEL
bool "high priority level"
endchoice

config BT_LE_DFT_PERIODIC_ADV_SCHED_PRIO_LEVEL
int
default 0 if BT_LE_PERIODIC_ADV_SCHED_PRIO_LOW_LEVEL
default 1 if BT_LE_PERIODIC_ADV_SCHED_PRIO_MID_LEVEL
default 2 if BT_LE_PERIODIC_ADV_SCHED_PRIO_HIGH_LEVEL
default 1

choice BT_LE_SYNC_SCHED_PRIO_LEVEL
prompt "The Sync scheduling priority level"
default BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
help
The SYNC scheduling priority level is used for arbitration when internal scheduling conflicts.
config BT_LE_SYNC_SCHED_PRIO_LOW_LEVEL
bool "low priority level"
config BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
bool "medium priority level"
config BT_LE_SYNC_SCHED_PRIO_HIGH_LEVEL
bool "high priority level"
endchoice

config BT_LE_DFT_SYNC_SCHED_PRIO_LEVEL
int
default 0 if BT_LE_SYNC_SCHED_PRIO_LOW_LEVEL
default 1 if BT_LE_SYNC_SCHED_PRIO_MID_LEVEL
default 2 if BT_LE_SYNC_SCHED_PRIO_HIGH_LEVEL
default 1
endmenu
2 changes: 1 addition & 1 deletion components/bt/controller/esp32h2/bt.c
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,7 @@ IRAM_ATTR void controller_wakeup_cb(void *arg)
#ifdef CONFIG_FREERTOS_USE_TICKLESS_IDLE
static bool esp_bt_check_wakeup_by_bt(void)
{
return (esp_sleep_get_wakeup_causes() & ESP_SLEEP_WAKEUP_BT);
return (esp_sleep_get_wakeup_causes() & BIT(ESP_SLEEP_WAKEUP_BT));
}

static esp_err_t sleep_modem_ble_mac_retention_init(void *arg)
Expand Down
2 changes: 1 addition & 1 deletion components/bt/controller/esp32h2/esp_bt_cfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ extern "C" {
#define RUN_BQB_TEST (0)
#define RUN_QA_TEST (0)
#define NIMBLE_DISABLE_SCAN_BACKOFF (0)

#define BT_LL_CTRL_PRIO_LVL_CFG ((CONFIG_BT_LE_DFT_SYNC_SCHED_PRIO_LEVEL << 4) | (CONFIG_BT_LE_DFT_PERIODIC_ADV_SCHED_PRIO_LEVEL << 2) | CONFIG_BT_LE_DFT_ADV_SCHED_PRIO_LEVEL)
#ifdef __cplusplus
}
#endif
Expand Down
2 changes: 1 addition & 1 deletion components/bt/controller/lib_esp32h2/esp32h2-bt-lib
22 changes: 22 additions & 0 deletions components/bt/host/bluedroid/api/esp_gap_ble_api.c
Original file line number Diff line number Diff line change
Expand Up @@ -805,6 +805,28 @@ esp_err_t esp_ble_create_sc_oob_data(void)

return (btc_transfer_context(&msg, NULL, 0, NULL, NULL) == BT_STATUS_SUCCESS ? ESP_OK : ESP_FAIL);
}

esp_err_t esp_ble_gap_get_local_irk(uint8_t local_irk[16])
{
if (local_irk == NULL) {
ESP_LOGE(__func__, "local_irk is NULL");
return ESP_ERR_INVALID_ARG;
}

if (esp_bluedroid_get_status() != ESP_BLUEDROID_STATUS_ENABLED) {
ESP_LOGE(__func__, "Bluedroid is not enabled");
return ESP_ERR_INVALID_STATE;
}

/* Use BTM API to safely retrieve local IRK */
if (BTM_GetLocalIRK(local_irk)) {
ESP_LOGD(__func__, "Local IRK retrieved successfully");
return ESP_OK;
} else {
ESP_LOGW(__func__, "Local IRK not available");
return ESP_ERR_INVALID_STATE;
}
}
#endif /* #if (SMP_INCLUDED == TRUE) */

esp_err_t esp_ble_gap_disconnect(esp_bd_addr_t remote_device)
Expand Down
23 changes: 23 additions & 0 deletions components/bt/host/bluedroid/api/include/api/esp_gap_ble_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -2088,6 +2088,7 @@ esp_err_t esp_ble_gap_set_resolvable_private_address_timeout(uint16_t rpa_timeou
*
*/
esp_err_t esp_ble_gap_add_device_to_resolving_list(esp_bd_addr_t peer_addr, uint8_t addr_type, uint8_t *peer_irk);

/**
* @brief This function clears the random address for the application
*
Expand Down Expand Up @@ -2493,6 +2494,28 @@ esp_err_t esp_ble_sc_oob_req_reply(esp_bd_addr_t bd_addr, uint8_t p_c[16], uint8
*
*/
esp_err_t esp_ble_create_sc_oob_data(void);

/**
* @brief Get the local Identity Resolving Key (IRK).
*
* @note This API retrieves the local IRK stored in the device's security database.
* The IRK is used by the controller to generate and resolve Resolvable Private Addresses (RPA).
* The IRK length is always 16 bytes (ESP_BT_OCTET16_LEN).
*
* @note Usage Restrictions: Do NOT call this API during a disconnection event or while
* a BLE disconnection is in progress. Calling this API during disconnection may lead
* to undefined behavior or accessing invalid information.
*
* @param[out] local_irk: Buffer to hold the 16-byte IRK. The array notation [16] explicitly
* indicates the required buffer size (ESP_BT_OCTET16_LEN).
*
* @return
* - ESP_OK : success
* - ESP_ERR_INVALID_ARG : local_irk is NULL
* - ESP_ERR_INVALID_STATE : BLE stack not initialized or IRK not available
*/
esp_err_t esp_ble_gap_get_local_irk(uint8_t local_irk[16]);

#endif /* #if (SMP_INCLUDED == TRUE) */

/**
Expand Down
Loading
Loading