Skip to content

Commit 4f2105d

Browse files
committed
Merge branch 'feat/support_ble_debug_with_gpio' into 'master'
Support BLE debug with GPIO on ESP32 Closes BLERP-1519 See merge request espressif/esp-idf!36621
2 parents b51d4d2 + 0a7888f commit 4f2105d

File tree

3 files changed

+22
-2
lines changed

3 files changed

+22
-2
lines changed

components/bt/controller/esp32/Kconfig.in

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,16 @@ config BTDM_BLE_VS_QA_SUPPORT
528528
help
529529
This enables BLE vendor HCI command and event for QA.
530530

531+
config BTDM_CTRL_CONTROLLER_DEBUG_MODE_1
532+
visible if 0
533+
bool "Enable Bluetooth controller debugging mode 1 (for internal use only)"
534+
default n
535+
depends on BT_ENABLED
536+
help
537+
Enables specific debugging features for the Bluetooth controller.
538+
This option is strictly for internal debugging purposes and should not be enabled in production environments,
539+
as it may impact performance and stability.
540+
531541
config BTDM_RESERVE_DRAM
532542
hex
533543
default 0xdb5c if BT_ENABLED

components/bt/controller/lib_esp32

components/bt/include/esp32/include/esp_bt.h

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,16 @@ the advertising packet will be discarded until the memory is restored. */
205205
#define BTDM_BLE_CHAN_ASS_EN (0)
206206
#endif
207207

208+
#if CONFIG_BTDM_CTRL_CONTROLLER_DEBUG_MODE_1
209+
#define BTDM_CTRL_CONTROLLER_DEBUG_MODE_1 (1 << 1)
210+
#else
211+
#define BTDM_CTRL_CONTROLLER_DEBUG_MODE_1 0
212+
#endif
213+
214+
#ifndef BTDM_CTRL_CONTROLLER_DEBUG_FLAG
215+
#define BTDM_CTRL_CONTROLLER_DEBUG_FLAG (BTDM_CTRL_CONTROLLER_DEBUG_MODE_1 | CONTROLLER_ADV_LOST_DEBUG_BIT)
216+
#endif
217+
208218
#if defined(CONFIG_BTDM_BLE_PING_EN)
209219
#define BTDM_BLE_PING_EN (CONFIG_BTDM_BLE_PING_EN)
210220
#else
@@ -224,7 +234,7 @@ the advertising packet will be discarded until the memory is restored. */
224234
.normal_adv_size = NORMAL_SCAN_DUPLICATE_CACHE_SIZE, \
225235
.mesh_adv_size = MESH_DUPLICATE_SCAN_CACHE_SIZE, \
226236
.send_adv_reserved_size = SCAN_SEND_ADV_RESERVED_SIZE, \
227-
.controller_debug_flag = CONTROLLER_ADV_LOST_DEBUG_BIT, \
237+
.controller_debug_flag = BTDM_CTRL_CONTROLLER_DEBUG_FLAG, \
228238
.mode = BTDM_CONTROLLER_MODE_EFF, \
229239
.ble_max_conn = CONFIG_BTDM_CTRL_BLE_MAX_CONN_EFF, \
230240
.bt_max_acl_conn = CONFIG_BTDM_CTRL_BR_EDR_MAX_ACL_CONN_EFF, \

0 commit comments

Comments
 (0)