From 1228063e1bb07c33b407b68cbb4e6a39e8a8e06d Mon Sep 17 00:00:00 2001 From: Jean-Francois Penven <67962328+jepenven-silabs@users.noreply.github.com> Date: Thu, 15 Dec 2022 16:15:51 +0100 Subject: [PATCH] Fix MLE Timeout (#23829) --- .../platform/silabs/efr32/project_include/OpenThreadConfig.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h b/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h index 76842d5783dbc1..c8f39692a69b0e 100644 --- a/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h +++ b/examples/platform/silabs/efr32/project_include/OpenThreadConfig.h @@ -39,7 +39,10 @@ #if CHIP_DEVICE_CONFIG_ENABLE_SED #define OPENTHREAD_CONFIG_PARENT_SEARCH_ENABLE 0 // In seconds -#define OPENTHREAD_CONFIG_MLE_CHILD_TIMEOUT_DEFAULT (SL_SLEEP_TIME_MS / 1000) +#define SL_MLE_TIMEOUT_seconds (SL_SLEEP_TIME_MS / 1000) + +// Timeout after 2 missed checkin or 4 mins if sleep interval is too short. +#define OPENTHREAD_CONFIG_MLE_CHILD_TIMEOUT_DEFAULT ((SL_MLE_TIMEOUT_seconds < 120) ? 240 : ((SL_MLE_TIMEOUT_seconds * 2) + 1)) #endif /****Uncomment below section for OpenThread Debug logs*/