mirror of
https://github.com/esphome/esphome.git
synced 2024-09-02 00:20:30 +02:00
Release BT controller unused memory in the right place (#1095)
This commit is contained in:
parent
148f5d9418
commit
ca4107d450
|
@ -99,14 +99,14 @@ bool ESP32BLETracker::ble_setup() {
|
|||
return false;
|
||||
}
|
||||
|
||||
esp_bt_controller_mem_release(ESP_BT_MODE_CLASSIC_BT);
|
||||
|
||||
// Initialize the bluetooth controller with the default configuration
|
||||
if (!btStart()) {
|
||||
ESP_LOGE(TAG, "btStart failed: %d", esp_bt_controller_get_status());
|
||||
return false;
|
||||
}
|
||||
|
||||
esp_bt_controller_mem_release(ESP_BT_MODE_CLASSIC_BT);
|
||||
|
||||
err = esp_bluedroid_init();
|
||||
if (err != ESP_OK) {
|
||||
ESP_LOGE(TAG, "esp_bluedroid_init failed: %d", err);
|
||||
|
|
Loading…
Reference in New Issue
Block a user