File tree Expand file tree Collapse file tree 2 files changed +5
-16
lines changed
Expand file tree Collapse file tree 2 files changed +5
-16
lines changed Original file line number Diff line number Diff line change 1717#if SOC_BT_SUPPORTED
1818#ifdef CONFIG_BT_ENABLED
1919
20- #if CONFIG_IDF_TARGET_ESP32
21- bool btInUse () {
22- return true;
23- }
24- #else
25- // user may want to change it to free resources
26- __attribute__((weak )) bool btInUse () {
27- return true;
28- }
29- #endif
30-
3120#include "esp_bt.h"
3221
3322#ifdef CONFIG_BTDM_CONTROLLER_MODE_BTDM
Original file line number Diff line number Diff line change @@ -305,11 +305,11 @@ void initArduino() {
305305 if (err ) {
306306 log_e ("Failed to initialize NVS! Error: %u" , err );
307307 }
308- // #if defined(CONFIG_BT_ENABLED) && SOC_BT_SUPPORTED
309- // if (!btInUse()) {
310- // esp_bt_controller_mem_release(ESP_BT_MODE_BTDM);
311- // }
312- // #endif
308+ #if defined(CONFIG_BT_ENABLED ) && SOC_BT_SUPPORTED
309+ if (!btInUse ()) {
310+ esp_bt_controller_mem_release (ESP_BT_MODE_BTDM );
311+ }
312+ #endif
313313 init ();
314314 initVariant ();
315315}
You can’t perform that action at this time.
0 commit comments