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, HFRE_Open_Remote_HandsFree_Port With Iphone

Hi,

The device use this:

IC: STM32F4, CC2564B with Bluetopia stack. 

IOS version 9.2.1
Iphone 4S

I need some help regarding HFRE_Open_Remote_HandsFree_Port() when the device connect for opening the remote port on the Iphone.

The function HFRE_Open_Remote_HandsFree_Port() return success and the Iphone is connected to the Bluetooth device (Bluetooth setting of IOS). But, the problem is that, the connection is successful and nothing else happens after "HFRE Open Confirmation, ID: 0x0003". There is no Control Indicator status at all and the device can't control the Call as well.

With an Android device everything is OK.

What can I do for an Iphone device?

Thanks in advance,

Denis

  • Hi Denis,

    I believe you want to open the remote audio gateway port? The HFRE_Open_Remote_HandsFree_Port() does the reverse. It is used by the audio gateway (AG) to open a remote HF port.

    The HFRE_Open_Remote_Audio_Gateway_Port() does the reverse, and I think you should be using this.

    Regards,
    Gigi Joseph.
  • Hi Gigi,
    Thank you for your answer,

    I have the same behavior with HFRE_Open_Remote_Audio_Gateway_Port() function.
    I want to open a port in the goal of using this function HFRE_Dial_Phone_Number().

    The device have to reconnect to the Iphone for dialing a phone number.

    Denis
  • Hi Denis,

    Can you please share the snoop/air sniffer logs?

    Regards,
    Gigi Joseph.
  • Hi Gigi,
    Yes for sure at the end of this post.
    Take note that in the sniffer logs, the Bluetooth MAC Address is hard coded in the code for helping me in this issue. Also, the service discovery is done only for the "Audio gateway".

    My Iphone is well connected after the logs "HFRE Open Confirmation, ID: 0x0002".

    One more question: On what version of Iphone and IOS that it is supposed to work?

    Thank you,
    Denis


    >conclassic
    Connect Request successful.
    >
    atLinkKeyRequest: 0x3CD0F833A81F
    GAP_Authentication_Response() Success.
    >
    atPINCodeRequest: 0x3CD0F833A81F
    The command PinCodeResponse is executed
    GAP_Authentication_Response(), Pin Code Response Success.
    >
    atLinkKeyCreation: 0x3CD0F833A81F
    Link Key: 0xB18536249009F1335BB15DD1662749AB
    Link Key Stored locally.
    >
    atAuthenticationStatus: 0 Board: 0x3CD0F833A81F
    >
    >servicedisc
    SDP_Service_Search_Attribute_Request(Audio gateway) Success.
    >
    atLinkKeyRequest: 0x3CD0F833A81F
    Link Key: 0xB18536249009F1335BB15DD1662749AB
    GAP_Authentication_Response() Success.
    >
    SDP Service Search Attribute Response Received (Size = 0x0010)
    Service Record: 1:
    Attribute ID 0x0000
    Type: Unsigned Int = 0x4F49111F
    Attribute ID 0x0001
    Type: Data Element Sequence
    Type: UUID_16 = 0x111F
    Type: UUID_16 = 0x1203
    Attribute ID 0x0002
    Type: Unsigned Int = 0x00000000
    Attribute ID 0x0004
    Type: Data Element Sequence
    Type: Data Element Sequence
    Type: UUID_16 = 0x0100
    Type: Data Element Sequence
    Type: UUID_16 = 0x0003
    Type: Unsigned Int = 0x08
    Attribute ID 0x0005
    Type: Data Element Sequence
    Type: UUID_16 = 0x1002
    Attribute ID 0x0006
    Type: Data Element Sequence
    Type: Unsigned Int = 0x656E
    Type: Unsigned Int = 0x006A
    Type: Unsigned Int = 0x0100
    Type: Unsigned Int = 0x6672
    Type: Unsigned Int = 0x006A
    Type: Unsigned Int = 0x0110
    Type: Unsigned Int = 0x6465
    Type: Unsigned Int = 0x006A
    Type: Unsigned Int = 0x0120
    Type: Unsigned Int = 0x6A61
    Type: Unsigned Int = 0x006A
    Type: Unsigned Int = 0x0130
    Attribute ID 0x0008
    Type: Unsigned Int = 0xFF
    Attribute ID 0x0009
    Type: Data Element Sequence
    Type: Data Element Sequence
    Type: UUID_16 = 0x111E
    Type: Unsigned Int = 0x0106
    Attribute ID 0x0100
    Type: Text String = Handsfree Gateway
    Attribute ID 0x0301
    Type: Unsigned Int = 0x01
    Attribute ID 0x0311
    Type: Unsigned Int = 0x002F
    >openremoteag 1
    Bluetooth Device Address: 0x3CD0F833A81F
    Open Remote HandsFree Port = 0001
    HCITR_COMProcess: MaxLength 4: TotalLength: 7
    >HFRE_Open_Remote_Audio_Gateway_Port: Function Successful (ID = 0002).
    >
    atLinkKeyRequest: 0x3CD0F833A81F
    Link Key: 0xB18536249009F1335BB15DD1662749AB
    GAP_Authentication_Response() Success.
    >
    HFRE Open Confirmation, ID: 0x0002
    >
  • Hi Denis,

    I couldn't see the attachment.
    Can you attach it again?

    Regards,
    Gigi Joseph.
  • Hi Gigi,

    Here is the bluetooth capture packet from WireShark Version 2.0.1 on a Linux desktop. I hope that it help. Remark at the end, the command status Disconnect is happen without any user intervention. 

    Denis

    openremoteag.zip

  • Hi Denis,

    The attached logs are just snoop logs at the linux side between linux and a TI controller.
    It just shows some ACL connection/disconnection. There's nothing on the iPhone connection issue.

    You mentioned in your earlier post - Take note that in the sniffer logs, the Bluetooth MAC Address is hard coded in the code for helping me in this issue. Also, the service discovery is done only for the "Audio gateway".

    Can you please share "this" air sniffer log?

    Regards,
    Gigi Joseph.
  • Hi Gigi,

    Thanks for you reply, I understand what you need but I don't have a Bluetooth Classic air sniffer tool in our labs. Could you suggest one tool? Ti have one "smartRF", but it is only for Bluetooth LE.

    Thanks,
    Denis
  • Hi Denis,

    You can use either Frontline or Ellisys

    Regards,
    Gigi Joseph.

  • Hi Gigi,

    Thank you for your great support, I found my answer in another thread of a Ti forum.
    I used a wrong port number for the remote port ID in the function HFRE_Open_Remote_Audio_Gateway_Port().

    Here is the port number to use in the service discovery response:
    "
    Attribute ID 0x0004
    Type: Data Element Sequence
    Type: Data Element Sequence
    Type: UUID_16 = 0x0100
    Type: Data Element Sequence
    Type: UUID_16 = 0x0003
    Type: Unsigned Int = 0x08 <--- This is the Port # !
    "
    Original thread :"e2e.ti.com/.../1773874

    Regards,
    Denis