From 62d78af1f85b306bdd22a4c9fced2a846e92a0da Mon Sep 17 00:00:00 2001 From: Mika Cohen Date: Mon, 29 Jun 2026 14:41:52 -0600 Subject: [PATCH] Suppress placeholder BMS faults during startup grace --- src/bms.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/bms.c b/src/bms.c index acf08e45..571907c0 100644 --- a/src/bms.c +++ b/src/bms.c @@ -44,9 +44,11 @@ void bms_update(BMS *bms, const CfgBMS *cfg, const Time *time) { const float timeout = 5.0f; // Before the first BMS update occurs right after startup, msg_age has its - // init value. We need to wait the `timeout` time before issuing errors. - if (bms->msg_age > timeout && time_elapsed(time, start, timeout)) { - set_fault(&fault_mask, BMSF_CONNECTION); + // init value. Suppress all telemetry faults until the grace period expires. + if (bms->msg_age > timeout) { + if (time_elapsed(time, start, timeout)) { + set_fault(&fault_mask, BMSF_CONNECTION); + } bms->fault_mask = fault_mask; return; }