From 7de46b8160daa3c808779b3b9af262eaaf820f01 Mon Sep 17 00:00:00 2001 From: Bastian de Byl Date: Fri, 8 May 2026 18:54:54 -0400 Subject: [PATCH] =?UTF-8?q?fix:=20move=20SKUDAK=20telemetry=20frame=20from?= =?UTF-8?q?=200x210=20=E2=86=92=200x211=20(avoid=20bus=20contention)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bench capture on the green car showed a non-Polarity module also broadcasting at 0x210 (DLC=8 frame with mostly-zero payload, byte 5 = 0x85 static — likely a Tesla OEM DI module). Even after a clean reflash + 'can c' to clear persisted maps, the rogue 0x210 frame keeps appearing on the wire, racing our intended frame and intermittently corrupting the VCU's read. Confirmed via 'can p' on the OBC that this firmware's CanMap has exactly one 0x210 entry with the 5 expected fields — the conflict is external. Moves all five AddSends to 0x211, an adjacent free ID. The VCU's CHARGER_CAN_ID_OI_OBC_AUX constant is updated to match in a paired stm32-hal-vcu PR. Same 7-byte expanded layout (state/udc/idc/uaux@5/soc), same 100ms cadence — only the arbitration ID changes. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/chargercan.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/chargercan.cpp b/src/chargercan.cpp index eed043d..f289c29 100644 --- a/src/chargercan.cpp +++ b/src/chargercan.cpp @@ -100,7 +100,7 @@ void ChargerCAN::MapMessages(CanMap* can) can->AddSend(Param::idc, 0x109, 24, 16, 1); can->AddSend(Param::opmode, 0x109, 40, 3, 5); //Set charging and connlock at once - /***** SKUDAK VCU telemetry (0x210) — SKUDAK-448 expanded charger telemetry *****/ + /***** SKUDAK VCU telemetry (0x211) — SKUDAK-448 expanded charger telemetry *****/ // Byte 0: state (0=Off, 1=WaitStart, 2=Enable, 3=Activate, 4=Run, 5=Stop) // Bytes 1-2: udc (V, gain=1) // Bytes 3-4: idc (0.1A, gain=10) @@ -108,9 +108,9 @@ void ChargerCAN::MapMessages(CanMap* can) // Byte 6: soc (%, gain=1) // Byte 7: reserved // Consumed by stm32-hal-vcu Core/Src/main.c CHARGER_CAN_ID_OI_OBC_AUX handler. - can->AddSend(Param::state, 0x210, 0, 8, 1); - can->AddSend(Param::udc, 0x210, 8, 16, 1); - can->AddSend(Param::idc, 0x210, 24, 16, 10); - can->AddSend(Param::uaux, 0x210, 40, 8, 10); - can->AddSend(Param::soc, 0x210, 48, 8, 1); + can->AddSend(Param::state, 0x211, 0, 8, 1); + can->AddSend(Param::udc, 0x211, 8, 16, 1); + can->AddSend(Param::idc, 0x211, 24, 16, 10); + can->AddSend(Param::uaux, 0x211, 40, 8, 10); + can->AddSend(Param::soc, 0x211, 48, 8, 1); }