nRF5340 LE Audio Samsung Galaxy Buds2 Pro - Multiple Problems

Hello,

I using the Samsung Galaxy Buds2 Pro headphones to connect to the latest v2.4.0 nRF SDK. I am using the LE Audio demo code as gateway. The demo connects successfully out of the box to the headphones, with some modifications to the prj.conf file, using the nRF5340 Audio DK. For my project needs, I have both source and sink enabled via CONFIG_STREAM_BIDIRECTIONAL.

CONFIG_AUDIO_DEV=2

CONFIG_BT_DEVICE_NAME="Galaxy Buds2 Pro"
#QOS will fail without this
CONFIG_BT_AUDIO_PRESENTATION_DELAY_US=40000
#Seem to get failed to discover without this
CONFIG_BLE_ACL_CONN_INTERVAL=72
CONFIG_BT_AUDIO_MAX_TRANSPORT_LATENCY_MS=100
CONFIG_LOG_BUFFER_SIZE=8192
CONFIG_BT_AUDIO_RETRANSMITS=2
CONFIG_BT_BAP_UNICAST_CLIENT_ASE_SRC_COUNT=2

CONFIG_STREAM_BIDIRECTIONAL=y
CONFIG_WALKIE_TALKIE_DEMO=y

CONFIG_AUDIO_SOURCE_I2S=y
CONFIG_BT_BONDABLE=n

CONFIG_BT_VCP_VOL_CTLR=n

Problem #1 - Controller Crashes

If you connect to the right headset first, then connect to the left headset, the"ble5-ctr-rpmsg_3349" controller crashes. I believe this also happened on the 3330 controller as well.

The crash happens after calling bt_bap_stream_start on the Left SINK. This only happens if you connect to the right headset first, followed by the left.

Once the controller crashes, the next call to bt_hci_cmd_send_sync will fail on semaphore take "timeout with err -11". This usually happens either on the next le_audio_send stream send OR on the ble_core.c watchdog call to net_core_ctrl_version_get.

Log:

         nRF5340 Audio nRF5340 Audio DK cpuapp
         NCS base version: 2.4.0
         Cmake run : Tue Jun 13 05:32:12 2023
GW [00:00:00.258,209] <inf> fw_info: ------- DEBUG BUILD -------
GW [00:00:00.258,239] <inf> fw_info: Compiled for GATEWAY device
GW [00:00:00.268,859] <inf> board_version: Compatible board/HW version found: 1.0.0
GW [00:00:00.305,755] <wrn> bt_hci_core: Controller to host flow control not supported
GW [00:00:00.308,898] <inf> bt_hci_core: No ID address. App must call settings_load()
GW [00:00:00.308,959] <inf> ble: MAC: 00:00:00:00:00:00 (public)
GW [00:00:00.309,509] <inf> ble: Controller version: 3349
GW [00:00:00.312,500] <err> settings: set-value failure. key: bt/name error(-2)
GW [00:00:00.312,591] <inf> bt_hci_core: Identity: FD:60:E5:B4:2A:20 (random)
GW [00:00:00.312,622] <inf> bt_hci_core: HCI: version 5.2 (0x0b) revision 0x0d15, manufacturer 0x07e8
GW [00:00:00.312,622] <inf> bt_hci_core: LMP: version 5.2 (0x0b) subver 0x0d15
GW [00:00:00.430,725] <inf> cis_gateway: Scanning successfully started
GW [00:00:05.272,583] <inf> cis_gateway: Connected: 7F:3B:83:F5:3B:A8 (random)
GW [00:00:07.189,117] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:07.189,117] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:07.457,885] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:08.467,346] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:08.467,346] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005698
GW [00:00:08.468,078] <inf> cis_gateway: Scanning successfully started
GW [00:00:08.857,391] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:08.917,388] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:08.917,419] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:09.217,315] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:09.217,437] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:09.257,995] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:09.258,026] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:09.258,544] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:09.577,362] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:09.857,421] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:10.107,452] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:10.147,583] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:10.147,583] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:10.207,916] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:10.207,946] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:10.208,404] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:10.208,465] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:10.257,415] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:10.258,331] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:10.427,459] <err> cis_gateway: <<<<< stream_started_cb >>>>>
GW [00:00:10.427,459] <inf> cis_gateway: Stream 0x200021ac started
GW [00:00:10.453,308] <wrn> bt_hci_core: opcode 0x2061 status 0x0c
GW [00:00:10.921,203] <err> cis_gateway: <<<<< stream_started_cb >>>>>
GW [00:00:10.921,234] <inf> cis_gateway: Stream 0x200023cc started
GW [00:00:12.058,898] <inf> cis_gateway: Connected: 71:09:B2:4D:BC:12 (random)
GW [00:00:14.863,433] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:14.863,464] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:15.131,622] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:15.439,147] <wrn> audio_datapath: In I2S TX underrun condition, total: 5000
GW [00:00:16.901,458] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:16.901,458] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_LEFT 0x20005760
GW [00:00:16.901,458] <inf> cis_gateway: All headsets connected
GW [00:00:17.471,496] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:17.531,494] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:17.531,524] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:18.071,441] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:18.071,563] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:18.141,662] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:18.141,693] <inf> cis_gateway: LEFT sink stream configured
GW [00:00:18.151,611] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:18.651,519] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:19.131,591] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:19.551,605] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:19.641,693] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:19.641,723] <inf> cis_gateway: LEFT source stream configured
GW [00:00:19.751,586] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:19.751,617] <inf> cis_gateway: Enable stream 0x20001f0c
GW [00:00:19.761,718] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:19.761,779] <inf> cis_gateway: Enable stream 0x20001cec
GW [00:00:19.821,533] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:19.851,562] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:19.857,177] <wrn> audio_datapath: I2S RX overrun. Single msg
GW [00:00:19.942,169] <wrn> audio_datapath: I2S RX continuing stream
GW [00:00:19.962,158] <wrn> audio_datapath: I2S RX overrun. Single msg
GW [00:00:20.439,147] <wrn> audio_datapath: In I2S TX underrun condition, total: 10000
GW [00:00:25.439,147] <wrn> audio_datapath: In I2S TX underrun condition, total: 15000
ASSERTION FAIL [err == 0] @ WEST_TOPDIR/zephyr/subsys/bluetooth/host/hci_core.c:330
        command opcode 0x2061 timeout with err -11
GW [00:00:29.958,007] <err> os: r0/a1:  0x00000003  r1/a2:  0x00000002  r2/a3:  0x00000001
GW [00:00:29.958,038] <err> os: r3/a4:  0x0000014a r12/ip:  0x00407fd0 r14/lr:  0x00020c95
GW [00:00:29.958,038] <err> os:  xpsr:  0x41100000
GW [00:00:29.958,038] <err> os: s[ 0]:  0x00000000  s[ 1]:  0x0000001c  s[ 2]:  0x00000000  s[ 3]:  0x000000a2
GW [00:00:29.958,038] <err> os: s[ 4]:  0x00000010  s[ 5]:  0x0000001a  s[ 6]:  0x00000000  s[ 7]:  0x000000a2
GW [00:00:29.958,068] <err> os: s[ 8]:  0x00000000  s[ 9]:  0x000000a2  s[10]:  0x00000003  s[11]:  0x00000002
GW [00:00:29.958,068] <err> os: s[12]:  0x00000000  s[13]:  0x00000000  s[14]:  0x00000031  s[15]:  0x00000000
GW [00:00:29.958,068] <err> os: fpscr:  0x20000010
GW [00:00:29.958,099] <err> os: Faulting instruction address (r15/pc): 0x00020ca0
GW [00:00:29.958,099] <err> os: >>> ZEPHYR FATAL ERROR 3: Kernel oops on CPU 0
GW [00:00:29.958,129] <err> os: Current thread: 0x200018c0 (ENCODER)
GW [00:00:29.958,129] <err> error_handler: Caught system error -- reason 3. Entering infinite loop

Problem #2 - Connection constantly disconnects

There seems to be a possible timing issue when connecting a headset stream, then starting the scan / connection to the other headset.

After starting the left headset stream, when you start scanning / connecting to the right headset, the left headset drops connection. It happens as soon as the right headset starts scan / connection. I have noticed that if you start searching for the right headset later in time / further in the code connection sequence, this happens much less frequently. The ACL scan is originally in unicast_client_location_cb. If I move the ACL scan to discover_source_cb or stream_enabled_cb, the issue happens much less frequently. If this is time dependent, then this is also likely a problem because as we add code to the rest of the system, time could change again and cause the issue to come back.
         nRF5340 Audio nRF5340 Audio DK cpuapp
         NCS base version: 2.4.0
         Cmake run : Tue Jun 13 05:32:12 2023
GW [00:00:00.259,490] <inf> fw_info: ------- DEBUG BUILD -------
GW [00:00:00.259,521] <inf> fw_info: Compiled for GATEWAY device
GW [00:00:00.270,141] <inf> board_version: Compatible board/HW version found: 1.0.0
GW [00:00:00.307,037] <wrn> bt_hci_core: Controller to host flow control not supported
GW [00:00:00.310,150] <inf> bt_hci_core: No ID address. App must call settings_load()
GW [00:00:00.310,241] <inf> ble: MAC: 00:00:00:00:00:00 (public)
GW [00:00:00.310,791] <inf> ble: Controller version: 3349
GW [00:00:00.313,781] <err> settings: set-value failure. key: bt/name error(-2)
GW [00:00:00.313,873] <inf> bt_hci_core: Identity: FD:60:E5:B4:2A:20 (random)
GW [00:00:00.313,903] <inf> bt_hci_core: HCI: version 5.2 (0x0b) revision 0x0d15, manufacturer 0x07e8
GW [00:00:00.313,903] <inf> bt_hci_core: LMP: version 5.2 (0x0b) subver 0x0d15
GW [00:00:00.432,067] <inf> cis_gateway: Scanning successfully started
GW [00:00:00.517,395] <inf> cis_gateway: Connected: 60:20:E9:4A:5E:67 (random)
GW [00:00:02.330,261] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:02.330,291] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:02.599,548] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:03.478,485] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:03.478,485] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_LEFT 0x20005698
GW [00:00:03.479,217] <inf> cis_gateway: Scanning successfully started
GW [00:00:03.625,518] <inf> cis_gateway: Connected: 4B:D7:D6:29:40:2F (random)
GW [00:00:03.878,540] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:03.918,548] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:03.918,579] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:04.308,471] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:04.308,593] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:04.368,713] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:04.368,713] <inf> cis_gateway: LEFT sink stream configured
GW [00:00:04.369,262] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:04.718,963] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:05.078,552] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:05.378,601] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:05.419,189] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:05.419,189] <inf> cis_gateway: LEFT source stream configured
GW [00:00:05.489,044] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:05.489,105] <inf> cis_gateway: Enable stream 0x20001f0c
GW [00:00:05.489,593] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:05.489,654] <inf> cis_gateway: Enable stream 0x20001cec
GW [00:00:05.521,972] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:05.522,003] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:05.528,533] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:05.539,001] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:05.539,855] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:05.540,100] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:05.540,130] <inf> cis_gateway: Stream 0x20001f0c stopped. Reason 13
GW [00:00:05.540,130] <wrn> cis_gateway: Unknown stream
GW [00:00:05.540,130] <inf> cis_gateway: Stream 0x20001cec stopped. Reason 13
GW [00:00:05.790,588] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:06.039,703] <wrn> bt_conn: no transition connecting
GW [00:00:06.040,222] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:06.040,496] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:06.040,496] <inf> cis_gateway: Stream 0x20001f0c stopped. Reason 13
GW [00:00:06.040,496] <wrn> cis_gateway: Unknown stream
GW [00:00:06.040,527] <inf> cis_gateway: Stream 0x20001cec stopped. Reason 13
GW [00:00:06.502,532] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:06.502,532] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005760
GW [00:00:06.502,532] <inf> cis_gateway: All headsets connected
GW [00:00:06.872,558] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:06.912,567] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:06.912,597] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:07.292,510] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:07.292,633] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:07.313,171] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:07.313,201] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:07.313,751] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:07.662,567] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:08.012,603] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:08.272,644] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:08.313,201] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:08.313,232] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:08.372,619] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:08.372,680] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:08.373,138] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:08.373,199] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:08.442,596] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:08.443,511] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:10.444,152] <err> cis_gateway: Failed to establish CIS, ret = -16
GW [00:00:10.463,104] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:10.463,531] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:10.463,562] <inf> cis_gateway: Stream 0x200023cc stopped. Reason 13
GW [00:00:10.463,562] <wrn> cis_gateway: Unknown stream
GW [00:00:10.463,562] <inf> cis_gateway: Stream 0x200021ac stopped. Reason 13
GW [00:00:10.464,843] <wrn> cis_gateway: Unknown stream
GW [00:00:10.464,935] <inf> cis_gateway: Disconnected: 4B:D7:D6:29:40:2F (random) (reason 0x16)
GW [00:00:10.465,576] <inf> cis_gateway: Scanning successfully started
GW [00:00:10.861,907] <inf> cis_gateway: Connected: 44:EF:53:25:6B:96 (random)
GW [00:00:12.492,218] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:12.492,218] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:12.670,776] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:13.642,730] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:13.642,730] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005760
GW [00:00:13.642,730] <inf> cis_gateway: All headsets connected
GW [00:00:14.002,777] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:14.052,764] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:14.052,795] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:14.422,698] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:14.422,821] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:14.463,378] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:14.463,409] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:14.472,869] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:14.832,763] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:15.202,789] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:15.472,839] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:15.512,969] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:15.512,969] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:15.573,303] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:15.573,333] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:15.583,007] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:15.583,068] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:15.613,250] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:15.633,239] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:15.633,636] <wrn> bt_conn: no transition connecting
GW [00:00:17.633,911] <err> cis_gateway: Failed to establish CIS, ret = -16
GW [00:00:17.653,320] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:17.653,747] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:17.653,747] <inf> cis_gateway: Stream 0x200023cc stopped. Reason 13
GW [00:00:17.653,778] <wrn> cis_gateway: Unknown stream
GW [00:00:17.653,778] <inf> cis_gateway: Stream 0x200021ac stopped. Reason 13
GW [00:00:17.654,998] <wrn> cis_gateway: Unknown stream
GW [00:00:17.655,090] <inf> cis_gateway: Disconnected: 44:EF:53:25:6B:96 (random) (reason 0x16)
GW [00:00:17.655,731] <inf> cis_gateway: Scanning successfully started
GW [00:00:18.001,403] <inf> cis_gateway: Connected: 48:1A:C0:46:05:23 (random)
GW [00:00:19.722,412] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:19.722,412] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:19.901,489] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:20.742,919] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:20.742,919] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005760
GW [00:00:20.742,919] <inf> cis_gateway: All headsets connected
GW [00:00:21.082,977] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:21.132,965] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:21.132,995] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:21.482,910] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:21.483,001] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:21.513,580] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:21.513,580] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:21.514,739] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:21.872,955] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:22.162,994] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:22.413,024] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:22.453,155] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:22.453,155] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:22.513,031] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:22.513,061] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:22.513,519] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:22.513,580] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:22.552,978] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:22.563,446] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:22.563,812] <wrn> bt_conn: no transition connecting
GW [00:00:24.564,117] <err> cis_gateway: Failed to establish CIS, ret = -16
GW [00:00:24.573,516] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:24.573,944] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:24.573,944] <inf> cis_gateway: Stream 0x200023cc stopped. Reason 13
GW [00:00:24.573,944] <wrn> cis_gateway: Unknown stream
GW [00:00:24.573,974] <inf> cis_gateway: Stream 0x200021ac stopped. Reason 13
GW [00:00:24.575,195] <wrn> cis_gateway: Unknown stream
GW [00:00:24.575,286] <inf> cis_gateway: Disconnected: 48:1A:C0:46:05:23 (random) (reason 0x16)
GW [00:00:24.575,927] <inf> cis_gateway: Scanning successfully started
GW [00:00:25.193,725] <inf> cis_gateway: Connected: 7B:A7:91:0C:AE:5E (random)
GW [00:00:27.002,624] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:27.002,624] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:27.181,182] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:28.093,109] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:28.093,139] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005760
GW [00:00:28.093,139] <inf> cis_gateway: All headsets connected
GW [00:00:28.453,155] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:28.503,173] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:28.503,204] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:28.843,109] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:28.843,231] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:28.863,769] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:28.863,800] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:28.864,349] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:29.163,146] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:29.473,205] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:29.793,273] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:29.833,343] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:29.833,374] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:29.893,707] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:29.893,737] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:29.894,195] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:29.894,256] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:29.933,197] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:29.943,634] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:29.944,030] <wrn> bt_conn: no transition connecting
GW [00:00:31.944,305] <err> cis_gateway: Failed to establish CIS, ret = -16
GW [00:00:31.954,101] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:31.954,528] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:31.954,528] <inf> cis_gateway: Stream 0x200023cc stopped. Reason 13
GW [00:00:31.954,559] <wrn> cis_gateway: Unknown stream
GW [00:00:31.954,559] <inf> cis_gateway: Stream 0x200021ac stopped. Reason 13
GW [00:00:31.955,810] <wrn> cis_gateway: Unknown stream
GW [00:00:31.955,902] <inf> cis_gateway: Disconnected: 7B:A7:91:0C:AE:5E (random) (reason 0x16)
GW [00:00:31.956,542] <inf> cis_gateway: Scanning successfully started
GW [00:00:32.355,743] <inf> cis_gateway: Connected: 61:E7:90:D0:18:37 (random)
GW [00:00:33.892,791] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:33.892,822] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:34.071,380] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:35.243,316] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:35.243,347] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005760
GW [00:00:35.243,347] <inf> cis_gateway: All headsets connected
GW [00:00:35.583,374] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:35.623,382] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:35.623,413] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:35.933,319] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:35.933,410] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:35.973,968] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:35.973,999] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:35.983,489] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:36.313,354] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:36.603,393] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:36.863,433] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:36.903,564] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:36.903,564] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:36.953,887] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:36.953,948] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:36.963,592] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:36.963,653] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:36.993,835] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:37.023,376] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:37.023,773] <wrn> bt_conn: no transition connecting
GW [00:00:39.024,047] <err> cis_gateway: Failed to establish CIS, ret = -16
GW [00:00:39.033,905] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:39.034,332] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:39.034,362] <inf> cis_gateway: Stream 0x200023cc stopped. Reason 13
GW [00:00:39.034,362] <wrn> cis_gateway: Unknown stream
GW [00:00:39.034,362] <inf> cis_gateway: Stream 0x200021ac stopped. Reason 13
GW [00:00:39.035,583] <wrn> cis_gateway: Unknown stream
GW [00:00:39.035,705] <inf> cis_gateway: Disconnected: 61:E7:90:D0:18:37 (random) (reason 0x16)
GW [00:00:39.036,346] <inf> cis_gateway: Scanning successfully started
GW [00:00:39.435,546] <inf> cis_gateway: Connected: 58:44:76:E7:1F:C8 (random)
GW [00:00:41.153,015] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:41.153,015] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:41.421,569] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:42.353,515] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:42.353,546] <wrn> cis_gateway: BT_AUDIO_LOCATION_FRONT_RIGHT 0x20005760
GW [00:00:42.353,546] <inf> cis_gateway: All headsets connected
GW [00:00:42.703,552] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:42.743,560] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:42.743,591] <wrn> cis_gateway: More than one sink endpoints found, ep idx 0 is used by default
GW [00:00:43.113,494] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:43.113,616] <err> cis_gateway: <<<<< discover_source >>>>>
GW [00:00:43.163,726] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:43.163,757] <inf> cis_gateway: RIGHT sink stream configured
GW [00:00:43.164,276] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:43.473,541] <err> cis_gateway: <<<<< unicast_client_location_cb >>>>>
GW [00:00:43.763,610] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:44.023,651] <err> cis_gateway: <<<<< discover_source_cb >>>>>
GW [00:00:44.044,189] <err> cis_gateway: <<<<< stream_configured_cb >>>>>
GW [00:00:44.044,219] <inf> cis_gateway: RIGHT source stream configured
GW [00:00:44.064,086] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:44.064,147] <inf> cis_gateway: Enable stream 0x200023cc
GW [00:00:44.064,605] <err> cis_gateway: <<<<< stream_qos_set_cb >>>>>
GW [00:00:44.064,636] <inf> cis_gateway: Enable stream 0x200021ac
GW [00:00:44.074,127] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:44.084,045] <err> cis_gateway: <<<<< stream_enabled_cb >>>>>
GW [00:00:44.084,411] <wrn> bt_conn: no transition connecting
GW [00:00:46.084,686] <err> cis_gateway: Failed to establish CIS, ret = -16
GW [00:00:46.094,116] <wrn> bt_hci_core: opcode 0x206f status 0x0c
GW [00:00:46.094,543] <wrn> bt_hci_core: opcode 0x206f status 0x12
GW [00:00:46.094,543] <inf> cis_gateway: Stream 0x200023cc stopped. Reason 13
GW [00:00:46.094,543] <wrn> cis_gateway: Unknown stream
GW [00:00:46.094,573] <inf> cis_gateway: Stream 0x200021ac stopped. Reason 13
GW [00:00:46.095,794] <wrn> cis_gateway: Unknown stream
GW [00:00:46.095,886] <inf> cis_gateway: Disconnected: 58:44:76:E7:1F:C8 (random) (reason 0x16)
GW [00:00:46.096,527] <inf> cis_gateway: Scanning successfully started
GW [00:00:46.213,775] <inf> cis_gateway: Connected: 40:EB:E0:AD:11:02 (random)
GW [00:00:47.311,126] <wrn> cis_gateway: Unknown stream
GW [00:00:47.311,218] <inf> cis_gateway: Disconnected: 60:20:E9:4A:5E:67 (random) (reason 0x13)
GW [00:00:47.311,889] <inf> cis_gateway: Scanning successfully started
GW [00:00:47.763,641] <err> cis_gateway: <<<<< security_changed_cb >>>>>
GW [00:00:47.763,641] <err> cis_gateway: <<<<< discover_sink >>>>>
GW [00:00:47.843,658] <err> cis_gateway: <<<<< discover_sink_cb >>>>>
GW [00:00:47.843,658] <err> cis_gateway: Discovery failed: 14
GW [00:00:47.843,811] <inf> cis_gateway: Disconnected: 40:EB:E0:AD:11:02 (random) (reason 0x13)
GW [00:00:47.843,811] <wrn> cis_gateway: Connection not found
GW [00:00:47.843,841] <wrn> cis_gateway: Unknown connection
GW [00:00:47.843,841] <inf> cis_gateway: Scanning successfully started

Problem #3 - Source audio not always acquired

The next issue that I have seen is if you connect to the headset successfully, the first time the connection is made, the source (headset microphone) audio will play on the headphone jack every time. The issue comes when you put the headset back in the case and close the lid, then re-open and take the headset out. The next successful connection will have a 50% chance of the microphone audio playing on the headphone jack. This 50% chance of source audio working happens every time you put the headphones back in the case and take them out again. 

One note: I have also tested this on a non-audio DK, with the source audio being fed back into the headset sink. For this reason, I don't think the issue has to do with the I2S or HW codec etc.

Lastly, it looks like the audio in data is still being received since the callback for Rx data is still being called.

I have attached an example project. It is the LE audio demo code with minor modifications. Search for <Modified> in the code to see what I modified. The modifications were only made in prj.conf and le_audio_cis_gateway.c

nrf2_4_0_AudioDemo.zip

Parents
  • Hello again,

    We have not yet performed any tests with the Galaxy buds pro 2 since the nRF Connect SDK v2.4 release, but we will schedule some next week to take a closer look at the issues you have reported here. In the meantime, I have a few suggestions you could try on your own, along with some additional questions.

    The demo connects successfully out of the box to the headphones, with some modifications to the prj.conf file, using the nRF5340 Audio DK. For my project needs, I have both source and sink enabled via CONFIG_STREAM_BIDIRECTIONAL.

    We have not yet tested using bidirectional streams with the galaxy buds pro 2 before. Does everything work as expected when you run the same test without the CONFIG_STREAM_BIDIRECTIONAL set?

    Regarding Problem #1:
    This behavior was indeed a known issue with the 3330 controller, but it was resolved before the v3349 release, so this is a very interesting report.
    I will need to discuss this some more with the team, and we will test this specifically next week.

    Regarding Problem #2:
    When we tested with the Galaxy buds pro 2 before we found that we had to make these modifications to our gateway device to have the most stable connection to the Galaxy buds pro 2:
    - The presentation delay must be set to 40 ms
    - The ACL connection interval should be 45 ms
    - The maximum number of retransmissions we should use is 2
    - There should be a small delay between the establishment of the two CISs

    Please make sure that you are using these configuration in your test, and see if that improves the stability of the connection.

    Regarding Problem #3:
    During our last round of testing with the Galaxy Buds Pro 2 we saw that there was some issue with the bonding to the earbuds, which perhaps could be related to what you are seeing here.
    Is the ACL to the earbuds terminated when they are put in the case?
    You mention that it works 50% of the time, could you elaborate on the behavior on the other 50% of the time when it is not working?
    It would also be great if you could capture a sniffer trace of these two scenarios (just of the link establishments, not of the ISO parts), so that I could check if there any indication of what goes wrong when it does.

    Again I would like to thank you for the detailed report, and I will keep you updated on any news from our own testing of the Galaxy Buds Pro 2 next week :) 

    Best regards,
    Karl

  • One other note on Problem #1.

    I saw a strange behavior on the right headset when connecting first. If you connect to the right headset, you can configure sink and then source, then ONLY start the right source and both the sink + source audio works. This behavior is not true for the left headset, configuring sink will enable sink audio, likewise for source.

Reply Children
No Data
Related