Skip to content
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

Suspending connect() can't be cancelled without gatt reference #135

Open
0x7061 opened this issue Mar 25, 2024 · 0 comments
Open

Suspending connect() can't be cancelled without gatt reference #135

0x7061 opened this issue Mar 25, 2024 · 0 comments

Comments

@0x7061
Copy link

0x7061 commented Mar 25, 2024

I'm using autoconnect=true and a clientside timeout of 15sec. The connect() method is suspending and returns the gatt instance only when a connection has been established. Without the gatt reference, however, I can't properly close the gatt in case of a timeout. The HCI interface seems to keep trying to connect in the background. My gut tells me the .waitForConnection() should be decoupled from the ClientBleGatt.connect() and instead the API user should call it when necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant