Hello.
I'm trying to connect to nordic device, but only connects randomly.
The logs of Android in attachment.
Android version: 11
The java code:
public void connect(Callback callback, Activity activity) {if (!connected) {BluetoothDevice device = getDevice();this.connectCallback = callback;this.connecting = true;Handler handler = new Handler(Looper.getMainLooper());if (Build.VERSION.SDK_INT > Build.VERSION_CODES.O) {Log.d(BleManager.LOG_TAG, "connectGatt(activity, false, this, BluetoothDevice.TRANSPORT_LE, PhyRequest.PHY_LE_1M_MASK | PhyRequest.PHY_LE_2M_MASK | PhyRequest.PHY_LE_CODED_MASK, handler)");gatt = device.connectGatt(activity, false, this,BluetoothDevice.TRANSPORT_LE, 1 | 1 << 1 | 1 << 2, handler);} else if (Build.VERSION.SDK_INT == Build.VERSION_CODES.O) {// A variant of connectGatt with Handled can't be used here.// Check https://github.com/NordicSemiconductor/Android-BLE-Library/issues/54// This bug specifically occurs in SDK 26 and is fixed in SDK 27Log.d(BleManager.LOG_TAG, "connectGatt(activity, false, this, BluetoothDevice.TRANSPORT_LE, PhyRequest.PHY_LE_1M_MASK | PhyRequest.PHY_LE_2M_MASK | PhyRequest.PHY_LE_CODED_MASK)");gatt = device.connectGatt(activity, false, this,BluetoothDevice.TRANSPORT_LE, 1 | 1 << 1 | 1 << 2/*, handler*/);} else if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {Log.d(BleManager.LOG_TAG, "connectGatt(activity, false, this, BluetoothDevice.TRANSPORT_LE)");gatt = device.connectGatt(activity, false, this,BluetoothDevice.TRANSPORT_LE);} else {Log.d(BleManager.LOG_TAG, "connectGatt(activity, false, this)");gatt = device.connectGatt(activity, false, this);}} else {if (gatt != null) {callback.invoke();} else {callback.invoke("BluetoothGatt is null");}}}
The output on adb logcat:
01-01 14:57:41.214 1973 4130 I BluetoothAdapter: STATE_ON01-01 14:57:41.214 1973 4130 D BluetoothLeScanner: Stop Scan with callback01-01 14:57:41.221 17562 17661 D BtGatt.ContextMap: remove() - id: 701-01 14:57:41.221 17562 17661 E BtGatt.ContextMap: remove() - removed: 701-01 14:57:41.222 17562 17622 I bt_stack: [INFO:gatt_api.cc(1102)] GATT_Deregister gatt_if=701-01 14:57:41.222 17562 17622 I bt_stack: [INFO:gatt_api.cc(1155)] Initialize tGATT_REG01-01 14:57:41.223 1973 4130 I Nearby : [MBleClient] M hardware scan: 1 clients, scanMode= OPPORTUNISTIC, filters size = 5 [CONTEXT service_id=49 ]01-01 14:57:41.223 1973 4130 I BluetoothAdapter: STATE_ON01-01 14:57:41.224 1973 4130 I BluetoothAdapter: STATE_ON01-01 14:57:41.224 1973 4130 I BluetoothAdapter: STATE_ON01-01 14:57:41.225 1973 4130 D BluetoothLeScanner: Start Scan with callback01-01 14:57:41.228 17562 17661 D BtGatt.ContextMap: add() - appUid: 10179, appPid: 1973, appName: com.google.uid.shared01-01 14:57:41.228 17562 17616 W BtGatt.GattService: checkToReportData before boot completed01-01 14:57:41.229 17562 17616 E BtGatt.GattService: [GSIM LOG]: gsimLogHandler, msg: MESSAGE_SCAN_STOP, appName: com.google.uid.shared, scannerId: 7, reportDelayMillis=001-01 14:57:41.229 17562 17593 D BtGatt.GattService: onScannerRegistered() - UUID=e43ffbb5-88d4-4ecc-bce8-7f2728c4e6e6, scannerId=7, status=001-01 14:57:41.229 1973 4873 D BluetoothLeScanner: onScannerRegistered() - status=0 scannerId=7 mScannerId=001-01 14:57:41.231 17562 17661 I BluetoothAdapter: STATE_ON01-01 14:57:41.234 17562 17613 I BluetoothAdapter: STATE_ON01-01 14:57:41.235 17562 17613 I BluetoothAdapter: STATE_ON01-01 14:57:41.235 17562 17616 W BtGatt.GattService: checkToReportData before boot completed01-01 14:57:41.236 17562 17613 I BluetoothAdapter: STATE_ON01-01 14:57:41.236 17562 17616 E BtGatt.GattService: [GSIM LOG]: gsimLogHandler, msg: MESSAGE_SCAN_START, appName: com.google.uid.shared, scannerId: 7, reportDelayMillis=001-01 14:57:41.236 17562 17616 W BtGatt.GattService: [GSIM LOG]: this is opportunistic scan, do not update DB01-01 14:57:41.236 17562 17622 E bt_btm : BTM_BleObserve Observe Already Active01-01 14:57:41.236 17562 17622 W bt_btif : bta_dm_ble_observe BTM_BleObserve failed. status 601-01 14:57:41.239 947 1393 D androidtc: Initializing SystemTextClassifier, type = System01-01 14:57:41.241 947 1393 E ClipboardService: Denying clipboard access to com.google.android.gm, application is not in focus nor is it a system service for user 001-01 14:57:41.241 947 1393 I ActivityManager: Changes in 10154 7 to 5, 0 to 801-01 14:57:41.245 6553 6570 I IceCone : a insert to clipboard from 10281 01-01 14:57:41.248 947 966 D NetworkPolicy: onUidStateChanged() uid: 10154, isForeground(true, 5)01-01 14:57:41.249 17562 17562 D HidDeviceService: handleMessage(): msg.what=801-01 14:57:41.253 947 5816 D SecContentProvider: query(), uri = 15 selection = isClipboardShareAllowedAsUser01-01 14:57:41.253 6553 6553 I IceCone : a copied item is duplicated. 01-01 14:57:41.253 947 5816 D SecContentProvider: called from android.uid.honeyboard:1015401-01 14:57:41.253 947 5816 D RestrictionPolicy: isClipboardShareAllowed : true01-01 14:57:41.254 6553 6553 I HBD : a clipType - 1 01-01 14:57:41.255 6553 6553 I IceCone : a remote copy failed. Continue apps on other devices Setting is Off. 01-01 14:57:41.256 6553 7066 I IceCone : RichcontentProvider query : 3, null, false 01-01 14:57:41.257 1973 3831 I NearbyDiscovery: FastPairScanner: isScreenOn=true, scanWithScreenOff=false, isLocationEnabled=true, disableLocationRequirement=true, isDiscoveryScanningEnabled=true, during24GhzWifiWarmingUpPeriod=false [CONTEXT service_id=265 ]01-01 14:57:41.257 1973 3831 I BluetoothAdapter: STATE_ON01-01 14:57:41.258 1973 3831 I NearbyDiscovery: FastPairScanner: eventType=INTERNAL_DOWNGRADE_SCAN, intReq=true, scanning=true, scanAllowed=true, bleEnabled=true, bleScanAvailable=true, lockScanRate=false, startScanningByLowPowerMode=false [CONTEXT service_id=265 ]01-01 14:57:41.259 1973 3831 I NearbyDiscovery: FastPairScanner: Stopping scan [CONTEXT service_id=265 ]01-01 14:57:41.259 1973 3831 I BluetoothAdapter: STATE_ON01-01 14:57:41.259 1973 3831 D BluetoothLeScanner: Stop Scan with callback01-01 14:57:41.261 947 1203 E ClipboardService: Denying clipboard access to com.google.android.gm, application is not in focus nor is it a system service for user 001-01 14:57:41.262 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x2, to_resume = 101-01 14:57:41.263 17562 17662 D BtGatt.ContextMap: remove() - id: 601-01 14:57:41.263 17562 17662 E BtGatt.ContextMap: remove() - removed: 601-01 14:57:41.263 17562 17622 I bt_stack: [INFO:gatt_api.cc(1102)] GATT_Deregister gatt_if=601-01 14:57:41.263 17562 17622 I bt_stack: [INFO:gatt_api.cc(1155)] Initialize tGATT_REG01-01 14:57:41.264 1973 3831 I NearbyDiscovery: FastPairScanner: isScreenOn=true, scanWithScreenOff=false, isLocationEnabled=true, disableLocationRequirement=true, isDiscoveryScanningEnabled=true, during24GhzWifiWarmingUpPeriod=false [CONTEXT service_id=265 ]01-01 14:57:41.265 17562 17616 W BtGatt.GattService: checkToReportData before boot completed01-01 14:57:41.265 17562 17616 E BtGatt.GattService: [GSIM LOG]: gsimLogHandler, msg: MESSAGE_SCAN_STOP, appName: com.google.uid.shared, scannerId: 6, reportDelayMillis=001-01 14:57:41.265 1973 3831 I NearbyDiscovery: FastPairScanner: Start scanning internally in LOW_POWER_SCANNING [CONTEXT service_id=265 ]01-01 14:57:41.265 1973 3831 I BluetoothAdapter: STATE_ON01-01 14:57:41.266 1973 3831 I BluetoothAdapter: STATE_ON01-01 14:57:41.266 1973 3831 I BluetoothAdapter: STATE_ON01-01 14:57:41.266 1973 3831 D BluetoothLeScanner: Start Scan with callback01-01 14:57:41.268 17562 17662 D BtGatt.ContextMap: add() - appUid: 10179, appPid: 1973, appName: com.google.uid.shared01-01 14:57:41.269 17562 17593 D BtGatt.GattService: onScannerRegistered() - UUID=f927dc9e-e823-47ab-990d-525d924fba72, scannerId=6, status=001-01 14:57:41.269 1973 4873 D BluetoothLeScanner: onScannerRegistered() - status=0 scannerId=6 mScannerId=001-01 14:57:41.271 17562 17662 I BluetoothAdapter: STATE_ON01-01 14:57:41.273 17562 17613 I BluetoothAdapter: STATE_ON01-01 14:57:41.273 17562 17613 E LeLogInfo: invalid scanMode01-01 14:57:41.274 1973 3831 I NearbyDiscovery: FastPairScanner: Starting LOW_POWER_SCANNING scanning [CONTEXT service_id=265 ]01-01 14:57:41.275 17562 17613 I BluetoothAdapter: STATE_ON01-01 14:57:41.275 17562 17616 W BtGatt.GattService: checkToReportData before boot completed01-01 14:57:41.275 17562 17613 I BluetoothAdapter: STATE_ON01-01 14:57:41.275 17562 17616 E BtGatt.GattService: [GSIM LOG]: gsimLogHandler, msg: MESSAGE_SCAN_START, appName: com.google.uid.shared, scannerId: 6, reportDelayMillis=001-01 14:57:41.275 17562 17616 W BtGatt.GattService: [GSIM LOG]: this is opportunistic scan, do not update DB01-01 14:57:41.277 947 4431 D SGM:GameManager: identifyGamePackage. com.mycompany.myapp, mCurrentUserId: 0, callerUserId: 0, callingMethodInfo: com.android.server.ssrm.SortingMachine.isGame(SortingMachine.java:162)01-01 14:57:41.278 17562 17613 D BtGatt.ScanManager: configureFilterParamter() : onFoundTimeout | onLostTimeout | onFoundCount | numOfTrackingEntries | scanFilterRssiThreshold | trackableScanFilterRssiThreshold | matchMode01-01 14:57:41.278 17562 17613 D BtGatt.ScanManager: configureFilterParamter() : __________500__|________10000__|___________1__|___________________0__|___________________-128__|____________________________-128__|________1_01-01 14:57:41.278 947 4431 D SGM:PkgDataHelper: getGamePkgData(). com.mycompany.myapp01-01 14:57:41.279 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x2, to_resume = 101-01 14:57:41.279 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x2, to_resume = 101-01 14:57:41.279 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x2, to_resume = 101-01 14:57:41.291 947 1187 I SemWifiServiceDetector: Traff. tracking resumed01-01 14:57:41.369 16719 16856 D ReactNativeBleManager: Stop scan01-01 14:57:41.449 947 966 I GestureDetector: handleMessage TAP01-01 14:57:41.450 947 947 I GestureDetector: handleMessage TAP01-01 14:57:41.483 16719 16855 I ReactNativeJS: Scan is stopped01-01 14:57:41.637 947 973 I ActivityManager: Changes in 10045 5 to 15, 8 to 001-01 14:57:41.638 947 966 D NetworkPolicy: onUidStateChanged() uid: 10045, isForeground(false, 15)01-01 14:57:41.638 17562 17562 D HidDeviceService: handleMessage(): msg.what=801-01 14:57:41.806 947 1187 D SemNscXgbMsL1: Probability - Cloud gaming: [0.04415229]01-01 14:57:41.807 947 1187 D SemNscXgbMsL1: Probability - Real time: [0.10864212]01-01 14:57:41.807 947 1187 D SemNscXgbMsL1: Probability - Non real time: [0.915227]01-01 14:57:41.807 947 1187 D SemNscXgbMsL1: 1 sample inference time: 0.716385 msecs01-01 14:57:41.809 947 1187 D SemNscXgbL2Rt: L2 RT 1 sample inference time: 1.699346 msecs01-01 14:57:41.810 947 1187 D SemNscXgbL2Nrt: L2 NRT 1 sample inference time: 0.882769 msecs01-01 14:57:42.247 16719 16855 I ReactNativeJS: 'Now connecting to peripheral with ID:', 'FE:EB:A9:02:1B:78'01-01 14:57:42.251 16719 16856 D ReactNativeBleManager: Disconnect from: FE:EB:A9:02:1B:7801-01 14:57:42.252 16719 16856 D ReactNativeBleManager: GATT is null01-01 14:57:42.254 16719 16855 I ReactNativeJS: Connecting to device FE:EB:A9:02:1B:78...01-01 14:57:42.258 16719 16856 D ReactNativeBleManager: Connect to: FE:EB:A9:02:1B:7801-01 14:57:42.258 16719 16856 D ReactNativeBleManager: connectGatt(activity, false, this, BluetoothDevice.TRANSPORT_LE, PhyRequest.PHY_LE_1M_MASK | PhyRequest.PHY_LE_2M_MASK | PhyRequest.PHY_LE_CODED_MASK, handler)01-01 14:57:42.259 16719 16856 I BluetoothAdapter: STATE_ON01-01 14:57:42.262 947 967 D BluetoothManagerService: mStateChangeCallbacks count 4901-01 14:57:42.262 16719 16856 D BluetoothGatt: connect() - device: FE:EB:A9:02:1B:78, auto: false01-01 14:57:42.262 16719 16856 I BluetoothAdapter: isSecureModeEnabled01-01 14:57:42.263 17562 17662 D BtConfig.SecureMode: isSecureModeOn:false01-01 14:57:42.264 16719 16856 D BluetoothGatt: registerApp()01-01 14:57:42.265 16719 16856 D BluetoothGatt: registerApp() - UUID=8eda2bf6-f3c2-4cfb-b90a-7375068e3e7201-01 14:57:42.269 17562 17662 D BtGatt.GattService: registerClient(com.mycompany.myapp) - UUID=8eda2bf6-f3c2-4cfb-b90a-7375068e3e7201-01 14:57:42.270 17562 17662 D BtGatt.ContextMap: add() - appUid: 10281, appPid: 16719, appName: com.mycompany.myapp01-01 14:57:42.271 17562 17593 D BtGatt.GattService: onClientRegistered() - UUID=8eda2bf6-f3c2-4cfb-b90a-7375068e3e72, clientIf=901-01 14:57:42.272 16719 17456 D BluetoothGatt: onClientRegistered() - status=0 clientIf=901-01 14:57:42.282 17562 17662 D BtGatt.GattService: clientConnect(com.mycompany.myapp) - address = FEEBA9_8, isDirect=true transport =2 set own addr = false own addr type:0, clientIf: 9, opportunistic=false, phy: 701-01 14:57:42.284 17562 17622 W bt_btm : BTM_SecAddBleDevice: dev_type=0x201-01 14:57:42.284 17562 17622 E bt_stack: [ERROR:gatt_api.cc(1237)] GATT_Connectgatt_if=9, address=fe:eb:a9:02:1b:78, is_direct=1, opportunistic=001-01 14:57:42.284 17562 17622 I bt_stack: [INFO:gatt_attr.cc(888)] gatt_sr_init_cl_status: bda=fe:eb:a9:02:1b:78, cl_supp_feat=0000, aware=101-01 14:57:42.284 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x1, to_resume = 101-01 14:57:42.312 947 1187 D SemNscXgbMsL1: Probability - Cloud gaming: [0.04415229]01-01 14:57:42.313 947 1187 D SemNscXgbMsL1: Probability - Real time: [0.10864212]01-01 14:57:42.313 947 1187 D SemNscXgbMsL1: Probability - Non real time: [0.915227]01-01 14:57:42.313 947 1187 D SemNscXgbMsL1: 1 sample inference time: 0.787077 msecs01-01 14:57:42.314 947 1187 D SemNscXgbL2Rt: L2 RT 1 sample inference time: 1.275885 msecs01-01 14:57:42.316 947 1187 D SemNscXgbL2Nrt: L2 NRT 1 sample inference time: 0.913692 msecs01-01 14:57:42.817 947 1187 D SemNscXgbMsL1: Probability - Cloud gaming: [0.04415229]01-01 14:57:42.818 947 1187 D SemNscXgbMsL1: Probability - Real time: [0.10864212]01-01 14:57:42.818 947 1187 D SemNscXgbMsL1: Probability - Non real time: [0.915227]01-01 14:57:42.818 947 1187 D SemNscXgbMsL1: 1 sample inference time: 0.672692 msecs01-01 14:57:42.820 947 1187 D SemNscXgbL2Rt: L2 RT 1 sample inference time: 1.471923 msecs01-01 14:57:42.821 947 1187 D SemNscXgbL2Nrt: L2 NRT 1 sample inference time: 0.964269 msecs01-01 14:57:43.081 947 1088 D InputReader: Btn_touch(8): value=1 when=60570.23678901-01 14:57:43.081 947 1088 I InputReader: Touch event's action is 0x0 (id=2, t=0) [pCnt=1, s=0.78 ] when=60570.23678901-01 14:57:43.081 947 1087 I InputDispatcher: Delivering touch to (1286): action: 0x4, f=0x0, d=0, 'e2f5469', t=1 01-01 14:57:43.081 947 1087 I InputDispatcher: Delivering touch to (16719): action: 0x0, f=0x0, d=0, '868231f', t=1 01-01 14:57:43.082 16719 16719 I [emailprotected][MainActivity]: ViewPostIme pointer 001-01 14:57:43.084 947 966 I GestureDetector: obtain mCurrentDownEvent. id: 711084446 caller: com.android.server.wm.SystemGesturesPointerEventListener.onPointerEvent:179 com.android.server.wm.PointerEventDispatcher.onInputEvent:71 android.view.InputEventReceiver.dispatchInputEvent:259 01-01 14:57:43.084 947 966 I GestureDetector: obtain mCurrentDownEvent. id: 711084446 caller: com.android.server.wm.SystemPerformancePointerEventListener.onPointerEvent:89 com.android.server.wm.PointerEventDispatcher.onInputEvent:71 android.view.InputEventReceiver.dispatchInputEvent:259 01-01 14:57:43.164 947 1088 D InputReader: Btn_touch(8): value=0 when=60570.32026901-01 14:57:43.165 947 1088 I InputReader: Touch event's action is 0x1 (id=2, t=0) [pCnt=1, s=] when=60570.32026901-01 14:57:43.165 947 1087 I InputDispatcher: Delivering touch to (16719): action: 0x1, f=0x0, d=0, '868231f', t=1 01-01 14:57:43.165 16719 16719 I [emailprotected][MainActivity]: ViewPostIme pointer 101-01 14:57:43.166 947 966 I GestureDetector: obtain mCurrentMotionEventRaw. action: 1 id: 33056095501-01 14:57:43.167 947 966 I GestureDetector: obtain mCurrentMotionEventRaw. action: 1 id: 33056095501-01 14:57:43.188 1231 1231 I wpa_supplicant: Heartbeat 604801-01 14:57:43.323 947 1187 D SemNscXgbMsL1: Probability - Cloud gaming: [0.04415229]01-01 14:57:43.323 947 1187 D SemNscXgbMsL1: Probability - Real time: [0.10864212]01-01 14:57:43.323 947 1187 D SemNscXgbMsL1: Probability - Non real time: [0.915227]01-01 14:57:43.323 947 1187 D SemNscXgbMsL1: 1 sample inference time: 0.4445 msecs01-01 14:57:43.324 947 1187 D SemNscXgbL2Rt: L2 RT 1 sample inference time: 0.812 msecs01-01 14:57:43.325 947 1187 D SemNscXgbL2Nrt: L2 NRT 1 sample inference time: 0.649077 msecs01-01 14:57:43.337 6239 6247 W earchbox:searc: Reducing the number of considered missed Gc histogram windows from 407 to 10001-01 14:57:43.384 947 966 I GestureDetector: handleMessage TAP01-01 14:57:43.385 947 947 I GestureDetector: handleMessage TAP01-01 14:57:43.827 947 1187 D SemNscXgbMsL1: Probability - Cloud gaming: [0.04415229]01-01 14:57:43.827 947 1187 D SemNscXgbMsL1: Probability - Real time: [0.10864212]01-01 14:57:43.827 947 1187 D SemNscXgbMsL1: Probability - Non real time: [0.915227]01-01 14:57:43.827 947 1187 D SemNscXgbMsL1: 1 sample inference time: 0.764115 msecs01-01 14:57:43.829 947 1187 D SemNscXgbL2Rt: L2 RT 1 sample inference time: 1.341962 msecs01-01 14:57:43.831 947 1187 D SemNscXgbL2Nrt: L2 NRT 1 sample inference time: 1.000961 msecs01-01 14:57:43.894 1973 21867 I NearbySharing: FastInitiation warming period has ended [CONTEXT service_id=194 ]01-01 14:57:44.297 947 1187 I SemWifiServiceDetector: Traff. tracking suspended01-01 14:57:44.508 1286 1286 D NetworkController.WifiSignalController: notifyListener: visible=true, enabled=true, connected=true, inetCondition=1, isDefault=true, receivedCR=true, receivedIC=-1, shouldForceHide=false, emptyConnected=false01-01 14:57:45.060 947 5816 D SamsungAlarmManager: Cancel Alarm calling from uid:10179 pid :2385 / OP:PendingIntent{ebd1fb9: PendingIntentRecord{71e256d com.google.android.gms/ startService}}01-01 14:57:45.071 947 1315 D SamsungAlarmManager: Cancel Alarm calling from uid:10179 pid :1973 / OP:PendingIntent{8470ffe: PendingIntentRecord{dad274a com.google.android.gms/ startService}}01-01 14:57:45.265 947 1148 D DeviceStorageMonitorService: check() STORAGE TOTAL > 64G01-01 14:57:45.266 947 1148 W DeviceStorageMonitorService: updateBroadcasts(/data) oldLevel:0, newLevel:0, seq:101-01 14:57:45.267 947 1148 D DeviceStorageMonitorService: Available File Node Number is [13493915]01-01 14:57:45.267 947 1148 W DeviceStorageMonitorService: updateBroadcasts_filenode(/data) fn_oldLevel:0, fn_newLevel:0, seq:101-01 14:57:45.407 947 1195 D WifiConnectivityMonitor: Stop WCM Poll. cnt : 501-01 14:57:45.427 16719 16749 D InputTransport: Input channel destroyed: 'ClientS', fd=15301-01 14:57:46.086 947 995 D PowerManagerService: UserActivityStateListenerState: 001-01 14:57:47.269 947 973 I ActivityManager: Changes in 10154 5 to 7, 8 to 001-01 14:57:47.275 947 966 D NetworkPolicy: onUidStateChanged() uid: 10154, isForeground(false, 7)01-01 14:57:47.275 17562 17562 D HidDeviceService: handleMessage(): msg.what=801-01 14:57:47.284 17562 17622 I bt_stack: [INFO:gatt_attr.cc(342)] gatt_connect_cback: remove untrusted client status, bda=fe:eb:a9:02:1b:7801-01 14:57:47.285 17562 17622 W bt_stack: [WARNING:bta_gattc_act.cc(384)] bta_gattc_open_fail: Cannot establish Connection. conn_id=000000. Return GATT_ERROR(133)01-01 14:57:47.288 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x1, to_resume = 101-01 14:57:47.289 17562 17593 D BtGatt.GattService: onConnected() - clientIf=9, connId=0, status=133, address=FEEBA9_801-01 14:57:47.290 16719 17456 D BluetoothGatt: onClientConnectionState() - status=133 clientIf=9 device=FE:EB:A9:02:1B:7801-01 14:57:47.296 16719 16719 D ReactNativeBleManager: onConnectionStateChange to 0 on peripheral: FE:EB:A9:02:1B:78 with status 13301-01 14:57:47.297 16719 16719 D BluetoothGatt: close()01-01 14:57:47.303 16719 16719 D BluetoothGatt: unregisterApp() - mClientIf=901-01 14:57:47.306 17562 17662 D BtGatt.GattService: unregisterClient(com.mycompany.myapp) - clientIf=901-01 14:57:47.307 17562 17662 D BtGatt.ContextMap: remove() - id: 901-01 14:57:47.308 17562 17662 E BtGatt.ContextMap: remove() - removed: 901-01 14:57:47.309 17562 17622 I bt_stack: [INFO:gatt_api.cc(1102)] GATT_Deregister gatt_if=901-01 14:57:47.309 17562 17622 I bt_stack: [INFO:gatt_api.cc(1155)] Initialize tGATT_REG01-01 14:57:47.309 16719 16719 D BluetoothGatt: cancelOpen() - device: FE:EB:A9:02:1B:7801-01 14:57:47.310 16719 16719 D BluetoothGatt: close()01-01 14:57:47.312 16719 16855 I ReactNativeJS: Attempt to connected 1 failed. "Connection error"01-01 14:57:47.315 16719 16719 D BluetoothGatt: unregisterApp() - mClientIf=001-01 14:57:47.316 16719 16856 D ReactNativeBleManager: Disconnect from: FE:EB:A9:02:1B:7801-01 14:57:47.316 16719 16856 D ReactNativeBleManager: GATT is null01-01 14:57:47.316 16719 16719 D ReactNativeBleManager: Peripheral event (BleManagerDisconnectPeripheral):FE:EB:A9:02:1B:7801-01 14:57:47.316 16719 16719 D ReactNativeBleManager: Disconnect01-01 14:57:47.519 16719 16855 I ReactNativeJS: Disconnected from FE:EB:A9:02:1B:7801-01 14:57:47.522 16719 16855 I ReactNativeJS: Connecting to device FE:EB:A9:02:1B:78...01-01 14:57:47.524 16719 16856 D ReactNativeBleManager: Connect to: FE:EB:A9:02:1B:7801-01 14:57:47.524 16719 16856 D ReactNativeBleManager: connectGatt(activity, false, this, BluetoothDevice.TRANSPORT_LE, PhyRequest.PHY_LE_1M_MASK | PhyRequest.PHY_LE_2M_MASK | PhyRequest.PHY_LE_CODED_MASK, handler)01-01 14:57:47.525 16719 16856 I BluetoothAdapter: STATE_ON01-01 14:57:47.527 947 967 D BluetoothManagerService: mStateChangeCallbacks count 4901-01 14:57:47.527 16719 16856 D BluetoothGatt: connect() - device: FE:EB:A9:02:1B:78, auto: false01-01 14:57:47.527 16719 16856 I BluetoothAdapter: isSecureModeEnabled01-01 14:57:47.527 17562 17662 D BtConfig.SecureMode: isSecureModeOn:false01-01 14:57:47.528 16719 16856 D BluetoothGatt: registerApp()01-01 14:57:47.528 16719 16856 D BluetoothGatt: registerApp() - UUID=f7f0b1e4-3bd2-4ee5-9745-57e7a11784ab01-01 14:57:47.530 17562 17662 D BtGatt.GattService: registerClient(com.mycompany.myapp) - UUID=f7f0b1e4-3bd2-4ee5-9745-57e7a11784ab01-01 14:57:47.532 17562 17662 D BtGatt.ContextMap: add() - appUid: 10281, appPid: 16719, appName: com.mycompany.myapp01-01 14:57:47.534 17562 17593 D BtGatt.GattService: onClientRegistered() - UUID=f7f0b1e4-3bd2-4ee5-9745-57e7a11784ab, clientIf=901-01 14:57:47.535 16719 17456 D BluetoothGatt: onClientRegistered() - status=0 clientIf=901-01 14:57:47.543 17562 17662 D BtGatt.GattService: clientConnect(com.mycompany.myapp) - address = FEEBA9_8, isDirect=true transport =2 set own addr = false own addr type:0, clientIf: 9, opportunistic=false, phy: 701-01 14:57:47.545 17562 17622 W bt_btm : BTM_SecAddBleDevice: dev_type=0x201-01 14:57:47.546 17562 17622 E bt_stack: [ERROR:gatt_api.cc(1237)] GATT_Connectgatt_if=9, address=fe:eb:a9:02:1b:78, is_direct=1, opportunistic=001-01 14:57:47.546 17562 17622 I bt_stack: [INFO:gatt_attr.cc(888)] gatt_sr_init_cl_status: bda=fe:eb:a9:02:1b:78, cl_supp_feat=0000, aware=101-01 14:57:47.546 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x1, to_resume = 101-01 14:57:49.057 366 366 D io_stats: [emailprotected] 179,0 r 546189 19124635 w 209753 4725824 d 29200 4696200 f 0 0 iot 248380 0 th 0 0 0 pt 0 inp 0 0 60576.21301-01 14:57:50.294 577 613 I SensorsHub: DeviceOrientation(0): event = 255, time = 6057744973809701-01 14:57:50.296 947 966 I WindowOrientationListener: OrientationSensorJudge.onSensorChanged, Rotation: -101-01 14:57:50.297 947 966 D WindowManager: rotationForOrientation, orientationSource=ActivityRecord{fe1f780 u0 com.mycompany.myapp/.MainActivity t61}01-01 14:57:50.343 947 1088 D InputReader: Btn_touch(8): value=1 when=60577.49821901-01 14:57:50.343 947 1088 I InputReader: Touch event's action is 0x0 (id=2, t=0) [pCnt=1, s=0.79 ] when=60577.49821901-01 14:57:50.343 947 1087 I InputDispatcher: Delivering touch to (1286): action: 0x4, f=0x0, d=0, 'e2f5469', t=1 01-01 14:57:50.344 947 1087 I InputDispatcher: Delivering touch to (16719): action: 0x0, f=0x0, d=0, '868231f', t=1 01-01 14:57:50.345 947 1087 D PowerManagerService: UserActivityStateListenerState: 101-01 14:57:50.345 947 966 I GestureDetector: obtain mCurrentDownEvent. id: 160040160 caller: com.android.server.wm.SystemGesturesPointerEventListener.onPointerEvent:179 com.android.server.wm.PointerEventDispatcher.onInputEvent:71 android.view.InputEventReceiver.dispatchInputEvent:259 01-01 14:57:50.345 16719 16719 I [emailprotected][MainActivity]: ViewPostIme pointer 001-01 14:57:50.346 947 966 I GestureDetector: obtain mCurrentDownEvent. id: 160040160 caller: com.android.server.wm.SystemPerformancePointerEventListener.onPointerEvent:89 com.android.server.wm.PointerEventDispatcher.onInputEvent:71 android.view.InputEventReceiver.dispatchInputEvent:259 01-01 14:57:50.351 947 966 I GestureDetector: obtain mCurrentMotionEventRaw. action: 2 id: 11800584801-01 14:57:50.351 947 966 I GestureDetector: obtain mCurrentMotionEventRaw. action: 2 id: 11800584801-01 14:57:50.727 1286 1516 D NetworkController: SignalStrength from intent slotId=001-01 14:57:50.728 1286 1516 D NetworkController.MobileSignalController(0/2147483647): new mSignalStrength=SignalStrength:{mCdma=Invalid,mGsm=Invalid,mWcdma=CellSignalStrengthWcdma: ss=-87 ber=99 rscp=-87 ecno=0 level=3,mTdscdma=Invalid,mLte=Invalid,mNr=Invalid,SignalBarInfo{ wcdmaLevel=4 },rat=3,primary=CellSignalStrengthWcdma}01-01 14:57:50.728 1286 1516 D NetworkController.MobileSignalController(0/2147483647): Display signal bar by emergency only[true][true]01-01 14:57:50.843 947 966 I GestureDetector: handleMessage LONG_PRESS01-01 14:57:50.843 947 947 I GestureDetector: handleMessage LONG_PRESS01-01 14:57:51.052 947 1087 D PowerManagerService: [api] userActivityFromNative : 10 (event: 2 flags: 0 displayId: 0) eventTime = 6057820701-01 14:57:51.419 947 1088 D InputReader: Btn_touch(8): value=0 when=60578.57460301-01 14:57:51.419 947 1088 I InputReader: Touch event's action is 0x1 (id=2, t=0) [pCnt=1, s=] when=60578.57460301-01 14:57:51.419 947 1087 I InputDispatcher: Delivering touch to (16719): action: 0x1, f=0x0, d=0, '868231f', t=1 01-01 14:57:51.422 16719 16719 I [emailprotected][MainActivity]: ViewPostIme pointer 101-01 14:57:52.547 17562 17622 I bt_stack: [INFO:gatt_attr.cc(342)] gatt_connect_cback: remove untrusted client status, bda=fe:eb:a9:02:1b:7801-01 14:57:52.547 17562 17622 W bt_stack: [WARNING:bta_gattc_act.cc(384)] bta_gattc_open_fail: Cannot establish Connection. conn_id=000000. Return GATT_ERROR(133)01-01 14:57:52.550 17562 17622 W bt_btm : btm_ble_disable_resolving_list() rl_state = 0x0, rl_mask = 0x1, to_resume = 101-01 14:57:52.553 17562 17593 D BtGatt.GattService: onConnected() - clientIf=9, connId=0, status=133, address=FEEBA9_801-01 14:57:52.555 16719 17338 D BluetoothGatt: onClientConnectionState() - status=133 clientIf=9 device=FE:EB:A9:02:1B:7801-01 14:57:52.564 16719 16719 D ReactNativeBleManager: onConnectionStateChange to 0 on peripheral: FE:EB:A9:02:1B:78 with status 13301-01 14:57:52.564 16719 16719 D BluetoothGatt: close()01-01 14:57:52.570 16719 16719 D BluetoothGatt: unregisterApp() - mClientIf=901-01 14:57:52.572 17562 17662 D BtGatt.GattService: unregisterClient(com.mycompany.myapp) - clientIf=901-01 14:57:52.575 17562 17662 D BtGatt.ContextMap: remove() - id: 901-01 14:57:52.575 17562 17662 E BtGatt.ContextMap: remove() - removed: 901-01 14:57:52.576 17562 17622 I bt_stack: [INFO:gatt_api.cc(1102)] GATT_Deregister gatt_if=901-01 14:57:52.576 17562 17622 I bt_stack: [INFO:gatt_api.cc(1155)] Initialize tGATT_REG01-01 14:57:52.577 16719 16719 D BluetoothGatt: cancelOpen() - device: FE:EB:A9:02:1B:7801-01 14:57:52.577 16719 16719 D BluetoothGatt: close()01-01 14:57:52.579 16719 16855 I ReactNativeJS: Attempt to connected 2 failed. "Connection error"01-01 14:57:52.581 16719 16856 D ReactNativeBleManager: Disconnect from: FE:EB:A9:02:1B:7801-01 14:57:52.581 16719 16856 D BluetoothGatt: cancelOpen() - device: FE:EB:A9:02:1B:7801-01 14:57:52.582 16719 16856 D BluetoothGatt: close()01-01 14:57:52.582 16719 16719 D BluetoothGatt: unregisterApp() - mClientIf=001-01 14:57:52.583 16719 16719 D ReactNativeBleManager: Peripheral event (BleManagerDisconnectPeripheral):FE:EB:A9:02:1B:7801-01 14:57:52.583 16719 16719 D ReactNativeBleManager: Disconnect01-01 14:57:52.588 16719 16856 D BluetoothGatt: unregisterApp() - mClientIf=001-01 14:57:52.590 16719 16856 D ReactNativeBleManager: Peripheral event (BleManagerDisconnectPeripheral):FE:EB:A9:02:1B:7801-01 14:57:52.590 16719 16856 D ReactNativeBleManager: Disconnect01-01 14:57:52.800 16719 16855 I ReactNativeJS: Disconnected from FE:EB:A9:02:1B:7801-01 14:57:53.050 16719 16855 I ReactNativeJS: Disconnected from FE:EB:A9:02:1B:7801-01 14:57:53.053 16719 16855 I ReactNativeJS: Connecting to device FE:EB:A9:02:1B:78...01-01 14:57:53.056 16719 16856 D ReactNativeBleManager: Connect to: FE:EB:A9:02:1B:7801-01 14:57:53.056 16719 16856 D ReactNativeBleManager: connectGatt(activity, false, this, BluetoothDevice.TRANSPORT_LE, PhyRequest.PHY_LE_1M_MASK | PhyRequest.PHY_LE_2M_MASK | PhyRequest.PHY_LE_CODED_MASK, handler)01-01 14:57:53.056 16719 16856 I BluetoothAdapter: STATE_ON01-01 14:57:53.058 947 967 D BluetoothManagerService: mStateChangeCallbacks count 4901-01 14:57:53.059 16719 16856 D BluetoothGatt: connect() - device: FE:EB:A9:02:1B:78, auto: false01-01 14:57:53.059 16719 16856 I BluetoothAdapter: isSecureModeEnabled01-01 14:57:53.059 17562 17662 D BtConfig.SecureMode: isSecureModeOn:false01-01 14:57:53.059 366 366 D io_stats: [emailprotected] 179,0 r 546193 19124655 w 209786 4726036 d 29200 4696200 f 0 0 iot 248388 0 th 0 0 0 pt 0 inp 0 0 60580.21501-01 14:57:53.059 16719 16856 D BluetoothGatt: registerApp()01-01 14:57:53.060 16719 16856 D BluetoothGatt: registerApp() - UUID=d740de82-1e75-4258-97e7-39b49f9d731901-01 14:57:53.062 17562 17662 D BtGatt.GattService: registerClient(com.mycompany.myapp) - UUID=d740de82-1e75-4258-97e7-39b49f9d731901-01 14:57:53.064 17562 17662 D BtGatt.ContextMap: add() - appUid: 10281, appPid: 16719, appName: com.mycompany.myapp01-01 14:57:53.065 17562 17593 D BtGatt.GattService: onClientRegistered() - UUID=d740de82-1e75-4258-97e7-39b49f9d7319, clientIf=901-01 14:57:53.066 16719 17338 D BluetoothGatt: onClientRegistered() - status=0 clientIf=901-01 14:57:53.075 17562 17662 D BtGatt.GattService: clientConnect(com.mycompany.myapp) - address = FEEBA9_8, isDirect=true transport =2 set own addr = false own addr type:0, clientIf: 9, opportunistic=false, phy: 701-01 14:57:53.077 17562 17622 W bt_btm : BTM_SecAddBleDevice: dev_type=0x201-01 14:57:53.077 17562 17622 E bt_stack: [ERROR:gatt_api.cc(1237)] GATT_Connectgatt_if=9, address=fe:eb:a9:02:1b:78, is_direct=1, opportunistic=001-01 14:57:53.077 17562 17622 I bt_stack: [INFO:gatt_attr.cc(888)] gatt_sr_init_cl_status: bda=fe:eb:a9:02:1b:78, cl_supp_feat=0000, aware=1
Thank you so much!