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.

Bluetopia just-works behavior? :)

Guru 18625 points

Good morning,

we are testing our application with several android devices. We are using Bluetopia software (SPPLEDemo) on top of TivaC TM4C123G + CC256x. The application works fine. We are focusing now in the Classic BT part, not BLE, even if the application is capable of both.

However, when trying to pair (just-works) several of our smartphones, some of them require the user to press "ok" on the display, while several others not. We would prefer the whole thing to occur with no user intervention :)

The devices requiring user intervention are:

  • samsung nexus S, android 4.1.2
  • motorola motog, android 4.4.4 

The ones which perform direct pairing are:

  • Nexus 5, android 5.0.1
  • BQ Edison, android 4.2.2
  • Samsung S3, android 4.3

Our Bluetopia version is v1.2R2. We know there is a newer 1.2 version but I cannot find the updated link. This one still points to 1.2R2 :)

So my question is twofold :)

  1. Where in the code should we force the connection to occur with no user intervention?
  2. Where is the 1.2 version?

Let me know if anybody has any hint or has experienced similar issues.

  • Hi,

    Can you try setting the SetPairabilityMode to SSP(secured simple pairing) and then set the IO capabilities (ChangeSimplePairingParameters) to No Input/output and try.

    The latest Tiva version available is 1.2R2 (www.ti.com/.../tibluetoothstack-sdk)
  • Please see my trace:

    OpenStack().

    HCI_VS_InitializeAfterHCIReset

    VS_Update_UART_Baud_Rate success.

    HCI_VS_InitializeAfterHCIReset Success

    Bluetooth Stack ID: 1.

    Device Chipset: 4.1.

    BD_ADDR: 0x0017e9506364

    Choose Mode>Server

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

    * Command Options General: Help, GetLocalAddress, SetBaudRate    *

    *                          Quit,                                 *

    * Command Options BR/EDR:  Inquiry, DisplayInquiryList, Pair,    *

    *                          EndPairing, PINCodeResponse,          *

    *                          PassKeyResponse,                      *

    *                          UserConfirmationResponse,             *

    *                          SetDiscoverabilityMode,               *

    *                          SetConnectabilityMode,                *

    *                          SetPairabilityMode,                   *

    *                          ChangeSimplePairingParameters,        *

    *                          GetLocalName, SetLocalName,           *

    *                          GetClassOfDevice, SetClassOfDevice,   *

    *                          GetRemoteName, SniffMode,             *

    *                          ExitSniffMode, Open, Close, Read,     *

    *                          Write, GetConfigParams,               *

    *                          SetConfigParams, GetQueueParams,      *

    *                          SetQueueParams, Loopback,             *

    *                          DisplayRawModeData, AutomaticReadMode,*

    *                          CBSend.                               *

    * Command Options GAPLE:   SetDiscoverabilityMode,               *

    *                          SetConnectabilityMode,                *

    *                          SetPairabilityMode,                   *

    *                          ChangePairingParameters,              *

    *                          AdvertiseLE, StartScanning,           *

    *                          StopScanning, ConnectLE,              *

    *                          DisconnectLE, PairLE,                 *

    *                          LEPasskeyResponse,                    *

    *                          QueryEncryptionMode, SetPasskey,      *

    *                          DiscoverGAPS, GetLocalName,           *

    *                          SetLocalName, GetLERemoteName,        *

    *                          SetLocalAppearance,                   *

    *                          GetLocalAppearance,                   *

    *                          GetRemoteAppearance,                  *

    * Command Options SPPLE:   DiscoverSPPLE, RegisterSPPLE, LESend, *

    *                          ConfigureSPPLE, LERead, Loopback,     *

    *                          DisplayRawModeData, AutomaticReadMode *

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

    SPP+LE>Open 1

    Server Opened: Server Port 1, Serial Port ID 1.

    Server Port Context Stored.

    SPP+LE>

    SPP+LE>SetPairabilityMode 2

    Pairability Mode Changed to pmPairableMode_EnableSecureSimplePairing.

    LE:     I/O Capabilities: No Input/Output, MITM: FALSE.

    BR/EDR: I/O Capabilities: No Input/Output, MITM: FALSE.

    SPP+LE>SetConnectabilityMode 1

    Connectability Mode: Connectable.

    SPP+LE>SetDiscoverabilityMode 2

    Discoverability: General.

    SPP+LE>ChangeSimplePairingParameters 3 0

    LE:     I/O Capabilities: No Input/Output, MITM: FALSE.

    BR/EDR: I/O Capabilities: No Input/Output, MITM: FALSE.

    SPP+LE>Result OOB:1, 0xe4b021f56b51

    Result: 1,0xe4b021f56b51.

    Server>Pair 1

    GAP_Initiate_Bonding(Dedicated): Success.

    I think I already do what you ask me in my trace. Do you have any other suggestion?

    PS: we tried with a Google Nexus 3 and also appears as a Notification which needs to be confirmed. May this be because the "notification" states "Do you want to connect to NULL"?

    Have a nice day.

  • Hi,

    That is strange, You mean to say you are seeing the user confirmation request on the DUT (Tiva + CC256x).
    If you use Display Yes/No it will prompt to show a Pincode when pairing. If you use No Input/Output it should pair automatically. In the remote device, you may have to create a secured connection, which is why you receive a pairing request each time.
  • Hi,

    I have try the same on my set up (by initiating the pairing from the DUT) with Nexus 4 without any issue.

    SPP+LE>pair 1

    GAP_Initiate_Bonding(Dedicated): Success.

    SPP+LE>

    atLinkKeyRequest: 0x10683f59e8a1

    GAP_Authentication_Response success.

    SPP+LE>

    atIOCapabilityRequest: 0x10683f59e8a1

    Auth success.

    SPP+LE>

    atIOCapabilityResponse: 0x10683f59e8a1

    Capabilities: Display Yes/No, MITM

    SPP+LE>

    atUserConfirmationRequest: 0x10683f59e8a1

    Auto Accepting: ERROR

    GAP_Authentication_Response success.

    SPP+LE>Un-handled Auth. Event.

    SPP+LE>

    atLinkKeyCreation: 0x10683f59e8a1

    Link Key Stored.

    SPP+LE>

    atAuthenticationStatus: 0 for 0x10683f59e8a1

    SPP+LE>

    Do you have any logs you can provide? It is not clear what you are seeing on the remote device? what is the pop-up? is it pin code request or user confirmation request?