Skip to content

Conversation

@h2zero
Copy link
Owner

@h2zero h2zero commented Nov 13, 2024

Instead of incrementing the notificatin value via xTaskNotifyGive this will now set a specific bit in the task notification value
which will be tested before blocking a task. This will prevent a task from blocking indefinitely if the event that calls taskRelease
occurs before entering the blocked state.

  • Adds a config setting for the bit to set in the task notification value.

Refactor NimBLEClient::connect and NimBLEClient::secureConnection.

This change ensures that only the function that sets m_pTaskData clears it, potentially preventing a segmentation fault.

  • Client will no longer disconnect if task timeout occurs when waiting for MTU exchange response.

Fixes #222

…cking.

Instead of incrementing the notificatin value via `xTaskNotifyGive` this will now set a specific bit in the task notification value
which will be tested before blocking a task. This will prevent a task from blocking indefinitely if the event that calls `taskRelease`
occurs before entering the blocked state.

* Adds a config setting for the bit to set in the task notification value.
* Create destructor for NimBLETaskData to delete semaphore if created.
This change ensures that only the function that sets `m_pTaskData` clears it, potentially preventing a segmentation fault.

* Client will no longer disconnect if task timeout occurs when waiting for MTU exchange response.
@h2zero h2zero merged commit a59e8ee into master Nov 14, 2024
94 checks passed
@h2zero h2zero deleted the fix-task-blocking branch November 14, 2024 17:45
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.

Allow task blocking duration to be configured

2 participants