From fe1fb25078765eb7dc9a3365deec54a49c4b9d65 Mon Sep 17 00:00:00 2001 From: xiewenxiang Date: Thu, 10 Mar 2022 10:40:12 +0800 Subject: [PATCH] doc(bt): Add description for de-initialize bt controller --- components/bt/include/esp32/include/esp_bt.h | 2 ++ components/bt/include/esp32c3/include/esp_bt.h | 2 ++ components/bt/include/esp32s3/include/esp_bt.h | 2 ++ 3 files changed, 6 insertions(+) diff --git a/components/bt/include/esp32/include/esp_bt.h b/components/bt/include/esp32/include/esp_bt.h index 65b08ab687..fad01b97bf 100644 --- a/components/bt/include/esp32/include/esp_bt.h +++ b/components/bt/include/esp32/include/esp_bt.h @@ -354,6 +354,8 @@ esp_err_t esp_bt_controller_init(esp_bt_controller_config_t *cfg); /** * @brief De-initialize BT controller to free resource and delete task. + * You should stop advertising and scanning, as well as + * disconnect all existing connections before de-initializing BT controller. * * This function should be called only once, after any other BT functions are called. * @return ESP_OK - success, other - failed diff --git a/components/bt/include/esp32c3/include/esp_bt.h b/components/bt/include/esp32c3/include/esp_bt.h index d62b7a4a94..2ec3064d6e 100644 --- a/components/bt/include/esp32c3/include/esp_bt.h +++ b/components/bt/include/esp32c3/include/esp_bt.h @@ -337,6 +337,8 @@ esp_err_t esp_bt_controller_init(esp_bt_controller_config_t *cfg); /** * @brief De-initialize BT controller to free resource and delete task. + * You should stop advertising and scanning, as well as + * disconnect all existing connections before de-initializing BT controller. * * This function should be called only once, after any other BT functions are called. * This function is not whole completed, esp_bt_controller_init cannot called after this function. diff --git a/components/bt/include/esp32s3/include/esp_bt.h b/components/bt/include/esp32s3/include/esp_bt.h index 2172796eb5..7bc1f0b6e2 100644 --- a/components/bt/include/esp32s3/include/esp_bt.h +++ b/components/bt/include/esp32s3/include/esp_bt.h @@ -336,6 +336,8 @@ esp_err_t esp_bt_controller_init(esp_bt_controller_config_t *cfg); /** * @brief De-initialize BT controller to free resource and delete task. + * You should stop advertising and scanning, as well as + * disconnect all existing connections before de-initializing BT controller. * * This function should be called only once, after any other BT functions are called. * This function is not whole completed, esp_bt_controller_init cannot called after this function.