Skip to main content

esp_bt_controller_enable

Function esp_bt_controller_enable 

Source
pub unsafe extern "C" fn esp_bt_controller_enable(mode: u32) -> i32
Expand description

@brief Enable Bluetooth Controller

@note 1. Bluetooth Controller cannot be enabled in ESP_BT_CONTROLLER_STATUS_IDLE status. It has to be initialized first. 2. Due to a known issue, you cannot call esp_bt_controller_enable() for the second time to change the Controller mode dynamically. To change the Controller mode, call esp_bt_controller_disable() and then call esp_bt_controller_enable() with the new mode.

@param[in] mode The Bluetooth Controller mode to enable

For API compatibility, retain this argument. This mode must match the mode specified in the cfg of esp_bt_controller_init().

@return - ESP_OK: Success - ESP_ERR_INVALID_STATE: Invalid Bluetooth Controller state - ESP_ERR_INVALID_ARG: Invalid arguments