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.

CC2564MODA: HSP profile bluetooth mic is not working

Part Number: CC2564MODA
Other Parts Discussed in Thread: CC2564

Hi,

We are using CC2564MODA bluetooth modules audio interface with Telit GSM LE910V2.

For Telit modem i am getting 8khz frame clock, 16bit data and 256khz bit clock.

We have configured the CC2564MODA module as slave I2S.

I have connected HSP profile headset to CC2564. in Call i am able to hear the voice but MIC is not working (heavy noise is coming).

my bluetooth codec config code is bellow :

*******************************************************************************************

    memset(CommandBuffer, 0, 34);
    /* PCM clock rate (kHz) and direction (0 = output, 1 = input)     */
    /* out from Talit in to cc2564 */
    p_cmd = CommandBuffer;
    UINT16_TO_STREAM(p_cmd, 256);
    CommandBuffer[2] = 0x01;

    /* Frame-sync freq (Hz) and duty cycle. For duty cycle, 0 will    */
    /* generate 50% duty cycle, >= 1 uses number of PCM clock cycles. */
    p_cmd = &CommandBuffer[3];
    UINT32_TO_STREAM(p_cmd, 8000000);
    p_cmd = &CommandBuffer[7];
    UINT16_TO_STREAM(p_cmd, 0x0000);

    /* Frame-sync edge: 0 = rising edge, 1 = falling edge             */
    CommandBuffer[9]  = 0x00;

    /* Frame-sync polarity: 0 = active high, 1 = active low           */
    CommandBuffer[10] = 0x00;

    /* channel 1 data out size, offset, and edge (0 = rise, 1 = fall) */
    /* Talit is riseing */
    p_cmd = &CommandBuffer[12];
    UINT16_TO_STREAM(p_cmd, 16);
    p_cmd = &CommandBuffer[14];
    UINT16_TO_STREAM(p_cmd, 1);
    CommandBuffer[16] = 0x00;

    /* channel 1 data in size, offset, and edge (0 = rise, 1 = fall)  */
    p_cmd = &CommandBuffer[17];
    UINT16_TO_STREAM(p_cmd, 16);
    p_cmd = &CommandBuffer[19];
    UINT16_TO_STREAM(p_cmd, 1);
    CommandBuffer[21] = 0x00;

    /* channel 2 data out size, offset, and edge (0 = rise, 1 = fall) */
    p_cmd = &CommandBuffer[23];
    UINT16_TO_STREAM(p_cmd, 16);
    p_cmd = &CommandBuffer[25];
    UINT16_TO_STREAM(p_cmd, 17);
    CommandBuffer[27] = 0x00;

    /* channel 2 data in size, offset, and edge (0 = rise, 1 = fall)  */
    p_cmd = &CommandBuffer[28];
    UINT16_TO_STREAM(p_cmd, 16);
    p_cmd = &CommandBuffer[30];
    UINT16_TO_STREAM(p_cmd, 17);
    CommandBuffer[32] = 0x00;

*******************************************************************************

Thanks,
shravan kumar

  • Shravan,

    Have you tried a PCM loopback test on your hardware? This loopback mode is for the PCM interface (so no data over BT).

    processors.wiki.ti.com/.../CC256x_VS_HCI_Commands

    It is recommended to do this test first in order to make sure that the hardware is configured properly and the PCM parameters in the CC256x codec config are correct. If using the TI dual mode Bluetooth stack, you can refer to the PcmLoopback() function in A3DP/HFP Demos for implementation. The loopback mode must be enabled after initializing AVPR and configuring the PCM interface using the HCI_VS_Write_CODEC_Config command.

    Best regards,
    Vihang
  • Hi Vihang,

    After sending Pcm Loop-back enable command we are not able to hear any thing at both sides.
    If we are not sending pcm loop-back command we are able to hear the voice but for mic noise is coming.

    My code flow in the application.
    i) We have loaded thee dts file.
    1) Main BT init script
    2) AVPR init script
    3) BLE init script

    ii) we have send PcmLoopback command.

    iii) we have configured the HCI_VS_Write_CODEC_Config. as mentioned in the above.

    Any suggestion on above issue.

    Thanks,
    Shravan.
  • Hi,

    After sending Pcm Loop-back enable command we are not able to hear any thing at both sides.
    If we are not sending pcm loop-back command we are able to hear the voice but for mic noise is coming.

    My code flow in the application.
    i) We have loaded thee dts file.
    1) Main BT init script
    2) AVPR init script
    3) BLE init script

    ii) we have send PcmLoopback command.

    iii) we have configured the HCI_VS_Write_CODEC_Config. as mentioned in the above.

    Any suggestion on above issue.
  • Hi,

    The AVPR and BLE cannot work simultaneously as explained in the datasheet. Please remove the step where you download the BLE initscript.

    Best regards,
    Vihang
  • Hi,


    Is three any linux command line tool to test the HSP profile for CC2564. like paring bluetooth Headset etc.

    But we wanted to do this in android mars-mellow how can i do it with without BLE.

    With out BLE it is not even pairing.

    Thanks,
    shravan.