From a9cfa7bc5e0a129d63ca5dc6261e5bb7fcd7178b Mon Sep 17 00:00:00 2001 From: Oliver Walter Date: Tue, 30 Apr 2024 02:37:16 +0200 Subject: [PATCH] add gCLS_DEVICE_ADDRESS to the HB interval to avoid collisons --- CLS.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CLS.c b/CLS.c index 05cf780..1b3777d 100644 --- a/CLS.c +++ b/CLS.c @@ -38,7 +38,8 @@ void CLS_Init(void) { CLS_HeatbeatTimerId = osTimerNew((osTimerFunc_t)CLS_Heatbeat, osTimerPeriodic, NULL, &timerAttr); if (CLS_HeatbeatTimerId != NULL) { // Timer object created - if (osTimerStart(CLS_HeatbeatTimerId, CLS_HEARTBEAT_INTERVAL_MS) == osOK) { // Timer started + // add gCLS_DEVICE_ADDRESS to the interval to avoid collisons + if (osTimerStart(CLS_HeatbeatTimerId, CLS_HEARTBEAT_INTERVAL_MS + gCLS_DEVICE_ADDRESS) == osOK) { // Timer started // Timer started successfully } }