Clear characteristic cccd value when disconnect#376
Merged
pennam merged 1 commit intoarduino-libraries:masterfrom Apr 10, 2025
Merged
Clear characteristic cccd value when disconnect#376pennam merged 1 commit intoarduino-libraries:masterfrom
pennam merged 1 commit intoarduino-libraries:masterfrom
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
Contributor
|
Hi @fabik111. Thanks for your pull request. Please disregard the failed spell check. This is a spurious failure caused by bit rot in the antiquated infrastructure used for that check, nothing to do with the changes you propose here. The failed check won't block the reviewers from merging your PR and we'll be sure to fix the broken spell check system separately ASAP. |
d909b6c to
2355c4d
Compare
This comment was marked as outdated.
This comment was marked as outdated.
2355c4d to
67d0048
Compare
This comment was marked as outdated.
This comment was marked as outdated.
andreagilardoni
approved these changes
Apr 8, 2025
facchinm
approved these changes
Apr 8, 2025
67d0048 to
80036ba
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #376 +/- ##
=========================================
- Coverage 9.62% 9.60% -0.03%
=========================================
Files 28 28
Lines 3656 3665 +9
=========================================
Hits 352 352
- Misses 3304 3313 +9 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
If the peripheral sketch with a subscribeable characteristic closes the connection with the central calling the
BLE.disconnect()all subsequent subscriptions, after the first connection, are not notified and the characteristic stays always as "subscribed".Solution
In this PR the characteristic CCCD value is cleared when the BLE.disconnect() is called for resetting the characteristic subscription status and allowing new subscriptions.
Sketches for reproducing the problem
Central
Peripheral
Logs
Here the logs of the current behaviour.
Central
Peripheral