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.

CC2564: Can't find headset and audio devices.

Part Number: CC2564


Hi. I'm working with cc2564 + STM32 + Bluetopia v4.0.2.2 + Patch v2.14 + IAR compiler.

with HSPDemo project i not have inquiry response from audio devices (headset, bluetooth audio sink). Tested with four different devices.

At the same time i received inquiry responses from many others devices (like PCs, phones, and BLE devices). One of the responsed phones wihtout BLE (Nokia X2-00 only BT 2.1)

Other devices find tested headsets well.

  • Hello Ivan,

    I can think of two possible scenarios that might cause this issue.

    The first would be that the code doesn't use GIAC - General Inquiry access code but a specific set of devices so other devices won't answer it.

    The second would be that you get too many responses - and the device only shows a specific number out of the total responses.

    Can you please send me the exact commands you are using in order to do an inquiry?

    Did you go over the WiKi page explaining how to use the app?

    if not please check the following link:

    BR,

    Chen Loewy

  • Hi. Thanks for answer.

    My inquiry:

    HCI_ASSIGN_GIAC_LAP(LAP);
    HCI_Inquiry(BluetoothStackID, LAP, 10, 20, (Byte_t*)&ret_val);
    if(!ret_val)
    {
    /* The Inquiry appears to have been sent successfully. */
    /* Processing of the results returned from this command occurs */
    /* within the GAP_Event_Callback() function. */
    Display(("Return Value is %d Perform_Inquiry() SUCCESS.\r\n", ret_val));
    NumberofValidResponses = 0;
    }
    else
    {
    /* A error occurred while performing the Inquiry. */
    Display(("Return Value is %d Perform_Inquiry() FAILURE.\r\n", ret_val));
    }

    My HCI_Event_Callback:

    switch(HCI_Event_Data->Event_Data_Type)
          {
             case etExtended_Inquiry_Result_Event:
               if(!(AddrInList(HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.BD_ADDR, (uint8_t*)BoardStr)))
               {
                BD_ADDRToStr(HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.BD_ADDR, BoardStr);
                Display(("Extended_Inquiry:  %s ", BoardStr));
                  Display(("RSSI: %d ", HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.RSSI));
                  Display(("Offset: %d ", HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.Clock_Offset));
                if(HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.Extended_Inquiry_Response.Extended_Inquiry_Response_Data[0] > 0)
                {
                  nStrCopy((uint8_t*)Str, (uint8_t*)&HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.Extended_Inquiry_Response.Extended_Inquiry_Response_Data[2], HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.Extended_Inquiry_Response.Extended_Inquiry_Response_Data[0]-1);
                  Str[HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.Extended_Inquiry_Response.Extended_Inquiry_Response_Data[0]-1] = 0;
                  Display(("[%s]\r\n", Str));
                }
                else
                  Display(("\r\n", Str));
               }
               else
                 Display(("                                  [%s]\r\n", BoardStr));
             break;
             case etInquiry_Complete_Event:
               HCI_ASSIGN_GIAC_LAP(LAP);
               HCI_Inquiry(BluetoothStackID, LAP, 5, 20, (Byte_t*)&ret_val);
             break;
             case etInquiry_Result_With_RSSI_Event:
               if(!(AddrInList(HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.BD_ADDR, (uint8_t*)BoardStr)))
               {
                BD_ADDRToStr(HCI_Event_Data->Event_Data.HCI_Inquiry_Result_With_RSSI_Event_Data->HCI_Inquiry_Result_With_RSSI_Data->BD_ADDR, BoardStr);
                Display(("Inquiry_With_RSSI: %s ", BoardStr));
                  Display(("RSSI: %d ", HCI_Event_Data->Event_Data.HCI_Inquiry_Result_With_RSSI_Event_Data->HCI_Inquiry_Result_With_RSSI_Data->RSSI));
                  Display(("Offset: %d\r\n", HCI_Event_Data->Event_Data.HCI_Inquiry_Result_With_RSSI_Event_Data->HCI_Inquiry_Result_With_RSSI_Data->Clock_Offset));
               }
               else
                 Display(("                                  [%s]\r\n", BoardStr));
             break;
             case etInquiry_Result_Event:
               if(!(AddrInList(HCI_Event_Data->Event_Data.HCI_Extended_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data.BD_ADDR, (uint8_t*)BoardStr)))
               {
                BD_ADDRToStr(HCI_Event_Data->Event_Data.HCI_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data->BD_ADDR, BoardStr);
                Display(("Inquiry_Result:    %s ", BoardStr));
                  Display(("Offset: %d\r\n", HCI_Event_Data->Event_Data.HCI_Inquiry_Result_Event_Data->HCI_Inquiry_Result_Data->Clock_Offset));
               }
               else
                 Display(("                                  [%s]\r\n", BoardStr));
             break;
    
             default:
               Display(("\r\nHCI_Event_Callback: %s\r\n", HCI_TYPES_ARRAY[HCI_Event_Data->Event_Data_Type]));
             break;



    And results at same time on phone and log cc2564 device:

    few devices with known BD_ADDR i filtred out (print only name, like    [KOT])

    On phone HK Esquire Mini and YE-106 are headset devices

  • Hi.

    Just going over the probable suspects.

    what value is your LAP?
  • HCI_ASSIGN_GIAC_LAP(_x) ASSIGN_LAP((_x), 0x9E, 0x8B, 0x33)
  • few times i receive inquiry response from headset. One response per hour with infinite inquiries