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.

CC2541: gaprole_sendupdateparam fail on some android phone.

Part Number: CC2541


My device works fine on iphone & some android phone.

It change the connection parameter by gaprole_sendupdateparam for specified conditions.

But for some android phone, gaprole_sendupdateparam not work.

Verified by packet sniffer:

Failed Android version:4.4.2, 6.0, 7.0

Bt stack version:1.4.1, 1.4.2

ps:

I'm wondering why GAPRole_SetParameter in *_init method does not effective,

gaprole_sendupdateparam using same parameters in GAPRole_SetParameter calls,

But the connection parameter changed after gaprole_sendupdateparam call(sometimes).

Thanks for your help, I struggle on It for one week.

  • Hello Felix,

    It's hard to provide a definitive answer without a sniffer file. As you have probably noticed and unlike iOS, there is no published Android standard for acceptable connection parameters in Android. You will need to test different parameters to find a set that is acceptable for the devices and desired connection parameters you want to support.

    Best wishes
  • Thanks.

    The problem is gaprole_sendupdateparam is not send any packet at all.

    Is there some rule prevent it or it should send packet anyway regardless phone accept it or not? 

    Below is the good case:

    good.psd

    Below is the bad:

    bad.psd

    The packet 6897 in good sent by gaprole_sendupdateparam, It disappear in bad case.

  • Can you confirm with CC Debugger that GAP_UpdateLinkParamReq is being hit? Also, make sure the known issue related to conn param update listed on the BLE wiki is not a factor.

    Best wishes

  • JXS said:

    Also, make sure the known issue related to conn param update listed on the BLE wiki is not a factor.

    I was checked  and  

    ,But did not find conn param update related items.

    Would you like give me the link?

    Thanks lot.

  • Hi felix,

    Sorry for the delay. It looks like the limitation was not published but has been added:

        A Slave initiated L2CAP Connection Parameter Update request via GAP_UpdateLinkParamReq will not be processed by the CC254x's BLE slave stack if the requested connection interval (CI) min/max range does not contain a range value that is a multiple of the current CI. The workaround is for the slave to request a min/max CI range that contains a multiple of the current CI. For example, if the current CI is 11.25ms, the request range should be min=7.5ms to max=X where X is >= than 22.5ms (2 x 11.25ms).

    I looked at your good & bad sniffer (psd) files. You are requesting a min/max CI range of 378.75ms - 398.75ms. In the good capture, the current CI is 18.75ms, so the multiple of 20 x CI falls in your min/max range. In the bad case, the current CI is 50ms, which has no multiple in the min/max range. I think if you change your max to 400ms (320), you should be ok.

    Best wishes