From 4896d6b1a1f519972113fdb3d8aeb62542777543 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Nie=C3=9Fen?= Date: Thu, 11 Nov 2021 02:39:01 +0100 Subject: [PATCH] Mention portMAX_DELAY in xEventGroupWaitBits docs (#411) The public function xEventGroupWaitBits passes xTicksToWait to the function vTaskPlaceOnUnorderedEventList, which passes the number of ticks to prvAddCurrentTaskToDelayedList and sets xCanBlockIndefinitely to pdTRUE, causing the latter to block indefinitely if xTicksToWait == portMAX_DELAY and INCLUDE_vTaskSuspend == 1. --- include/event_groups.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/event_groups.h b/include/event_groups.h index dd2fda87c..6807002eb 100644 --- a/include/event_groups.h +++ b/include/event_groups.h @@ -243,7 +243,8 @@ typedef TickType_t EventBits_t; * * @param xTicksToWait The maximum amount of time (specified in 'ticks') to wait * for one/all (depending on the xWaitForAllBits value) of the bits specified by - * uxBitsToWaitFor to become set. + * uxBitsToWaitFor to become set. A value of portMAX_DELAY can be used to block + * indefinitely (provided INCLUDE_vTaskSuspend is set to 1 in FreeRTOSConfig.h). * * @return The value of the event group at the time either the bits being waited * for became set, or the block time expired. Test the return value to know