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: BLE SDK abnormal supervision timeout question

Part Number: CC2541

Posted for a customer-

I'm reaching out with a specific technical question regarding the behavior of the TI BLE stack on the CC2541 TI SoC chip when it's given an abnormal supervision timeout from the application code. Namely, we have a case where we were setting the connection supervision timeout to zero. The code looked like ths:

 

GAP_SetParamValue(TGAP_CONN_EST_SUPERV_TIMEOUT, 0);

 

From reading the TI documentation and webboard this doesn't seem to be a valid value, although the stack was returning SUCCESS from the API call. What I'm interested in knowing is what kind of behavior would this cause? Does a value of zero disable the connection supervision timeout altogether, does the stack use a minimum value instead, or does zero mean drop the connection when the first packet is lost at the connection interval?

 

Here's some information about the version of the BLE SDK we are using:

 

Release Name: ble_sdk_1.4.2.2

Release Date: 2016-06-09 06:57:09

 

Thank you for the information. Any insight you can provide into the inner workings of the stack will be greatly appreciated.

  • Hi,

    No, a value of 0 does not disable the timeout.

    The supervision timeout parameter specifies the maximum amount of time that either the master or slave can go before receiving a link-layer packet. Both slave and master device maintain their own “Supervision timer”, which resets to zero every time a packet is received. If supervision timer ever reaches the supervision timeout, the device considers the connection lost, and exits the connection state (returning to the advertising, scanning, or standby state).

    The Supervision Timeout is a multiple of 10ms in the range of 100ms and 32.0s. It Must be larger than (1 + slaveLatency) * (ConnInterval) where,

    • Slave Latency is any value between 0 and 499, though it cannot exceed:  ((supervisionTimeout / connInterval) – 1)
    • Connection Interval is a multiple of 1.25ms in range of 7.5ms and 4.0s

    I would suspect that the value would be deemed invalid and would continue to use the previous value.

    Either way, it's not recommended and to comply with the specification, the customer must follow the above rules