A short story about Android BLE connection timeouts and GATT internal errors
Andreas Schweizer

Hi Francesco,

in our case, there was a bug in the peripheral firmware that caused the peripheral not to react any more (see the packets in the connection with the iPhone). The iPhone gives up after 720 milliseconds, but Android tries to reach the peripheral for 20 more seconds.

We were able to fix the bug by properly closing the connection on the peripheral side, i.e. transmitting the LL_TERMINATE_IND PDU. In this case, both iOS and Android immediately acknowledge the termination and close the connection.

So, in most cases, it’s working fine now. The only issue that remains is if the smartphone misses the LL_TERMINATE_IND PDU from the peripheral, eg. because of RF interference. In this case, the smartphone still waits for the supervision timeout to elapse.

HTH, cheers,


Like what you read? Give Andreas Schweizer a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.