Open david-gettins opened 9 months ago
Do you have any logs from the log(...)
method?
Unfortunately not. I am unable to reproduce it now. It only happened the first time I connected the peripherals to v2.7.2
after upgrading from v2.6.1
. Like I said in the issue description, our peripherals were updated using a different device (i.e. not DFU on the phone), so I am investigating with our hardware team too.
After updating to
v2.7.2
of the library, I started noticingonServicesInvalidated
being called after connection and initialisation. This caused errors in our logic due to the collection of gatt services being emptied in theonServicesInvalidated
override.The peripheral in question had a firmware update by our hardware team using nRF Connect. Could this be the cause? Or is something else going on? The firmware update did not change any of the GATT services or characteristics available on the peripheral.
This has identified issues in our logic. We should re-discover services after they have been invalidated to resolve it. Am I correct that would be a sensible course of action after
onServicesInvalidated
is called?Apologies there are a few questions in there...