From a3606672d15bc16667efa0058761d07b28c46741 Mon Sep 17 00:00:00 2001 From: Koen Dergent Date: Tue, 16 Feb 2021 10:01:16 +0100 Subject: [PATCH] only use time producer fields when enabled --- 301/CO_TIME.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/301/CO_TIME.h b/301/CO_TIME.h index 97176be..a68c032 100644 --- a/301/CO_TIME.h +++ b/301/CO_TIME.h @@ -181,7 +181,9 @@ static inline void CO_TIME_set(CO_TIME_t *TIME, TIME->residual_us = 0; TIME->ms = ms; TIME->days = days; +#if ((CO_CONFIG_TIME) & CO_CONFIG_TIME_PRODUCER) TIME->producerTimer_ms = TIME->producerInterval_ms =producerInterval_ms; +#endif } }