component/bt: modify the init/deinit function
This commit is contained in:
parent
c7dac035ae
commit
667ac172df
1 changed files with 3 additions and 0 deletions
|
@ -16,6 +16,7 @@
|
|||
#include "btc_main.h"
|
||||
#include "future.h"
|
||||
#include "esp_err.h"
|
||||
#include "btif_config.h"
|
||||
|
||||
static future_t *main_future[BTC_MAIN_FUTURE_NUM];
|
||||
|
||||
|
@ -60,6 +61,7 @@ void btc_init_callback(void)
|
|||
|
||||
static void btc_init_bluetooth(void)
|
||||
{
|
||||
btif_config_init();
|
||||
bte_main_boot_entry(btc_init_callback);
|
||||
}
|
||||
|
||||
|
@ -67,6 +69,7 @@ static void btc_init_bluetooth(void)
|
|||
static void btc_deinit_bluetooth(void)
|
||||
{
|
||||
bte_main_shutdown();
|
||||
btif_config_clean_up();
|
||||
future_ready(*btc_main_get_future_p(BTC_MAIN_DEINIT_FUTURE), FUTURE_SUCCESS);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue