|
| 1 | +.. zephyr:code-sample:: bluetooth_cap_handover |
| 2 | + :name: Common Audio Profile (CAP) Handover |
| 3 | + :relevant-api: bluetooth bt_bap bt_cap bt_conn |
| 4 | + |
| 5 | + Connects to a CAP acceptor and performs CAP handover procedures |
| 6 | + |
| 7 | +Overview |
| 8 | +******** |
| 9 | + |
| 10 | +Application demonstrating the CAP handover functionality. |
| 11 | +Starts by scanning for a CAP Acceptor then sets up unicast audio, and then switches between unicast |
| 12 | +and broadcast using the CAP handover procedures. |
| 13 | + |
| 14 | +This sample can be found under :zephyr_file:`samples/bluetooth/cap_handover` in the Zephyr tree. |
| 15 | + |
| 16 | +Check the :zephyr:code-sample-category:`bluetooth` samples for general information. |
| 17 | + |
| 18 | +Requirements |
| 19 | +************ |
| 20 | + |
| 21 | +* BlueZ running on the host, or |
| 22 | +* A board with Bluetooth Low Energy 5.2 support |
| 23 | + |
| 24 | +Building and Running |
| 25 | +******************** |
| 26 | + |
| 27 | +When building targeting an nrf52 series board with the Zephyr Bluetooth Controller, |
| 28 | +use ``-DEXTRA_CONF_FILE=overlay-bt_ll_sw_split.conf`` to enable the required ISO |
| 29 | +feature support. |
| 30 | + |
| 31 | +Building for an nrf5340dk |
| 32 | +------------------------- |
| 33 | + |
| 34 | +You can build both the application core image and an appropriate controller image for the network |
| 35 | +core with: |
| 36 | + |
| 37 | +.. zephyr-app-commands:: |
| 38 | + :zephyr-app: samples/bluetooth/cap_handover/ |
| 39 | + :board: nrf5340dk/nrf5340/cpuapp |
| 40 | + :goals: build |
| 41 | + :west-args: --sysbuild |
| 42 | + |
| 43 | +If you prefer to only build the application core image, you can do so by doing instead: |
| 44 | + |
| 45 | +.. zephyr-app-commands:: |
| 46 | + :zephyr-app: samples/bluetooth/cap_handover/ |
| 47 | + :board: nrf5340dk/nrf5340/cpuapp |
| 48 | + :goals: build |
| 49 | + |
| 50 | +In that case you can pair this application core image with the |
| 51 | +:zephyr:code-sample:`bluetooth_hci_ipc` sample |
| 52 | +:zephyr_file:`samples/bluetooth/hci_ipc/nrf5340_cpunet_iso-bt_ll_sw_split.conf` configuration. |
| 53 | + |
| 54 | +Building for a simulated nrf5340bsim |
| 55 | +------------------------------------ |
| 56 | + |
| 57 | +Similarly to how you would for real HW, you can do: |
| 58 | + |
| 59 | +.. zephyr-app-commands:: |
| 60 | + :zephyr-app: samples/bluetooth/cap_handover/ |
| 61 | + :board: nrf5340bsim/nrf5340/cpuapp |
| 62 | + :goals: build |
| 63 | + :west-args: --sysbuild |
| 64 | + |
| 65 | +Note this will produce a Linux executable in :file:`./build/zephyr/zephyr.exe`. |
| 66 | +For more information, check :ref:`this board documentation <nrf5340bsim>`. |
| 67 | + |
| 68 | +Building for a simulated nrf52_bsim |
| 69 | +----------------------------------- |
| 70 | + |
| 71 | +.. zephyr-app-commands:: |
| 72 | + :zephyr-app: samples/bluetooth/cap_handover/ |
| 73 | + :board: nrf52_bsim |
| 74 | + :goals: build |
| 75 | + :gen-args: -DEXTRA_CONF_FILE=overlay-bt_ll_sw_split.conf |
0 commit comments