Skip to main content
Associate II
November 17, 2025
Question

HAP Central start stream fail

  • November 17, 2025
  • 5 replies
  • 582 views

Use example code BLE_Audio_HAP_Central to audio function. The Central may start the stream fail, though the BLE connect and GAP link returns are OK. and Once the stream start failed, the stream cannot be start forever, with the result "CAP Unicast Start Procedure is Complete with status 0x91".  Compared with the normal process the GAP link lack of CAP event 0x06, 0x12. 

I have to use aci_gap_clear_security_db()  then I can connect and start the stream successfully. And what's more, use aci_gap_remove_bonded_device() to remove the certain device and repairing cannot start the stream. It seems that there's some memory issues. 

 

log for stream start failed

[10:10:48.442]·¢¡ú¡ó{A\0v³\0ÿÿ}¡õ
[10:10:48.445]ÊÕ¡û¡ôaci_gap_terminate_gap_proc() returns status 0x00
HAPAPP_StopScanning() returns status 0x00
Selected device 0
aci_gap_create_connection() returns status 0x00
{A\0w³\0V˜}P_PROC_COMPLETE_VSEVT_CODE
>>== ACI_GAP_PROC_COMPLETE_VSEVT_CODE
>>== HCI_LE_ENHANCED_CONNECTION_COMPLETE_SUBEVT_CODE - Connection handle: 0x0001
 - Connection established with @:a4:90:ce:1e:a9:87
 - Connection Interval: 40.00 ms
 - Connection latency: 0
 - Supervision Timeout: 10000 ms
>>== device is already bonded
aci_gap_send_pairing_req returns 0
 Success: aci_gap_adv_set_enable stop

[10:10:48.726]ÊÕ¡û¡ô>>== ACI_GAP_PAIRING_COMPLETE_VSEVT_CODE
 - Pairing Success

Pairing Complete with connection handle 0x0001
GAF Profiles Mask 0x0A present in NVM
profiles 0x00 of the GAF are already linked on ConnHandle 0x0001
CAP_Linkup() for GAF restoration on ConnHandle 0x0001 for link mask 0x0A returns status 0x00

[10:10:48.848]ÊÕ¡û¡ôMTU = 247
 Success: aci_gatt_update_char_value BLOCKSIZE command
CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x0A
CAP Unicast Linkup Event with status 0x00

[10:10:48.968]ÊÕ¡û¡ôCAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098

[10:10:49.127]ÊÕ¡û¡ôCAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x9B001E
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0004

[10:10:49.567]ÊÕ¡û¡ôCAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x28001E
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098

[10:10:49.727]ÊÕ¡û¡ôCAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2

[10:10:50.446]ÊÕ¡û¡ôCAP Event : 0x39
Volume Control Profile is linked on ConnHandle 0x0001
CAP Event : 0x00
CAP Linkup Complete on Connhandle 0x0001 with status 0x00
Complete HAP Linkup on ConnHandle 0x0001 is started with status 0x00

[10:10:52.127]ÊÕ¡û¡ôHAP Linkup Complete Event with ConnHandle 0x0001 is received with status 0x00
HAP_HARC_ReadPresetsRequest() returns status 0x92

[10:10:54.362]·¢¡ú¡ó{A\0vµ\0ÿÿ}¡õ
[10:10:54.366]ÊÕ¡û¡ôStart Telephony Stream
Start Telephony Stream
Set Start Stream for CAP Acceptor 0 on connHandle 0x0001 :
Sink Codec Conf :
 Audio Channel Allocation : 0x00000003
 Channel Per CIS : 1
 Sampling Freq : 0x03
Source Codec Conf :
 Audio Channel Allocation : 0x00000003
 Channel Per CIS : 1
 Sampling Freq : 0x03
CAP_Unicast_AudioStart() of 1 CAP Accceptors in Set Type 0x00 returns status 0x00
{A\0wµÄT}
[10:10:59.485]ÊÕ¡û¡ôCAP Event : 0x0B
CAP Unicast Start Procedure is Complete with status 0x91

 

5 replies

ST Employee
November 18, 2025

Hello Huang,

 

Could you explain your setup and the sequence used on the central from the first stream, including reset and/or disconnection ? Additionally could you share full logs from the beginning ?

 

Best regards,

HuangFanAuthor
Associate II
November 19, 2025

Hi,

the full log:

==>> Start Ble_Hci_Gap_Gatt_Init function
 Success: aci_hal_write_config_data command - CONFIG_DATA_PUBADDR_OFFSET
 Public Bluetooth Address: 00:12:56:5d:48:cd
 Success: aci_hal_write_config_data command - CONFIG_DATA_IR_OFFSET
 Success: aci_hal_write_config_data command - CONFIG_DATA_ER_OFFSET
 Success: aci_hal_set_tx_power_level command
 Success: aci_gatt_init command
 Success: aci_gap_init command
 Success: aci_gatt_update_char_value - Device Name
 Success: aci_gatt_update_char_value - Appearance
 Success: hci_le_set_default_phy command
 Success: aci_gap_set_io_capability command
 hci_le_set_event_mask, result: 0x00
 hci_le_read_local_p256_public_key, result: 0x00
 Success: aci_gap_set_authentication_requirement command
 Success: aci_gap_configure_whitelist command
==>> End Ble_Hci_Gap_Gatt_Init function
Number of advertising sets supported : 8
Advertising data length max : 1650
 Success: aci_gap_adv_set_configuration_v2
 Success: aci_gap_adv_set_adv_data
 Success: aci_gap_adv_set_scan_resp_data

Services and Characteristics creation
 Success: aci_gatt_add_service command: Batt 
 Success: aci_gatt_add_char command : BAT
 Success: aci_gatt_add_service command: DataTrans 
 Success: aci_gatt_add_char command : APPRX
 Success: aci_gatt_add_char command : APPTX
 Success: aci_gatt_add_service command: DIS 
 Success: aci_gatt_add_char command : MANS
 Success: aci_gatt_add_char command : MONS
 Success: aci_gatt_add_char command : SNS
 Success: aci_gatt_add_char command : FRS
 Success: aci_gatt_add_char command : HRS
 Success: aci_gatt_add_char command : BUILDDATETIME
 Success: aci_gatt_add_char command : SRS
 Success: aci_gatt_add_char command : SYID
 Success: aci_gatt_add_char command : PNI
 Success: aci_gatt_update_char_value MANS command
 Success: aci_gatt_update_char_value MONS command
 Success: aci_gatt_update_char_value SNS command
 Success: aci_gatt_update_char_value FRS command
 Success: aci_gatt_update_char_value HRS command
 Success: aci_gatt_update_char_value BUILDDATETIME command
 Success: aci_gatt_update_char_value SRS command
 Success: aci_gatt_update_char_value SYID command
 Success: aci_gatt_update_char_value PNI command
 Success: aci_gatt_add_service command: OADSer 
 Success: aci_gatt_add_char command : IMAGEIDENTIFY
 Success: aci_gatt_add_char command : IMAGEBLOCK
 Success: aci_gatt_add_char command : BLOCKSIZE
 Success: aci_gatt_add_char command : IMAGESTATUS
 Success: aci_gatt_add_char command : FW_VER
 Success: aci_gatt_update_char_value BLOCKSIZE command
 Success: aci_gatt_update_char_value FW_VER command
End of Services and Characteristics creation

CAPAPP_Init()
BLE_AUDIO_STACK_Init() returns status 0x00
BLE Audio Stack Lib version: v1.5_FULL_Official
CAP_Init() returns status 0x00
Generic Telephony Bearer CCID 0 successfully registered
Enable Audio Codec in LE Controller status 0x00
CAPAPP_Init() returns status 0x00
HAPAPP_HAPInit() with role 0x0E returns status 0x00
/*
above are the init process for BLE stack and Audio init
below are processes for scan, connect, CAP link, Telephone stream start
*/
[08:45:22.171]·¢¡ú¡ó{A\0vQÿÿ}¡õ
[08:45:22.174]ÊÕ¡û¡ô{A\0wQÛ5}aci_gap_ext_start_scan() returns status 0x00//start scanning
HAPAPP_StartScanning() returns status 0x00
HAPAPP_StartScanning() returns status 0x00
vivo tws 3: a4:90:ce:1e:a9:87

[08:45:25.890]·¢¡ú¡ó{A\0v³\0ÿÿ}¡õ
[08:45:25.896]ÊÕ¡û¡ôaci_gap_terminate_gap_proc() returns status 0x00
HAPAPP_StopScanning() returns status 0x00//stop scanning
Selected device 0
aci_gap_create_connection() returns status 0x00 // create connection 
{A\0w³\0V˜} ACI_GAP_PROC_COMPLETE_VSEVT_CODE

[08:45:25.930]ÊÕ¡û¡ô>>== ACI_GAP_PROC_COMPLETE_VSEVT_CODE
>>== HCI_LE_ENHANCED_CONNECTION_COMPLETE_SUBEVT_CODE - Connection handle: 0x0001
 - Connection established with @:a4:90:ce:1e:a9:87
 - Connection Interval: 40.00 ms
 - Connection latency: 0
 - Supervision Timeout: 10000 ms
>>== device is already bonded
aci_gap_send_pairing_req returns 0 //start pairing
 Success: aci_gap_adv_set_enable stop

[08:45:26.344]ÊÕ¡û¡ô>>== ACI_GAP_PAIRING_COMPLETE_VSEVT_CODE // pairing done
 - Pairing Success

Pairing Complete with connection handle 0x0001
GAF Profiles Mask 0x0A present in NVM // start CAP link
profiles 0x00 of the GAF are already linked on ConnHandle 0x0001
CAP_Linkup() for GAF restoration on ConnHandle 0x0001 for link mask 0x0A returns status 0x00

[08:45:26.504]ÊÕ¡û¡ôMTU = 247
 Success: aci_gatt_update_char_value BLOCKSIZE command
MTU = 247
 Success: aci_gatt_update_char_value BLOCKSIZE command
CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x0A
CAP Unicast Linkup Event with status 0x00

[08:45:26.625]ÊÕ¡û¡ôCAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098

[08:45:26.744]ÊÕ¡û¡ôCAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x9B001E
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0004

[08:45:27.104]ÊÕ¡û¡ôCAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x28001E
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098

[08:45:27.264]ÊÕ¡û¡ôCAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2

[08:45:27.904]ÊÕ¡û¡ôCAP Event : 0x39
Volume Control Profile is linked on ConnHandle 0x0001
CAP Event : 0x00
CAP Linkup Complete on Connhandle 0x0001 with status 0x00
Complete HAP Linkup on ConnHandle 0x0001 is started with status 0x00

[08:45:29.382]ÊÕ¡û¡ôHAP Linkup Complete Event with ConnHandle 0x0001 is received with status 0x00
HAP_HARC_ReadPresetsRequest() returns status 0x92

[08:45:33.386]·¢¡ú¡ó{A\0vµ\0ÿÿ}¡õ
[08:45:33.390]ÊÕ¡û¡ôStart Telephony Stream // start Telephony Stream
Start Telephony Stream
Set Start Stream for CAP Acceptor 0 on connHandle 0x0001 :
Sink Codec Conf :
 Audio Channel Allocation : 0x00000003
 Channel Per CIS : 1
 Sampling Freq : 0x03
Source Codec Conf :
 Audio Channel Allocation : 0x00000003
 Channel Per CIS : 1
 Sampling Freq : 0x03
CAP_Unicast_AudioStart() of 1 CAP Accceptors in Set Type 0x00 returns status 0x00
{A\0wµÄT}
[08:45:38.502]ÊÕ¡û¡ôCAP Event : 0x0B // 5 senconds later, receive the fail message 
CAP Unicast Start Procedure is Complete with status 0x91
HuangFanAuthor
Associate II
November 19, 2025

after clear DB and repairing, then start stream successfully.

[09:05:01.792]收←◆==>> Start Ble_Hci_Gap_Gatt_Init function
 Success: aci_hal_write_config_data command - CONFIG_DATA_PUBADDR_OFFSET
 Public Bluetooth Address: 00:12:56:5d:48:cd
 Success: aci_hal_write_config_data command - CONFIG_DATA_IR_OFFSET
 Success: aci_hal_write_config_data command - CONFIG_DATA_ER_OFFSET
 Success: aci_hal_set_tx_power_level command
 Success: aci_gatt_init command
 Success: aci_gap_init command
 Success: aci_gatt_update_char_value - Device Name
 Success: aci_gatt_update_char_value - Appearance
 Success: hci_le_set_default_phy command
 Success: aci_gap_set_io_capability command
 hci_le_set_event_mask, result: 0x00
 hci_le_read_local_p256_public_key, result: 0x00
 Success: aci_gap_set_authentication_requirement command
 Success: aci_gap_configure_whitelist command
==>> End Ble_Hci_Gap_Gatt_Init function
Number of advertising sets supported : 8
Advertising data length max : 1650
 Success: aci_gap_adv_set_configuration_v2
 Success: aci_gap_adv_set_adv_data
 Success: aci_gap_adv_set_scan_resp_data

Services and Characteristics creation
 Success: aci_gatt_add_service command: Batt 
 Success: aci_gatt_add_char command : BAT
 Success: aci_gatt_add_service command: DataTrans 
 Success: aci_gatt_add_char command : APPRX
 Success: aci_gatt_add_char command : APPTX
 Success: aci_gatt_add_service command: DIS 
 Success: aci_gatt_add_char command : MANS
 Success: aci_gatt_add_char command : MONS
 Success: aci_gatt_add_char command : SNS
 Success: aci_gatt_add_char command : FRS
 Success: aci_gatt_add_char command : HRS
 Success: aci_gatt_add_char command : BUILDDATETIME
 Success: aci_gatt_add_char command : SRS
 Success: aci_gatt_add_char command : SYID
 Success: aci_gatt_add_char command : PNI
 Success: aci_gatt_update_char_value MANS command
 Success: aci_gatt_update_char_value MONS command
 Success: aci_gatt_update_char_value SNS command
 Success: aci_gatt_update_char_value FRS command
 Success: aci_gatt_update_char_value HRS command
 Success: aci_gatt_update_char_value BUILDDATETIME command
 Success: aci_gatt_update_char_value SRS command
 Success: aci_gatt_update_char_value SYID command
 Success: aci_gatt_update_char_value PNI command
 Success: aci_gatt_add_service command: OADSer 
 Success: aci_gatt_add_char command : IMAGEIDENTIFY
 Success: aci_gatt_add_char command : IMAGEBLOCK
 Success: aci_gatt_add_char command : BLOCKSIZE
 Success: aci_gatt_add_char command : IMAGESTATUS
 Success: aci_gatt_add_char command : FW_VER
 Success: aci_gatt_update_char_value BLOCKSIZE command
 Success: aci_gatt_update_char_value FW_VER command
End of Services and Characteristics creation

CAPAPP_Init()
BLE_AUDIO_STACK_Init() returns status 0x00
BLE Audio Stack Lib version: v1.5_FULL_Official
CAP_Init() returns status 0x00
Generic Telephony Bearer CCID 0 successfully registered
Enable Audio Codec in LE Controller status 0x00
CAPAPP_Init() returns status 0x00
HAPAPP_HAPInit() with role 0x0E returns status 0x00

[09:05:04.010]发→◇{A\0vQ}□
[09:05:04.013]收←◆{A\0wQ?}aci_gap_ext_start_scan() returns status 0x00
HAPAPP_StartScanning() returns status 0x00
HAPAPP_StartScanning() returns status 0x00
vivo tws 3: a4:90:ce:1e:a9:87

[09:05:05.858]发→◇{A\0v?\0}□
[09:05:05.861]收←◆aci_gap_terminate_gap_proc() returns status 0x00
HAPAPP_StopScanning() returns status 0x00
Selected device 0
aci_gap_create_connection() returns status 0x00
{A\0w?\0V榼 ACI_GAP_PROC_COMPLETE_VSEVT_CODE

[09:05:05.958]收←◆>>== ACI_GAP_PROC_COMPLETE_VSEVT_CODE
>>== HCI_LE_ENHANCED_CONNECTION_COMPLETE_SUBEVT_CODE - Connection handle: 0x0001
 - Connection established with @:a4:90:ce:1e:a9:87
 - Connection Interval: 40.00 ms
 - Connection latency: 0
 - Supervision Timeout: 10000 ms
>>== device is already bonded
aci_gap_send_pairing_req returns 0
 Success: aci_gap_adv_set_enable stop

[09:05:06.359]收←◆>>== ACI_GAP_PAIRING_COMPLETE_VSEVT_CODE
 - Pairing Success

Pairing Complete with connection handle 0x0001
GAF Profiles Mask 0x0A present in NVM
profiles 0x00 of the GAF are already linked on ConnHandle 0x0001
CAP_Linkup() for GAF restoration on ConnHandle 0x0001 for link mask 0x0A returns status 0x00

[09:05:06.480]收←◆MTU = 247
 Success: aci_gatt_update_char_value BLOCKSIZE command
MTU = 247
 Success: aci_gatt_update_char_value BLOCKSIZE command
CAP Event : 0x0A
CAP Unicast Linkup Event with status 0x00

[09:05:06.600]收←◆CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098

[09:05:06.721]收←◆CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x9B001E
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0004

[09:05:06.842]收←◆CAP Event : 0x06
CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

[09:05:06.879]收←◆CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

[09:05:07.041]收←◆CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x28001E
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098

[09:05:07.161]收←◆CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2

[09:05:07.840]收←◆CAP Event : 0x39
Volume Control Profile is linked on ConnHandle 0x0001
CAP Event : 0x00
CAP Linkup Complete on Connhandle 0x0001 with status 0x00
Complete HAP Linkup on ConnHandle 0x0001 is started with status 0x00

[09:05:09.279]收←◆HAP Linkup Complete Event with ConnHandle 0x0001 is received with status 0x00
HAP_HARC_ReadPresetsRequest() returns status 0x92

[09:05:12.954]发→◇{A\0v?\0}□
[09:05:12.956]收←◆Start Telephony Stream
Start Telephony Stream
Set Start Stream for CAP Acceptor 0 on connHandle 0x0001 :
Sink Codec Conf :
 Audio Channel Allocation : 0x00000003
 Channel Per CIS : 1
 Sampling Freq : 0x03
Source Codec Conf :
 Audio Channel Allocation : 0x00000003
 Channel Per CIS : 1
 Sampling Freq : 0x03
CAP_Unicast_AudioStart() of 1 CAP Accceptors in Set Type 0x00 returns status 0x00
{A\0w?腡}
[09:05:13.080]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01

[09:05:13.200]收←◆CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01

[09:05:13.320]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01

[09:05:13.440]收←◆CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01
>>== ISOCHRONOUS_GROUP_EVENT
 - Opcode: 0x2062
 - CIG ID: 0 - cis_conn_handle: 0x0009
 - CIG ID: 0 - cis_conn_handle: 0x000A

[09:05:13.561]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x02
CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x02
CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x02
CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x02

[09:05:13.722]收←◆CAP Event : 0x06
CAP Event : 0x06
CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x03
CAP Event : 0x01
Init Audio Clock with freq 3
Audio Clock Initialization
RCC AS is now properly initialized
CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x03
CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x03
CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x03

[09:05:14.289]收←◆>>== ISOCHRONOUS_GROUP_EVENT
 - Opcode: 0x0019
 - cis_conn_handle: 0x0009 - iso_interval: 8
==>> AUDIO_RegisterGroup()
CAP Event : 0x0E
Setup Output Audio Data Path is requested for ASE ID 5 on ACL Conn Handle 0x0001 (CIS Conn Handle 0x0009)
 Codec ID
 Coding format : 0x06
 Company id : 0x0000
 VS codec id : 0x0000
 Presentation Delay 40000 us
 Min Controller Delay 2813 us
 Max Controller Delay 230000 us
Setup Audio Peripheral for Sink Role at Sampling frequency 3
Audio Channels Allocation Configuration : 0x00000001
Number of Audio Channels 1 
Configure Audio Periphal drivers at Sampling frequency 3
Register callback to Start Audio Peripheral Tx
==>> CODEC Configure Data Path with following parameters:
 Direction : 1
 Data Path ID : 0x01
 Sample Depth : 16
 Decimation : 2
==>> CODEC_ConfigureDataPath() : Success
==>> CODEC Setup ISO Data Path for CIS Connection Handle 0x0009
==>> CODEC_SetupIsoDataPath() : Success
CAP Event : 0x0F
Number of Output Channels Up: 1
Output Audio Data Path is up with status 0x00 for CIS Conn handle 0x0009
Controller Delay : 22000 us
Transport Latency : 4290 us
Setup Unicast Audio Data Path for ASE ID 5 on CIS connection handle 0x0009 with controller delay at 22000 us returns status 0x00
Audio Data Path is complete with remaining Application delay for audio process to respect : 100us
CAP Event : 0x01
Init Audio Clock with freq 3
Audio Clock already configured
>>== HCI_LE_CIS_ESTABLISHED_SUBEVT_CODE - CIS Connection handle: 0x0009 - Status 0x00

[09:05:14.560]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x04

[09:05:15.101]收←◆>>== ISOCHRONOUS_GROUP_EVENT
 - Opcode: 0x0019
 - cis_conn_handle: 0x000A - iso_interval: 8
==>> AUDIO_RegisterGroup()
CAP Event : 0x0E
Setup Output Audio Data Path is requested for ASE ID 6 on ACL Conn Handle 0x0001 (CIS Conn Handle 0x000A)
 Codec ID
 Coding format : 0x06
 Company id : 0x0000
 VS codec id : 0x0000
 Presentation Delay 40000 us
 Min Controller Delay 2813 us
 Max Controller Delay 230000 us
Setup Audio Peripheral for Sink Role at Sampling frequency 3
Audio Channels Allocation Configuration : 0x00000002
Number of Audio Channels 1 
==>> CODEC Configure Data Path with following parameters:
 Direction : 1
 Data Path ID : 0x01
 Sample Depth : 16
 Decimation : 2
==>> CODEC_ConfigureDataPath() : Success
==>> CODEC Setup ISO Data Path for CIS Connection Handle 0x000A
==>> CODEC_SetupIsoDataPath() : Success
CAP Event : 0x0F
Number of Output Channels Up: 2
Output Audio Data Path is up with status 0x00 for CIS Conn handle 0x000A
Controller Delay : 22000 us
Transport Latency : 4290 us
Setup Unicast Audio Data Path for ASE ID 6 on CIS connection handle 0x000A with controller delay at 22000 us returns status 0x00
Audio Data Path is complete with remaining Application delay for audio process to respect : 100us
>>== HCI_LE_CIS_ESTABLISHED_SUBEVT_CODE - CIS Connection handle: 0x000A - Status 0x00

[09:05:15.440]收←◆CAP Event : 0x0E
Setup Input Audio Data Path is requested for ASE ID 1 on ACL Conn Handle 0x0001 (CIS Conn Handle 0x0009)
 Codec ID
 Coding format : 0x06
 Company id : 0x0000
 VS codec id : 0x0000
 Presentation Delay 40000 us
 Min Controller Delay 5329 us
 Max Controller Delay 230000 us
Setup Audio Peripheral for Source Role at Sampling frequency 3
Audio Channels Allocation Configuration : 0x00000001
Number of Audio Channels 1 
Register callback to Start Audio Peripheral Rx
==>> CODEC Configure Data Path with following parameters:
 Direction : 0
 Data Path ID : 0x01
 Sample Depth : 16
 Decimation : 1
==>> CODEC_ConfigureDataPath() : Success
==>> CODEC Setup ISO Data Path for CIS Connection Handle 0x0009
==>> CODEC_SetupIsoDataPath() : Success
CAP Event : 0x0F
Input Audio Data Path is up with status 0x00 for CIS Conn handle 0x0009
Controller Delay : 22000 us
Transport Latency : 4290 us
Setup Unicast Audio Data Path for ASE ID 1 on CIS connection handle 0x0009 with controller delay at 22000 us returns status 0x00
Audio Data Path is complete with remaining Application delay for audio process to respect : 100us
CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x04
START AUDIO SOURCE (input)
START AUDIO SINK (output)
CAP Event : 0x0E
Setup Input Audio Data Path is requested for ASE ID 2 on ACL Conn Handle 0x0001 (CIS Conn Handle 0x000A)
 Codec ID
 Coding format : 0x06
 Company id : 0x0000
 VS codec id : 0x0000
 Presentation Delay 40000 us
 Min Controller Delay 5329 us
 Max Controller Delay 230000 us
Setup Audio Peripheral for Source Role at Sampling frequency 3
Audio Channels Allocation Configuration : 0x00000002
Number of Audio Channels 1 
==>> CODEC Configure Data Path with following parameters:
 Direction : 0
 Data Path ID : 0x01
 Sample Depth : 16
 Decimation : 1
==>> CODEC_ConfigureDataPath() : Success
==>> CODEC Setup ISO Data Path for CIS Connection Handle 0x000A
==>> CODEC_SetupIsoDataPath() : Success
CAP Event : 0x0F
Input Audio Data Path is up with status 0x00 for CIS Conn handle 0x000A
Controller Delay : 22000 us
Transport Latency : 4290 us
Setup Unicast Audio Data Path for ASE ID 2 on CIS connection handle 0x000A with controller delay at 22000 us returns status 0x00
Audio Data Path is complete with remaining Application delay for audio process to respect : 100us
CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x04

[09:05:15.679]收←◆CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x04
CAP Event : 0x0B
CAP Unicast Start Procedure is Complete with status 0x00

 

ST Employee
November 19, 2025

Hello,

 

Thank you for your reply. 

I see from the log you are based on STM32CubeWBA version 1.5.0 (and probably STM32WBA5).

Please, retry with the last release (currently 1.8.0 available on st.com) and tell us if you still see the issue. 

Additionally, the scenario is important for us to understand the issue. 

 

Best regards,

HuangFanAuthor
Associate II
November 20, 2025

I tested the example BLE_Audio_HAP_Central in 1.8.0 on STM32WBA55G-DK1 board, the the steam start failed, the log as:

[11:32:15.198]收←◆
SNVMA_Init - Corrupted banks erases [IsHeaderOk]==>> Start Ble_Hci_Gap_Gatt_Init function
 Success: aci_hal_write_config_data command - CONFIG_DATA_PUBADDR_OFFSET
 Public Bluetooth Address: 00:80:e1:2a:c2:21
 Success: aci_hal_write_config_data command - CONFIG_DATA_IR_OFFSET
 Success: aci_hal_write_config_data command - CONFIG_DATA_ER_OFFSET
 Success: aci_hal_set_tx_power_level command
 Success: aci_gatt_init command
 Success: aci_gap_init command
 Success: aci_gatt_update_char_value - Device Name
 Success: aci_gatt_update_char_value - Appearance
 Success: hci_le_set_default_phy command
 Success: aci_gap_set_io_capability command
 Success: aci_gap_set_authentication_requirement command
 Success: aci_gap_configure_whitelist command
==>> End Ble_Hci_Gap_Gatt_Init function
BLE_AUDIO_STACK_Init() returns status 0x00
BLE Audio Stack Lib version: v1.13_FULL_Official
CAPAPP_Init()
CAP_Init() returns status 0x00
Generic Telephony Bearer CCID 0 successfully registered
Enable Audio Codec in LE Controller status 0x00
CAPAPP_Init() returns status 0x00
HAPAPP_HAPInit() with role 0x0E returns status 0x00

[11:32:16.768]收←◆[APP_MENU_CONF] Startup timer expired, Display home

[11:32:26.824]收←◆[APP_MENU_CONF] Start Scanning
aci_gap_ext_start_scan() returns status 0x00
HAPAPP_StartScanning() returns status 0x00

[11:32:29.721]收←◆Unknown: a4:90:ce:1e:a9:87

[11:32:30.026]收←◆Unknown: a4:90:ce:1e:a9:87

[11:32:30.243]收←◆Unknown: a4:90:ce:1e:a9:87

[11:32:30.457]收←◆Unknown: a4:90:ce:1e:a9:87

[11:32:30.556]收←◆Unknown: a4:90:ce:1e:a9:87

[11:32:30.782]收←◆Unknown: a4:90:ce:1e:a9:87

[11:32:31.208]收←◆[APP_MENU_CONF] Selected device 0
aci_gap_ext_create_connection() returns status 0x00

[11:32:31.293]收←◆>>== HCI_LE_ENHANCED_CONNECTION_COMPLETE_SUBEVT_CODE - Connection handle: 0x0001
 - Connection established with @:a4:90:ce:1e:a9:87
 - Connection Interval: 30.00 ms
 - Connection latency: 0
 - Supervision Timeout: 10000 ms
>>== device is already bonded
==>> aci_gap_send_pairing_req : Success

[11:32:31.332]收←◆>>== ACI_GAP_PROC_COMPLETE_VSEVT_CODE

[11:32:31.494]收←◆>>== ACI_GAP_PAIRING_COMPLETE_VSEVT_CODE
 - Pairing Success

Pairing Complete with connection handle 0x0001
GAF Profiles Mask 0x0A present in NVM
profiles 0x00 of the GAF are already linked on ConnHandle 0x0001
CAP_Linkup() for GAF restoration on ConnHandle 0x0001 for link mask 0x0A returns status 0x00

[11:32:31.557]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01
CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01
CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00
CAP Event : 0x0A
CAP Unicast Linkup Event with status 0x00

[11:32:31.617]收←◆CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 min: 75, max 100
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098
CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 min: 40, max 80
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2
CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x9B001E
 min: 30, max 155
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0004

[11:32:31.856]收←◆CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x28001E
 min: 30, max 40
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098
CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 min: 75, max 100
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D0
CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 min: 40, max 80
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2
>>== HCI_LE_PHY_UPDATE_COMPLETE_SUBEVT_CODE - ACL Connection handle: 0x0001 - Status 0x00
>>== RX_PHY : 0x02 - TX_PHY : 0x02

[11:32:32.215]收←◆CAP Event : 0x3A
Volume Control Profile is linked on ConnHandle 0x0001
CAP Event : 0x00
CAP Linkup Complete on Connhandle 0x0001 with status 0x00
Complete HAP Linkup on ConnHandle 0x0001 is started with status 0x00

[11:32:32.935]收←◆HAP Linkup Complete Event with ConnHandle 0x0001 is received with status 0x00
HAP_HARC_ReadPresetsRequest() returns status 0x92

[11:32:34.985]收←◆[APP_MENU_CONF] Start Telephony Stream
Start Telephony Stream
Set Start Stream for CAP Acceptor 0 on connHandle 0x0001 :
Sink Codec Conf :
 Audio Channel Allocation : 0x00000000
 Channel Per CIS : 1
 Sampling Freq : 0x03
Source Codec Conf :
 Audio Channel Allocation : 0x00000000
 Channel Per CIS : 1
 Sampling Freq : 0x03
>>== ISOCHRONOUS_GROUP_EVENT
 - Opcode: 0x2062
 - CIG ID: 0 - cis_conn_handle: 0x0009
CAP_Unicast_AudioStart() of 1 CAP Acceptors in Set Type 0x00 returns status 0x00

[11:32:40.045]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

 

HuangFanAuthor
Associate II
November 20, 2025

if start steam failed, Clear DB, then it will be OK, the log as:

[13:42:36.495]收←◆
SNVMA_Init - Corrupted banks erases [IsHeaderOk]==>> Start Ble_Hci_Gap_Gatt_Init function
 Success: aci_hal_write_config_data command - CONFIG_DATA_PUBADDR_OFFSET
 Public Bluetooth Address: 00:80:e1:2a:c2:21
 Success: aci_hal_write_config_data command - CONFIG_DATA_IR_OFFSET
 Success: aci_hal_write_config_data command - CONFIG_DATA_ER_OFFSET
 Success: aci_hal_set_tx_power_level command
 Success: aci_gatt_init command
 Success: aci_gap_init command
 Success: aci_gatt_update_char_value - Device Name
 Success: aci_gatt_update_char_value - Appearance
 Success: hci_le_set_default_phy command
 Success: aci_gap_set_io_capability command
 Success: aci_gap_set_authentication_requirement command
 Success: aci_gap_configure_whitelist command
==>> End Ble_Hci_Gap_Gatt_Init function
BLE_AUDIO_STACK_Init() returns status 0x00
BLE Audio Stack Lib version: v1.13_FULL_Official
CAPAPP_Init()
CAP_Init() returns status 0x00
Generic Telephony Bearer CCID 0 successfully registered
Enable Audio Codec in LE Controller status 0x00
CAPAPP_Init() returns status 0x00
HAPAPP_HAPInit() with role 0x0E returns status 0x00

[13:42:38.065]收←◆[APP_MENU_CONF] Startup timer expired, Display home

[13:42:40.272]收←◆[APP_MENU_CONF] Clear Security DB
SNVMA_Write() for AUDIO NVM Buffer returns status 0x00

[13:42:50.737]收←◆[APP_MENU_CONF] Start Scanning
aci_gap_ext_start_scan() returns status 0x00
HAPAPP_StartScanning() returns status 0x00
Unknown: a4:90:ce:1e:a9:87
Redmi Buds 5 Pro: 48:73:cb:e7:df:0e

[13:42:50.823]收←◆Unknown: 48:73:cb:64:08:e1

[13:42:51.040]收←◆Redmi Buds 5 Pro: 48:73:cb:e7:df:0e
Unknown: 48:73:cb:64:08:e1
Unknown: a4:90:ce:1e:a9:87

[13:42:51.273]收←◆Unknown: 48:73:cb:64:08:e1
Redmi Buds 5 Pro: 48:73:cb:e7:df:0e

[13:42:51.446]收←◆Unknown: 48:73:cb:64:08:e1
Redmi Buds 5 Pro: 48:73:cb:e7:df:0e

[13:42:51.558]收←◆Unknown: 48:73:cb:64:08:e1

[13:42:51.606]收←◆Unknown: a4:90:ce:1e:a9:87
Redmi Buds 5 Pro: 48:73:cb:e7:df:0e

[13:42:51.733]收←◆Unknown: 48:73:cb:64:08:e1
[APP_MENU_CONF] Selected device 0
aci_gap_ext_create_connection() returns status 0x00
>>== HCI_LE_ENHANCED_CONNECTION_COMPLETE_SUBEVT_CODE - Connection handle: 0x0001
 - Connection established with @:a4:90:ce:1e:a9:87
 - Connection Interval: 30.00 ms
 - Connection latency: 0
 - Supervision Timeout: 10000 ms
>>== device is not bonded
==>> aci_gap_send_pairing_req : Success

[13:42:51.795]收←◆>>== ACI_GAP_PROC_COMPLETE_VSEVT_CODE

[13:42:52.884]收←◆>>== HCI_LE_PHY_UPDATE_COMPLETE_SUBEVT_CODE - ACL Connection handle: 0x0001 - Status 0x00
>>== RX_PHY : 0x02 - TX_PHY : 0x02

[13:42:52.943]收←◆>>== ACI_GAP_PAIRING_COMPLETE_VSEVT_CODE
 - Pairing Success

Pairing Complete with connection handle 0x0001
GAF Profiles Mask 0x00 present in NVM
profiles 0x00 of the GAF are already linked on ConnHandle 0x0001
CAP_Linkup() on ConnHandle 0x0001 for link mask 0x1B returns status 0x00
>>== HCI_LE_PHY_UPDATE_COMPLETE_SUBEVT_CODE - ACL Connection handle: 0x0001 - Status 0x00
>>== RX_PHY : 0x02 - TX_PHY : 0x02

[13:42:53.930]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

[13:42:53.991]收←◆CAP Event : 0x12
ASE ID 2 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

[13:42:54.051]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

[13:42:54.111]收←◆CAP Event : 0x12
ASE ID 6 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x00

[13:42:54.713]收←◆SNVMA_Write() for AUDIO NVM Buffer returns status 0x00

[13:42:55.342]收←◆CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 min: 75, max 100
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098
CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 min: 40, max 80
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2
CAP Event : 0x02
Sink PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x9B001E
 min: 30, max 155
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0004

[13:42:55.671]收←◆CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 7.5 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x28001E
 min: 30, max 40
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x0098
CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 48 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x64004B
 min: 75, max 100
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D0
CAP Event : 0x03
Source PAC Record from CAP Acceptor on ConnHandle 0x0001
Remote Record: 
 Supported Sample Freq: 
 16 kHz
 24 kHz
 32 kHz
 Supported Frame Duration: 
 7.5 ms
 10 ms
 Preferred 10 ms
 Supported Channel Counts: 
 1 Channel
 Supported Octets Per Codec Frame: 0x500028
 min: 40, max 80
 Supported Max Codec Frame Per SDU: 2
 Supported Preferred Audio Contexts: 0x00D2

[13:42:57.531]收←◆CAP Event : 0x0A
CAP Unicast Linkup Event with status 0x00

[13:42:58.372]收←◆SNVMA_Write() for AUDIO NVM Buffer returns status 0x00

[13:42:58.581]收←◆CAP Event : 0x3A
Volume Control Profile is linked on ConnHandle 0x0001

[13:42:58.942]收←◆CAP Event : 0x00
CAP Linkup Complete on Connhandle 0x0001 with status 0x00
Complete HAP Linkup on ConnHandle 0x0001 is started with status 0x00

[13:42:59.662]收←◆HAP Linkup Complete Event with ConnHandle 0x0001 is received with status 0x00
HAP_HARC_ReadPresetsRequest() returns status 0x92

[13:43:02.643]收←◆[APP_MENU_CONF] Start Telephony Stream
Start Telephony Stream
Set Start Stream for CAP Acceptor 0 on connHandle 0x0001 :
Sink Codec Conf :
 Audio Channel Allocation : 0x00000000
 Channel Per CIS : 1
 Sampling Freq : 0x03
Source Codec Conf :
 Audio Channel Allocation : 0x00000000
 Channel Per CIS : 1
 Sampling Freq : 0x03
CAP_Unicast_AudioStart() of 1 CAP Acceptors in Set Type 0x00 returns status 0x00

[13:43:02.693]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01

[13:43:02.752]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x01
>>== ISOCHRONOUS_GROUP_EVENT
 - Opcode: 0x2062
 - CIG ID: 0 - cis_conn_handle: 0x0009

[13:43:02.813]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x02
CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x02

[13:43:02.903]收←◆CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x03
CAP Event : 0x01
Init Audio Clock with freq 3
Audio Clock Initialization
RCC AS is now properly initialized

[13:43:03.063]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x03

[13:43:03.267]收←◆>>== ISOCHRONOUS_GROUP_EVENT
 - Opcode: 0x0019
 - cis_conn_handle: 0x0009 - iso_interval: 8
==>> AUDIO_RegisterGroup()
CAP Event : 0x0E
Setup Output Audio Data Path is requested for ASE ID 5 on ACL Conn Handle 0x0001 (CIS Conn Handle 0x0009)
 Codec ID
 Coding format : 0x06
 Company id : 0x0000
 VS codec id : 0x0000
 Presentation Delay 40000 us
 Min Controller Delay 2712 us
 Max Controller Delay 110000 us
Setup Audio Peripheral for Sink Role at Sampling frequency 3
Configure Audio Periphal drivers at Sampling frequency 3
Register callback to Start Audio Peripheral Tx
==>> CODEC Configure Data Path with following parameters:
 Direction : 1
 Data Path ID : 0x01
==>> CODEC_ConfigureDataPath() : Success
==>> CODEC Setup ISO Data Path for CIS Connection Handle 0x0009
==>> CODEC_SetupIsoDataPath() : Success
CAP Event : 0x0F
Number of Output Channels Up: 0
Output Audio Data Path is up with status 0x00 for CIS Conn handle 0x0009
Controller Delay : 20000 us
Transport Latency : 2070 us
Setup Unicast Audio Data Path for ASE ID 5 on CIS connection handle 0x0009 with controller delay at 20000 us returns status 0x00
Audio Data Path is complete with remaining Application delay for audio process to respect : 10us
>>== HCI_LE_CIS_ESTABLISHED_SUBEVT_CODE - CIS Connection handle: 0x0009 - Status 0x00
CIG_Sync_Delay: 2070 us, CIS_Sync_Delay: 2070 us
Transport_Latency_C_To_P: 2070 us, Transport_Latency_P_To_C: 2070 us
PHY_C_To_P: 0x02, PHY_P_To_C: 0x02
BN_C_To_P: 0x01, BN_P_To_C: 0x01
FT_C_To_P: 0x01, FT_P_To_C: 0x01
Max_PDU_C_To_P: 0x0028, Max_PDU_P_To_C: 0x0028
NSE: 0x03, ISO_Interval: 0x0008
CAP Event : 0x0E
Setup Input Audio Data Path is requested for ASE ID 1 on ACL Conn Handle 0x0001 (CIS Conn Handle 0x0009)
 Codec ID
 Coding format : 0x06
 Company id : 0x0000
 VS codec id : 0x0000
 Presentation Delay 40000 us
 Min Controller Delay 4607 us
 Max Controller Delay 110000 us
Setup Audio Peripheral for Source Role at Sampling frequency 3
Register callback to Start Audio Peripheral Rx
==>> CODEC Configure Data Path with following parameters:
 Direction : 0
 Data Path ID : 0x01
==>> CODEC_ConfigureDataPath() : Success
==>> CODEC Setup ISO Data Path for CIS Connection Handle 0x0009
==>> CODEC_SetupIsoDataPath() : Success
CAP Event : 0x0F
Input Audio Data Path is up with status 0x00 for CIS Conn handle 0x0009
Controller Delay : 20000 us
Transport Latency : 2070 us
Setup Unicast Audio Data Path for ASE ID 1 on CIS connection handle 0x0009 with controller delay at 20000 us returns status 0x00
Audio Data Path is complete with remaining Application delay for audio process to respect : 10us
CAP Event : 0x12
ASE ID 1 [Type 0x00 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x04
START AUDIO SOURCE (input)

[13:43:03.617]收←◆START AUDIO SINK (output)

[13:43:03.681]收←◆CAP Event : 0x12
ASE ID 5 [Type 0x01 ] with remote CAP Acceptor on ConnHandle 0x0001 is in State 0x04
CAP Event : 0x0B
CAP Unicast Start Procedure is Complete with status 0x00

 

ST Employee
November 20, 2025

Hi, 

 

Thank you for the logs. It seems ASEs states are not aligned between Central and Peripheral.

-Which peripheral are you testing against ?

-Does the peripheral supports GATT Caching ?

-Could you confirm you did not reset the central during the entire scenario ?

-Are you able to do an air trace ? we would like to check the behavior of the peripheral regarding  the ASCS specification

"If the characteristic value for a bonded client changes when not in a connection and the value of the
Client Characteristic Configuration descriptor is configured for notifications, the server shall notify the new
characteristic value when reconnecting to the bonded client."

 

Here is few workaround proposal to be tested :

-force aci_gap_clear_security_db() (as you did with the joystick)

-use CAP_Linkup() with CompleteLinkMode set to 1

 

BR

HuangFanAuthor
Associate II
November 21, 2025

Hi,

The peripheral I'm testing is a TWS headset, vivo tws 3 pro, BLE5.3.

I'm not sure if it supports GATT Caching. what's the impact?

In the entire test scenario, I may reset the central with the reset button unconsciously and not clear the chip. I'm sure that after the first connection and start the stream successfully, I can reset the central or Peripheral then connection and start the stream successfully. After a disconnection for a while, 1~5 minutes perhaps, the stream may start fail. In this moment, the only way is to use ClearDB which will clear all bonded data. It's a rude operation and cannot be accepted.

Even I used to mention that I use aci_gap_get_bonded_devices()/ aci_gap_remove_bonded_device() to remove the Peripheral separately cannot solve this issue. why?

I will try to do the air trace and update the trace, but I'm not sure if the capture tools support this.

Also I will try to use CAP_Linkup() with CompleteLinkMode set to 1 and update the result.

ST Employee
November 21, 2025

Hi,

 

Both host stack and audio stack are storing information in NVM. They can be cleared respectively with  aci_gap_clear_security_db() and BLE_AUDIO_STACK_DB_ClearAllRecords().

But we have to understand if the ASE state misalignment could be the cause 

An air trace could help a lot, please note the connection is encrypted so you can use debug key (https://community.st.com/t5/stm32-mcus-wireless/how-to-get-ltk-long-term-key/m-p/821768)

 

BR,

 

ST Employee
November 27, 2025

Hello Huang Fan,

 

Thank you for the capture,

 

According to the air sniff traces, we can observe that the issue is due to a dealignments between the GATT databases of the two devices.


The first dealignment is related to the config descriptor of the GATT characteristics of the Audio services. The HAP Central has kept in memory that 'notification' is enabled for the Audio ATT characteristics from the first CAP linkup, but it is not done at the peripheral side. Consequently, when the HAP Central, during the streaming start procedure of the second connection, expects to receive a notification from the peripheral after a ASE Control operation, it never receives a feedback from the peripheral.

 

The Core specification says  "The Client Characteristic Configuration descriptor value shall be persistent across
connections for bonded devices." (Core Spec  - Vol 3 Part G 3.3.3.3), so the peripheral does not have the correct behavior. 

 

The second dealignment is related to the initial state of the Audio Stream Endpoint when the HAP Central starts the Stream Audio Start procedure : The HAP Central restores the ASE State during the CAP Linkup restoration in CODEC CONFIGURED State while the ASEs in Peripheral side are in IDLE State. 
Consequently, when the Audio Stream Start Procedure, the HAP Central performs a QoS Config operation with the ASEs but this operation is not permitted with ASE in IDLE State.

The change/reset of peripheral ASEs to Idle state should have been notified to the Central as well. 

 

It seems the peripheral does not store any data related to CAP linkup. Ensure your device has the last software version since VIVO may propose some updates.

 

Note the proposed workaround to use CAP_Linkup() with CompleteLinkMode will bypass this peripheral issue.

 

Best regards,

HuangFanAuthor
Associate II
November 28, 2025

Hi,

Thanks for the  explanation of the issue.

It seems the peripheral not response the ASE operation as you mentioned. Though I can use CAP_Linkup() with Complete LinkMode, but the complete link will take more than 8 seconds very time which could be a disastrous user experience, while within 2 seconds for none complete link.  

I wonder that there must be other ways to link up with the headset. For I've used the headset with my phone and computer for more than half years, no issue happens. It's a pity that I cannot decrypt the air trace.  

ST Employee
December 1, 2025

Hello,

 

The application is provided for demonstration and can be adapted to your needs. 

You can speed up the linkup by changing the connection interval from 30ms to 7.5ms (see HAPAPP_CreateConnection()).  

Still I would recommend to do a connection update (hci_le_connection_update()) at the end of the linkup to set a longer interval such 30 or 60ms for saving power consumption and having an ACL interval compatible with the ISO interval (7.5ms or 10ms for HAP audio configs)

 

Best regards,