No peripheral connection after disconnect with Android App Nordic Uart Service until mac-address of smartphone changes

No connection after disconnect with Android App Nordic Uart Service until mac-address of smartphone changes

Multilink multirole software developed in SES studio.

Other smartphone can connect without reset of NRF52 or I should wait until first phone changes its mac-address.

No feedback (from any handle) from NRF52... just no connection

LOG from Android studio

2021-12-16 20:54:23.372 11320-11353/com.sicameiot.PingPong D/Surface: Surface::connect(this=0x72766ee000,api=1)
2021-12-16 20:54:23.373 11320-11353/com.sicameiot.PingPong D/Surface: Surface::setBufferCount(this=0x72766ee000,bufferCount=3)
2021-12-16 20:54:24.429 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: stopLeScan()
2021-12-16 20:54:24.432 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: scan not started yet
2021-12-16 20:54:25.306 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: stopLeScan()
2021-12-16 20:54:25.309 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: isLeEnabled(): ON
2021-12-16 20:54:25.325 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: stopLeScan()
2021-12-16 20:54:25.327 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: scan not started yet
2021-12-16 20:54:25.348 11320-11320/com.sicameiot.PingPong D/DM-30: ... onActivityResultdevice.address==E3:F6:F8:7B:76:E1mserviceValuecom.sicameiot.PingPong.UartService@7c66d8e
2021-12-16 20:54:25.350 11320-11320/com.sicameiot.PingPong D/BluetoothGatt: connect() - device: E3:F6:F8:7B:76:E1, auto: false
2021-12-16 20:54:25.350 11320-11320/com.sicameiot.PingPong D/BluetoothGatt: registerApp()
2021-12-16 20:54:25.350 11320-11320/com.sicameiot.PingPong D/BluetoothGatt: registerApp() - UUID=1f7942b9-e69c-4196-ba66-a35a71c70388
2021-12-16 20:54:25.353 11320-11320/com.sicameiot.PingPong D/UartService: Trying to create a new connection.
2021-12-16 20:54:25.354 11320-11320/com.sicameiot.PingPong D/DM-30: onResume
2021-12-16 20:54:25.354 11320-11338/com.sicameiot.PingPong D/BluetoothGatt: onClientRegistered() - status=0 clientIf=7
2021-12-16 20:54:25.356 11320-11320/com.sicameiot.PingPong V/PhoneWindow: DecorView setVisiblity: visibility = 0, Parent = android.view.ViewRootImpl@b17118d, this = DecorView@399f42[MainActivity]
2021-12-16 20:54:25.380 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: stopLeScan()
2021-12-16 20:54:25.382 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: scan not started yet
2021-12-16 20:54:25.384 11320-11320/com.sicameiot.PingPong V/PhoneWindow: DecorView setVisiblity: visibility = 4, Parent = android.view.ViewRootImpl@29581d1, this = DecorView@6a5bb6a[DeviceListActivity_master]
2021-12-16 20:54:25.385 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: stopLeScan()
2021-12-16 20:54:25.386 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: scan not started yet
2021-12-16 20:54:25.390 11320-11353/com.sicameiot.PingPong D/Surface: Surface::disconnect(this=0x72766ee000,api=1)
2021-12-16 20:54:25.392 11320-11320/com.sicameiot.PingPong D/View: [Warning] assignParent to null: this = DecorView@6a5bb6a[DeviceListActivity_master]
2021-12-16 20:54:25.393 11320-11320/com.sicameiot.PingPong I/InputTransport: Destroy ARC handle: 0x728380a840
2021-12-16 20:54:25.883 11320-11338/com.sicameiot.PingPong D/BluetoothGatt: onClientConnectionState() - status=133 clientIf=7 device=E3:F6:F8:7B:76:E1
2021-12-16 20:54:25.884 11320-11338/com.sicameiot.PingPong I/UartService: Disconnected from GATT server.
2021-12-16 20:54:25.886 11320-11320/com.sicameiot.PingPong D/DM-30: UART_DISCONNECT_MSG
2021-12-16 20:54:25.886 11320-11320/com.sicameiot.PingPong W/UartService: mBluetoothGatt closed
2021-12-16 20:54:25.886 11320-11320/com.sicameiot.PingPong D/BluetoothGatt: close()
2021-12-16 20:54:25.886 11320-11320/com.sicameiot.PingPong D/BluetoothGatt: unregisterApp() - mClientIf=7
2021-12-16 20:54:33.119 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: stopLeScan()
2021-12-16 20:54:33.122 11320-11320/com.sicameiot.PingPong D/BluetoothAdapter: scan not started yet

Parents
  • Hi

    The "6320.wireshark.pcapng" file only shows L2CAP fragments from the Master (central side) on my end 

    Regarding the disconnect reason (19) you're seeing, this can be a few things. The one I think is most likely, since you're only seeing this issue with one specific phone. Is that the phone is struggling with keeping up with the crystal frequency on the nRF52833 DK at low connection intervals, causing it to disconnect even though it has been able to connect once. You can try increasing the MIN_CONN_INTERVAL and MAX_CONN_INTERVAL to larger values to see if that helps. For example to 50 and 100 respectively. 

    Best regards,

    Simon

  • Dear.

    disconnect 19 is not a problem. I disconnect it manually.

    But I cant connect again til mac address android changes (different android)

    No any feedback from nrf52.

Reply Children
Related