Lines Matching +full:hci +full:- +full:uart
1 .. zephyr:code-sample:: bluetooth_hci_uart
2 :name: HCI UART
3 :relevant-api: hci_raw bluetooth uart_interface
5 Expose a Bluetooth controller to another device or CPU over UART.
10 Expose Bluetooth controller support over UART to another device/CPU
11 using the H:4 HCI transport protocol (requires HW flow control from the UART).
18 Default UART settings
39 provide a modern Bluetooth LE 5.0 controller to a Linux-based machine for native
40 BLE support or QEMU-based development.
52 .. zephyr-app-commands::
53 :zephyr-app: samples/bluetooth/hci_uart
57 .. _bluetooth-hci-uart-qemu-posix:
62 In order to use the HCI UART controller with QEMU or :ref:`native_sim <native_sim>` you will need
64 connect the UART to the Linux machine, and then attach it with this command:
66 .. code-block:: console
68 sudo btattach -B /dev/ttyACM0 -S 1000000 -R
80 The ``-R`` flag passed to ``btattach`` instructs the kernel to avoid
90 .. _bluetooth-hci-uart-bluez:
95 In order to use the HCI UART controller with BlueZ you will need to attach it
97 UART to the Linux machine, and then attach it with this command:
99 .. code-block:: console
101 sudo btattach -B /dev/ttyACM0 -S 1000000
121 The sample can be debugged using RTT since the UART is otherwise used by this
124 .. code-block:: console
126 west build samples/bluetooth/hci_uart -- -DEXTRA_CONF_FILE='debug.conf'
128 Then attach RTT as described here: :ref:`Using Segger J-Link <Using Segger J-Link>`
137 .. code-block:: console
139 west build samples/bluetooth/hci_uart -b nrf52833dk/nrf52833@df -- -DCONFIG_BT_CTLR_DF=y
146 Check the :zephyr:code-sample:`ble_direction_finding_connectionless_rx` and the
147 :zephyr:code-sample:`ble_direction_finding_connectionless_tx` for more details.
149 Using a USB CDC ACM UART
152 The sample can be configured to use a USB UART instead. See :zephyr_file:`samples/bluetooth/hci_uar…
160 On the controller side, the ``zephyr,bt-c2h-uart`` DTS property (in the ``chosen``
161 block) is used to select which uart device to use. For example if we want to
162 keep the console logs, we can keep console on uart0 and the HCI on uart1 like
165 .. code-block:: dts
170 zephyr,shell-uart = &uart0;
171 zephyr,bt-c2h-uart = &uart1;
176 driver instead of the built-in controller:
178 .. code-block:: cfg
183 Similarly, the ``zephyr,bt-hci`` DTS property selects which HCI instance to use.
184 The UART needs to have as its child node a HCI UART node:
186 .. code-block:: dts
191 zephyr,shell-uart = &uart0;
192 zephyr,bt-hci = &bt_hci_uart;
199 compatible = "zephyr,bt-hci-uart";