polarofficial / polar-ble-sdk

Repository includes SDK and code examples. More info https://polar.com/en/developers
Other
488 stars 155 forks source link

Unable to connect #464

Open Pavan-Bellam opened 5 months ago

Pavan-Bellam commented 5 months ago

Platform your question concerns:

Device:

Description: Sure, here's a formatted issue report for GitHub, including the provided logs and a description of the problem:


Issue: Unable to Connect to Device via Bluetooth

Description

I am experiencing an issue where the example application is unable to connect to a Bluetooth device. The connection process starts but fails shortly after, resulting in a disconnection. The logs indicate that the device is not bonded and there are issues retrieving device information.

Logs

2024-06-03 19:17:22.634 16339-4991  NearbyMediums           com.google.android.gms.persistent    I  Found Fast Ble Advertisements :
                                                                                                    BleAdvertisement { version=2, socketVersion=2, isFast=true, serviceIdHash=null, data=[ 0x23 0x49 0x36 0x34 0x41 0x11 0x32 0xe3 0xa3 0x9a 0xba 0xcf 0x16 0x88 0xa7 0xbf 0x6a 0x21 0xd4 0xbf 0xa9 0xcf 0xc9 ], deviceToken=[ 0x43 0x5b ], rxAdvertisement=null } : 1 times.
                                                                                                    Total 1 fast advertisements.
2024-06-03 19:17:22.637 16339-3847  NearbyConnections       com.google.android.gms.persistent    I  Processing lost BlePeripheral BlePeripheral{advertisement=BleAdvertisement { version=2, socketVersion=2, isFast=true, serviceIdHash=null, data=[ 0x23 0x46 0x52 0x43 0x42 0x11 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ], deviceToken=[ 0x88 0x37 ], rxAdvertisement=null }, address=null, psm=0, deviceToken=<ByteString@39ec218 size=2 contents="\2107">, isSecondProfile=false, rxInstantConnectionAdv=null}.
2024-06-03 19:17:22.637 16339-3847  NearbyConnections       com.google.android.gms.persistent    I  Lost BleEndpoint for BlePeripheral BlePeripheral{advertisement=BleAdvertisement { version=2, socketVersion=2, isFast=true, serviceIdHash=null, data=[ 0x23 0x46 0x52 0x43 0x42 0x11 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ], deviceToken=[ 0x88 0x37 ], rxAdvertisement=null }, address=null, psm=0, deviceToken=<ByteString@39ec218 size=2 contents="\2107">, isSecondProfile=false, rxInstantConnectionAdv=null} (with EndpointId FRCB and EndpointInfo [ 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ]).
2024-06-03 19:17:22.641 16339-4992  NearbySharing           com.google.android.gms.persistent    I  (REDACTED) Ignoring lost endpoint %s because we don't have an associated ShareTarget
2024-06-03 19:17:22.642 16339-4991  NearbySharing           com.google.android.gms.persistent    I  (REDACTED) Endpoint %s lost over Nearby Connections
2024-06-03 19:17:22.643 16339-3847  NearbyConnections       com.google.android.gms.persistent    I  ClientProxy(29104412) reporting onEndpointLost(FRCB)
2024-06-03 19:17:24.277 16339-4991  NearbyConnections       com.google.android.gms.persistent    I  Found BleAdvertisement [ 0x23 0x46 0x52 0x43 0x42 0x11 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ] (with EndpointId FRCB and EndpointInfo [ 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ])
2024-06-03 19:17:24.281 16339-4991  NearbyConnections       com.google.android.gms.persistent    I  ClientProxy(29104412) reporting onEndpointFound(FRCB)
2024-06-03 19:17:24.282 16339-4991  NearbyConnections       com.google.android.gms.persistent    I  ClientProxy(29104412) reporting onEndpointDistanceChanged(FRCB, UNKNOWN)
2024-06-03 19:17:24.283 16339-4991  NearbyConnections       com.google.android.gms.persistent    I  No Bluetooth Classic MAC address found in [ 0x23 0x46 0x52 0x43 0x42 0x11 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ]
2024-06-03 19:17:24.284 16339-3847  NearbySharing           com.google.android.gms.persistent    I  (REDACTED) Endpoint %s discovered over Nearby Connections
2024-06-03 19:17:24.294 16339-4992  NearbySharing           com.google.android.gms.persistent    I  (REDACTED) Failed to convert given advertisement (%s)%s to share target from discovered advertisement. Ignoring.
2024-06-03 19:17:24.295 16339-4992  NearbySharing           com.google.android.gms.persistent    I  (REDACTED) Report endpoint %s as lost, since we cannot recognize this endpoint anymore
2024-06-03 19:17:24.296 16339-4992  NearbySharing           com.google.android.gms.persistent    I  (REDACTED) Ignoring lost endpoint %s because we don't have an associated ShareTarget
2024-06-03 19:17:27.639 16339-4992  NearbyMediums           com.google.android.gms.persistent    I  Found Fast Ble Advertisements :
                                                                                                    BleAdvertisement { version=2, socketVersion=2, isFast=true, serviceIdHash=null, data=[ 0x23 0x46 0x52 0x43 0x42 0x11 0x32 0xa6 0x09 0x88 0x0e 0x95 0x64 0xac 0xac 0x03 0x3a 0x10 0x17 0x50 0xed 0xaf 0x19 ], deviceToken=[ 0x88 0x37 ], rxAdvertisement=null } : 1 times.
                                                                                                    BleAdvertisement { version=2, socketVersion=2, isFast=true, serviceIdHash=null, data=[ 0x23 0x49 0x36 0x34 0x41 0x11 0x32 0xe3 0xa3 0x9a 0xba 0xcf 0x16 0x88 0xa7 0xbf 0x6a 0x21 0xd4 0xbf 0xa9 0xcf 0xc9 ], deviceToken=[ 0x43 0x5b ], rxAdvertisement=null } : 1 times.
                                                                                                    Total 2 fast advertisements.
2024-06-03 19:17:29.617  4640-4640  MainActivity            com.polar.androidblesdk              D  DISCONNECTED: 83E7B82B