-
Notifications
You must be signed in to change notification settings - Fork 588
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
when unsubscribe during long-write, long-write doesn't "finish" and disconnect never "started" #218
Comments
Thanks for the quickness Darius! Let me know if I can provide details or help provide more specific code to reproduce. |
I will create a fix tomorrow and I will ask you to test it. ;) |
This is now fixed and should be available shortly in |
This is actually a more general problem with unsubscribing from operations while they were running. Should be fixed now but it may use a refactor later on. Please test it and share if it helped. Best Regards |
Thanks very much! I'll update now and let you know what I see. Great work! |
Hello! I have been noticing that if "unsubscribe" is called when a write is ongoing, or a subscribe to change is subscribing, the queued "Disconnect" is not finished. In my case I am noticing it during a long-write. My application is observing a characteristic-change for response, and long-writing. Here is an example of a "unsubscribe" while long-write
So i start off with "RxBleRadioOperationDescriptorWrite(85537306)" is ongoing, but now it is finished. The long write starts, the disconnect is queued, the long write is disabled but the disconnect never starts. I can see my BLE device says I'm still connected, but subsequent attempts to scan for devices never actually "start". It requires an app reboot then the state is back to normal.
I was seeing the same behaviour when I was waiting for
connection.setupNotification(characteristic)
or waiting for a normal (small) write, but this is a shorter window and probably harder to hit unsubscribe during.So as far as steps to reproduce go, I'd say try unsubscribe mid a very "long" write. I do not have an ack strategy (do I need one?). Thanks for your time.
The text was updated successfully, but these errors were encountered: