How damienmaguire/stm32-vcu works
ZombieVerter is STM32 firmware for a configurable electric-vehicle conversion VCU. The principal workflow is vehicle signals and driver inputs entering the firmware, which manages drive/precharge behavior and communicates with selected drivetrain, charging, battery, and vehicle systems. The repository supports many interchangeable vehicle-specific implementations; the README documents these capabilities, while only a subset of runtime wiring is visible in the excerpts. Dashed links mark those documented or likely integrations whose exact dispatch is not shown.
Main entry points: stm32_vcu.cpp VCU Main Loop · CANSPI.cpp CAN Interface · throttle.cpp Throttle Control · iomatrix.cpp I/O Mapping
Components 18
VCU Runtime
- VCU Main Loop
src/stm32_vcu.cpp
Control Inputs
- Throttle Control
src/throttle.cpp - I/O Mapping
src/iomatrix.cpp - Temperature Sensing
src/temp_meas.cpp
Vehicle And Drive
- Vehicle Adapters
src/BMW_E39.cpp - Toyota Hybrid Drive
src/GS450H.cpp - Leaf Inverter
src/leafinv.cpp - Outlander Drive
src/outlanderinverter.cpp
Energy Systems
- Battery / BMS
src/leafbms.cpp - Charger Control
src/charger.cpp - CHAdeMO Charging
src/chademo.cpp - CCS Charging
src/i3LIM.cpp - FOCCCI Charging
src/Foccci.cpp
Hardware And CAN
- CAN Interface
src/CANSPI.cpp - MCP2515 Driver
src/MCP2515.cpp - Hardware Initialization
src/hwinit.cpp - ISA Shunt
src/isa_shunt.cpp
Other components
- Driver / Vehicle
Connections 17
- Driver / Vehicle → VCU Main Loop: provides inputs
- VCU Main Loop → Throttle Control: runs control
- VCU Main Loop → I/O Mapping: reads and sets I/O
- VCU Main Loop → Temperature Sensing: uses sensing
- VCU Main Loop → Vehicle Adapters: selects vehicle
- VCU Main Loop → Toyota Hybrid Drive: controls drivetrain
- VCU Main Loop → Leaf Inverter: supports drivetrain
- VCU Main Loop → Outlander Drive: supports drivetrain
- VCU Main Loop → Battery / BMS: supports battery
- VCU Main Loop → Charger Control: manages charging
- VCU Main Loop → CHAdeMO Charging: supports fast charge
- VCU Main Loop → CCS Charging: supports fast charge
- VCU Main Loop → FOCCCI Charging: supports fast charge
- VCU Main Loop → CAN Interface: initializes CAN
- CAN Interface → MCP2515 Driver: uses controller
src/CANSPI.cpp - VCU Main Loop → Hardware Initialization: initializes hardware
src/stm32_vcu.cpp - VCU Main Loop → ISA Shunt: initializes shunt
src/stm32_vcu.cpp