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

Error 22 (0x16): GATT_CONN_TERMINATE_LOCAL_HOST only on Samsung XCover device

When I run the BLE peripheral HRS example on the eval board and try to connect with a Samsung XCover3 using the "nRF Connect" app, I got the error 22 (0x16): GATT_CONN_TERMINATE_LOCAL_HOST.

Doing the same with a Sony Xperia ZL, I got no error. After looking in the logs, there are some interesting services discovered by the Samsung device, that are not realy advertised by the eval board.

My question is now, where comes the error from? Bluetooth chipset of Samsung or a bug in the softdevice? What can I do, to fix this problem?

  • nRF52832
  • SDK 12.2.0
  • Softdevice S132
  • Eval board PCA10040

Working device:

  • Device name: Xperia ZL
  • Android version: 6.0.1
  • Manufacturer: Sony
  • Model: XPeria ZL
  • Build version: cm_odin-userdebug 6.0.1 MOB31K 05f414329b test-keys
  • Board: MSM8960
  • Product: C6503

log_sony_xperia_zl.txt

Non working device:

  • Device name: Samsung SM-G389F
  • Android version: 6.0.1
  • Manufacturer: Samsung
  • Model: SM-G389F
  • Build version: MMB29K.G389FXX U1APK1
  • Board: universal3475
  • Product: xcover3veltexx

log_samsung_xcover3.txt

Wireshark trace with Sony XPeria ZL connecting to HRM example: nordic_hrm_sony_xperia_zl.pcapng

Wireshark trace with Samsung XCover 3 connecting to HRM example: nordic_hrm_samsung_xcover_3.pcapng

Parents
  • Hi,

    This could be caused by an old gatt table with services that you previously bonded with. Try to go into Bluetooth settings on your phone, forget all bluetooth services/devices that you have listed there (paired with) and perhaps disable Bluetooth and enable it again. Then try again and see if it works.

    If this doesn’t work, try to find any error codes reported by the nRF52(any reasons for the disconnect). See e.g. this answer on how to debug. A sniffer trace could also reveal what the problem is.

Reply
  • Hi,

    This could be caused by an old gatt table with services that you previously bonded with. Try to go into Bluetooth settings on your phone, forget all bluetooth services/devices that you have listed there (paired with) and perhaps disable Bluetooth and enable it again. Then try again and see if it works.

    If this doesn’t work, try to find any error codes reported by the nRF52(any reasons for the disconnect). See e.g. this answer on how to debug. A sniffer trace could also reveal what the problem is.

Children
No Data
Related