TactilityKernel improvements and more (#459)

This commit is contained in:
Ken Van Hoeylandt
2026-01-25 23:54:33 +01:00
committed by GitHub
parent 96eccbdc8d
commit dfe2c865d1
36 changed files with 759 additions and 331 deletions
@@ -67,6 +67,7 @@ public:
}
if (shutdown) {
mutex.unlock();
return false;
}
@@ -86,14 +87,14 @@ public:
}
/**
* Consume 1 or more dispatched function (if any) until the queue is empty.
* Consume 1 or more dispatched functions (if any) until the queue is empty.
* @warning The timeout is only the wait time before consuming the message! It is not a limit to the total execution time when calling this method.
* @param[in] timeout the ticks to wait for a message
* @return the amount of messages that were consumed
*/
uint32_t consume(TickType_t timeout = kernel::MAX_TICKS) {
// Wait for signal
if (!eventFlag.wait(WAIT_FLAG, false, true, timeout)) {
if (!eventFlag.wait(WAIT_FLAG, false, true, nullptr, timeout)) {
return 0;
}