xref: /btstack/test/le_audio/README.md (revision ced70f9bfeafe291ec597a3a9cc862e39e0da3ce)
1These samples are meant to be used with the [PTS Dongel](https://bluekitchen-gmbh.com/bluetooth-pts-with-nordic-nrf52840-usb-dongle/) or an equivalent setup like
2the one described in here using a nrf5340dk.
3
4# nrf5340dk as HCI dongle
5for this a working [Zephyr](https://www.zephyrproject.org/) build environment is required, where the setup of Zephyr is beyond the scope of this document.
6
7The nrf5340 is a dual core SOC for which the network core handles the low level radio control and the application core handles the actual application.
8So to make a working dongle the network core and the application core need to be programmed.
9
10### network core / Packetcraft LL
11for nrf5340 the latest netcore firmware is located at [sdk-nrf](https://github.com/nrfconnect/sdk-nrf/tree/main/lib/bin/bt_ll_acs_nrf53/bin)
12to program it:
13```sh
14nrfjprog --program ble5-ctr-rpmsg_<version number>.hex --chiperase --coprocessor CP_NETWORK -r
15```
16
17### application core
18the `hci_uart` sample is used here over USB CDC
19build using:
20```sh
21west build -b nrf5340dk_nrf5340_cpuapp -- -DDTC_OVERLAY_FILE=usb.overlay -DOVERLAY_CONFIG=overlay-usb.conf
22```
23with `usb.overlay` specifying to use USB CDC instead of a physical UART
24```c
25/*
26 * Copyright (c) 2021 Nordic Semiconductor ASA
27 *
28 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
29 */
30
31/ {
32	chosen {
33		zephyr,bt-c2h-uart = &cdc_acm_uart0;
34	};
35};
36
37&zephyr_udc0 {
38	cdc_acm_uart0: cdc_acm_uart0 {
39		compatible = "zephyr,cdc-acm-uart";
40	};
41};
42```
43and `overlay-usb.conf` to enable USB
44```make
45CONFIG_USB_DEVICE_STACK=y
46CONFIG_USB_DEVICE_PRODUCT="Zephyr HCI UART sample"
47CONFIG_USB_CDC_ACM=y
48CONFIG_USB_DEVICE_INITIALIZE_AT_BOOT=n
49```
50