zephyr/samples/bluetooth/hci_spi
Joakim Andersson 81614307e9 Bluetooth: Add workaround for no command buffer available
Add workaround for no command buffer available when the host is
transmitting Host Number of Completed Packet Commands.
This command does not follow normal flow control of HCI commands and
the controller side HCI drivers that allocates HCI command buffers with
K_NO_WAIT can end up running out of command buffers.

Increase the command buffer count from 2 to 10 for the affected drivers
until the issue has a proper fix.

Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
2021-08-16 15:12:22 -04:00
..
boards
src
CMakeLists.txt
README.rst
prj.conf Bluetooth: Add workaround for no command buffer available 2021-08-16 15:12:22 -04:00
sample.yaml

README.rst

.. _bluetooth-hci-spi-sample:

Bluetooth: HCI SPI
##################

Overview
********

Expose Zephyr Bluetooth Controller support over SPI to another device/CPU using
the Zephyr SPI HCI transport protocol (similar to BlueNRG).

Requirements
************

A board with SPI slave, GPIO and Bluetooth Low Energy support.

Building and Running
********************

You then need to ensure that your :ref:`devicetree <dt-guide>` defines a node
for the HCI SPI slave device with compatible
:dtcompatible:`zephyr,bt-hci-spi-slave`. This node sets an interrupt line to
the host and associates the application with a SPI bus to use.

See :zephyr_file:`boards/nrf51dk_nrf51422.overlay
<samples/bluetooth/hci_spi/boards/nrf51dk_nrf51422.overlay>` in this sample
directory for an example overlay for the :ref:`nrf51dk_nrf51422` board.

You can then build this application and flash it onto your board in
the usual way; see :ref:`boards` for board-specific building and
flashing information.

You will also need a separate chip acting as BT HCI SPI master. This
application is compatible with the HCI SPI master driver provided by
Zephyr's Bluetooth HCI driver core; see the help associated with the
:kconfig:`CONFIG_BT_SPI` configuration option for more information.

Refer to :ref:`bluetooth-samples` for general Bluetooth information, and
to :ref:`96b_carbon_nrf51_bluetooth` for instructions specific to the
96Boards Carbon board.