This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Android app GATT CONN TIMEOUT

Hi,

I am using nRF51422 with SDK 9.0 and SoftDevice130 with nus service. I have a custom android app running on BLE uart service. Data communication and connection handling is proper with the app. When I switch off the nRf51422 peripheral device, the app will come to know disconnection event only when (0x08) GATT CONN TIMEOUT event occur. I just want to know there is any other way to identify the disconnection event ? If not, is it possible to reduce the GATT CONN TIMEOUT interval ?

Thanks.

Parents
  • I'm guessing you get this event because of the connection supervision timeout. It defines defines the maximum time between two received packets before the connection is considered lost. You should be able to lower this, but you don't want to lower it too much, because you don't want the connection to be considered lost because you lost a packet or two.

    I'm not sure if it is a solution for you, but you can also do a proper disconnect from the peripheral, by calling sd_ble_gap_disconnect().

  • If the peripheral doesn't answer in x number of connection events the connection supervision timeout is hit and it is unavailable. The central can't know if this is because the peripheral is turned off, if it has moved out of range, or if for some other reason the radio signals aren't getting through. To the central these scenarioes would look exactly the same.

Reply Children
No Data
Related