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

fix: ble central requires a timeout when tries to start a connection #420

Merged
merged 24 commits into from
Oct 28, 2024

Conversation

gabrielsantosphilips
Copy link
Contributor

@gabrielsantosphilips gabrielsantosphilips commented Oct 4, 2024

This PR addresses the fix introduced in amp-embedded-infra: philips-software/amp-embedded-infra-lib#723

The main idea is to not delegate the timeout management to the application for detecting failures. Instead, we will handle this internally, as users may not be aware of how long it takes for a connection to be established.

Below is a sequence diagram illustrating the proposed solution:

image

Also small improvements are being added by this PR.

Copy link
Contributor

github-actions bot commented Oct 4, 2024

🦙 MegaLinter status: ⚠️ WARNING

Descriptor Linter Files Fixed Errors Elapsed time
✅ ACTION actionlint 6 0 0.03s
✅ CPP clang-format 14 3 0 1.36s
✅ DOCKERFILE hadolint 1 0 0.09s
✅ JSON jsonlint 7 0 0.14s
✅ JSON prettier 7 2 0 1.85s
⚠️ MARKDOWN markdownlint 6 1 7 2.15s
⚠️ MARKDOWN markdown-link-check 6 2 49.35s
✅ MARKDOWN markdown-table-formatter 6 1 0 1.29s
✅ REPOSITORY checkov yes no 28.62s
✅ REPOSITORY git_diff yes no 0.67s
✅ REPOSITORY grype yes no 22.86s
✅ REPOSITORY ls-lint yes no 0.07s
✅ REPOSITORY secretlint yes no 54.53s
✅ REPOSITORY trivy yes no 23.42s
✅ REPOSITORY trivy-sbom yes no 0.12s
✅ REPOSITORY trufflehog yes no 9.41s
⚠️ SPELL lychee 32 1 72.71s
✅ YAML prettier 9 1 0 1.95s
✅ YAML v8r 9 0 6.23s
✅ YAML yamllint 9 0 0.24s

See detailed report in MegaLinter reports

MegaLinter is graciously provided by OX Security

@gabrielsantosphilips gabrielsantosphilips marked this pull request as ready for review October 22, 2024 15:27
@gabrielsantosphilips gabrielsantosphilips requested a review from a team as a code owner October 22, 2024 15:27
hal_st/middlewares/ble_middleware/GapCentralSt.cpp Outdated Show resolved Hide resolved
hal_st/middlewares/ble_middleware/GapCentralSt.cpp Outdated Show resolved Hide resolved
hal_st/middlewares/ble_middleware/GapCentralSt.cpp Outdated Show resolved Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@gabrielsantosphilips gabrielsantosphilips merged commit bb209a3 into main Oct 28, 2024
25 checks passed
@gabrielsantosphilips gabrielsantosphilips deleted the feature/fix-ble-central-connection branch October 28, 2024 07:57
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

Successfully merging this pull request may close these issues.

3 participants