Open Cheryet opened 10 months ago
I've updated to 3.1.2 in hopes it would fix this issue as it was in the patch notes.
This is also still happening to me, despite the issue being resolved in that release.
How long have you been waiting for this event? If the connection is lost from the BLE device, the phone BT module usually tries to re-establish the connection itself and there may be a delay between the device turning off and the information that it has been disconnected.
How long have you been waiting for this event?
Well, I am not receiving the event during the tens of minutes I may set the phone down after testing.
The fact it's not happening in the same time frame as the iOS disconnect is suggesting it's not going to happen at all.
How long have you been waiting for this event?
Similar here, Not receiving the event during the 10+ minuets after a disconnection has been made.
Prerequisites
Expected Behavior
When a device is disconnected from BLE, The OnDisconnected() callback reports an error related to disconnection. When a disconnection is successful via a call to bleManager.cancelDeviceConnection() no error should be shown. When a connection is lost, an error should be reported.
Current Behavior
While setting up my disconnection handler I am never seeing an error for device.OnDisconnected() or manager.onDeviceDisconnected(DeviceId). Although the callback gets called, the Error parameter is always null in my case. This happens on IOS and Android
Library version
3.1.2-rc.0
Device
IPhone 14 (IOS 17.2), Samsung Galaxy S8 (Android 9)
Environment info
Steps to reproduce
Formatted code sample or link to a repository
Relevant log output
Additional information
I have tried multiple versions of BLE PLX to attempt to fix this issue. Down graded to 2.x.x as well as tried some patch versions from similar issues (OnDisconnect() event not firing). To try and get an error I've disconnected power to the BLE device but error still returned as null.
The reason for needing this Error code is to determine if a reconnection should happen on devices that have lost a connection. If a device is disconnected by using the function, no reconnection is required.