This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC2564B A3DP settings

Other Parts Discussed in Thread: CC2564

Hi

I am trying assisted mode A2DP (A3DP) and it looks like all vendor commands are executed successfully and the sequence too seems to be as per the requirement but when a song is played from remote device the SBC packets are still routed to host stack rather then decoded on the BT controller 

Can some one tell if they have come across this issue and how to resolve this.

Strangely one is 20-25 attempts the packet are played at controller but it is all noise and it is very discontinuous.

seq is : AVPR enable sink mode during stack init. After receiving a2dp connect indication issue 1) open sink stream on a2dp  2) configure PCM and A3DP codec settings on a2dp start indication 3) call start sink stream 

Thanks 

regards

Nitin

  • Hi Nitin,

    Please share the logger logs so I can see the command exchange.
    Also, which is the host MCU and SDK/service pack release versions?

    Regards,
    Gigi Joseph.
  • HI Joseph,
    I am using 3rd party BT-BLE stack and the platform is proprietary using CC2564B interfaced to host over UART for HCI link
    base service back from below link 4.0 and service pack add on is from : (processors.wiki.ti.com/.../CC256x_Downloads CC2564B AVPR Add-On )

    git.ti.com/.../TIInit_6.7.16_avpr_add-on.bts

    Following is the HCI log while making connection and playing audio from connected phone: Hope it gives some insight to the issue.

    when the data is decoded from BT controller it is producing all noise but most of the time the data is sent to host stack.
    I tried with MTU size 990 but it is still same.

    =====================================
    : : Received AVDTP_CONNECT_IND
    : AVDTP Handle:
    : ADDR: F7:EF:A9:01:44:2C
    : Result = 0x0
    : btAudioRendInitA2dpSinkParams calling
    : vs_enableA2DP called ... @ [enable AVPR here::]
    : vs_HCI_VS_LE_Enable called [disable BLE in AVPR]... : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD92 -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD92 -> UNKNOWN
    : Command Status: 0x00
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD5B -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD5B -> UNKNOWN
    : Command Status: 0x0C
    : : Received A2DP_CONFIGURE_IND
    : Codec Instance = 0
    : Event Result = 0x0
    : Event Data = 0x900a772b, Data Length = 4
    : Code Type: SBC
    : SBC Codec IE = 0x21 0x15 0x02 0x35
    : -> Sampling Frequency = 44100
    : -> Channel Mode = Joint Stereo (2)
    : -> Block Length = 16
    : -> Subbands = 8
    : -> Allocation Method = Loudness
    : -> Bitpool = 2, 53
    : : Received A2DP_CONNECT_IND
    : Codec Instance = 0
    : Event Result = 0x0
    : calling vs_assistedA3DPopen to open a3dp stream
    : A2DP Media Channel Params ... : Media Channel params:
    : Media Channel ID: 65
    : Configured MTU: 1021
    : vs_HCI_VS_A3DP_Sink_Open_Stream called ... @
    : btAudioRendInitA2dpSinkCodecParams calling
    : btAudioRendI2SCodecInit samplerate = 44100 bitspersample = 16
    : I2S_Get_Clock 12000000
    : vs_HCI_VS_Write_CODEC_Config_a3dp called ... @
    : vs_HCI_VS_Write_CODEC_Config_Enhanced called ... @
    : vs_HCI_VS_A3DP_Sink_Codec_Configuration called ... ##################btbleClientCB callback = BtbleCallback_AvConnectionState ##############

    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD9A -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD9A -> UNKNOWN
    : Command Status: 0x00
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD06 -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD06 -> UNKNOWN
    : Command Status: 0x00
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD07 -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD07 -> UNKNOWN
    : Command Status: 0x00
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD9C -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD9C -> UNKNOWN
    : Command Status: 0x00
    @
    @
    : Received A2DP_START_IND
    : Codec Instance = 0
    : Event Result = 0x0
    : calling vs_HCI_VS_A3DP_Sink_Start_Stream

    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD9D -> UNKNOWN
    : Received HCI_COMMAND_COMPLETE_EVENT.
    : Num Command Packets: 1 (0x01)
    : Command Opcode: 0xFD9D -> UNKNOWN
    : Command Status: 0x00

    =======================================


    reagrds
    Nitin
  • Hi Nitin,

    I was looking for the Logger logs. Please see the instructions from: processors.wiki.ti.com/.../CC256x_Logger_User_Guide .
    The logger tool is available for download from: www.ti.com/.../wilink-bt_wifi-wireless_tools

    Can you confirm if you're downloading the core SP as well (before the avpr add on)?

    Regards,
    Gigi Joseph.
  • Hi Joseph
    That is good info to tap what is going on in CC2564B and hopefully we will be able to root cause the issue after we capture the log.
    I will try to get rework and use suggested tools to capture logs and share with you.
    Yes i am downloading code SP and add on SP and the downloading of SP is happening without any issue

    I tried with different MTU Sizes but still the sbc data is sent to host rather then decoded at controller.
    By the time i get the log is there something you can think of that could be going wrong in setting A3DP which is causing this problem.


    regards
    Nitin
  • Hi Nitin,

    I can't really comment without seeing the logger logs - but it seems to me from your logs that one of the commands is failing -
    ": Command Status: 0x0C"

    Regards,
    Gigi Joseph.
  • Hi Joseph

    The command  that is showing status as 0x0c is disable BLE. I guess that is because i am not loading BLE add on patch yet and should be the reason it fails. I  did not had that during initial trials I just added in case the internal code in TI module needs it.

    I was able to capture debug log using the debug trace tool suggested in your previous mail. Attached for your reference.

    I have done the setup as per Wiki but the logger is not showing parsed packet info in friendly text but all hex values. Hope you tool will be able to open it and parse it well.

    In A3dp mode i am continously getting lots of 0x00 as the log will show. Let me know if this gives insight to the problem i am facing for A3DP. I will try to get my logger fixed for displaying / parsing logs properly.

    regards

    Nitin

    a3dp-error_lgr.txt

  • A3dp_error1.zipHi

    Can some decode this log from CC2564B (tx_dbg) got using TI logger and let me know what is causing SBC packets to be sent to host rather then getting decoded in BT controller, when i configured for A3DP

    Check attached log:

    Thanks

    regards

    Nitin

  • Hi Nitin,

    (1) Please confirm which CID you're passing to "HCI_VS_A3DP_Open_Stream"
    (2) Please confirm if you're passing the configured parameters to the HCI_VS_A3DP_Sink_Codec_Configuration command.
    (3) You're already sending the "HCI_VS_Write_CODEC_Config" command. So no need to send the HCI_VS_Write_CODEC_Config_Enhanced command afterwards.
    (4) There's no need to send HCI_VS_AVPR_Enable during the stack init. It's being sent by the AVPR service pack. Please remove it and see if it helps.
    (5) Try the HCI_Flow_Spec command to set flow direction to "incoming" and service type as "guaranteed"

    Regards,
    Gigi Joseph.
  • Hi Joseph
    Thanks for your reply
    As suggested i checked all above and it is all fine but still the packets are sent to host stack
    By HCI_VS_A3DP_Open_Stream you meant HCI_VS_A3DP_Sink_Open_Stream right? i am using HCI_VS_A3DP_Sink_Open_Stream and the ACL connection handle is correct and L2CAP cannel ID too is corrent
    I disable config enhanced and even avpr enable but still same.
    I am trying to update flow control and few QOS params but not sure if that is going to solve the problem.
    Do you see QOS issue that can cause this behavior? Can you please recheck the new log i attached yesterday and see what is the real root cause so i am apply a real fix.

    Thanks for your efforts

    regards
    Nitin
  • Hi,

    Please share the new logger logs with the changes that I suggested.
    Please ensure that you use the latest ili/xml files. They are available at: git.ti.com/.../master .

    Regards,
    Gigi Joseph.
  • HI Joseph

    Please find attached log with suggested changes

    Let me know if you see any thing going on wrong here.

    regards

    Nitin

    a3dp_log0306.rar

  • Hi,

    The HCI_VS_A3DP_Open_Stream command should not be sent. You should be only sending the HCI_VS_A3DP_Sink_Open_Stream command. Other than that the commands look okay (assuming you're using the configured SBC params and the AVDTP media channel).

    Please verify if the "HCI_VS_Write_CODEC_Config" parameters are correct and aligned to your codec.

    Regards,
    Gigi Joseph.
  • Hi
    Sending HCI_VS_A3DP_Open_Stream along with HCI_VS_A3DP_Sink_Open_Stream was one experiment i wanted to try that is what the attached log is showing. I am call only a3dp sink related config calls and PCM config but still same result.
    Will try different codec config and some other data format config (PCM I2s master slave and see it their is any change in out come

    Let me know if i can experiment with some thing else to resolve / root cause this issue.
    regards
    Nitin
  • Hi,

    You need to set the correct codec config parameters...

    Regards,
    Gigi Joseph.
  • Hi Joseph
    I have a question regarding codec in BT controller I had strange problem with same module while working on HFP.
    I tried all possible settings for codec at cc2564/and CC2564B while configuring it for HFP voice as per wiki page but nothing worked. Finally when i set PCM clock to 0 (which the doc never suggest) and configure BT side codec to salve and other end wolfson to master i was able to have 2way audio else it was always one way audio and other way noise.

    Can you let me know what is TI's suggestion for codec setting. Should I set it as master or slave / and does it work best in PCM or I2S mode? and what are the settings for PCM clock for 44.1 K sample stream and 48 K stream.
    I guess the codec though suggest a wide rage of PCM lock values for master and slave mode it does work for a particular combination of PCM clock and sample rate in a particular mode which is not listed any where.

    regards
    Nitin
  • Hi Joseph
    As i said in my last mail i will try codec settings, I tried different config for codec for TI^^2564B and also other end codec wolfson but still not result the packets still going to host stack. Also i checked experimenting with MTU size. from 260 bytes to 800 and the L2CAP channel id is correct while opening the A3DP stream.
    Any idea what could be wrong, Others if you have remotely come across this issue please comment..

    regards
    Nitin
  • Hi Joseph
    Do you have any new things that i can try to get over the problme i am seeing with enabling A3DP ?
    Please help.

    regards
    Nitin