Bluetooth Commonο
Exampleο
The target-specific HCI-over-UART controller examples have been replaced by a single example, bluetooth/hci/controller_hci_uart, which supports all targets that provide HCI over UART:
Removed example
Targets it used to cover
examples/bluetooth/hci/controller_hci_uart_esp32ESP32
examples/bluetooth/hci/controller_hci_uart_esp32c3_and_esp32s3ESP32-C3, ESP32-S3
examples/bluetooth/nimble/hciESP32-C2, ESP32-C5, ESP32-C6, ESP32-C61, ESP32-H2, ESP32-H21, ESP32-H4, ESP32-S31
Each removed directory keeps only a
README.mdthat points to the new example. Select the target withidf.py set-target <target>. The HCI UART pins, baud rate, and hardware flow control settings default to the values used by the removed examples, so no rewiring is required.The unified example relies on the Bluetooth controller to provide the HCI UART transport. Applications derived from the removed examples must therefore be updated accordingly:
The HCI UART pins are now routed by the controller instead of the application. The new option makes
esp_bt_controller_init()enable the HCI UART and UHCI bus clocks and apply , , and, when is enabled, and .Applications derived from
controller_hci_uart_esp32previously enabled these clocks and configured the UART pins themselves usinguart_ll_enable_bus_clock(),uhci_ll_enable_bus_clock(), anduart_set_pin()before callingesp_bt_controller_init(). Remove this code and enable instead. If the application needs to manage the HCI UART itself, keep the option disabled. When the option is enabled, the controller overrides any HCI UART pins configured by the application.