BMS Module

Source: docs.foxbms.org — BMS Files: src/app/application/bms/bms.c, bms.h, bms_cfg.h


State Machine

Main states (from CAN 0x220 BmsState field):

State Value Description
STANDBY 5 All contactors open, no current flow
PRECHARGE 6 Precharge contactor closed, waiting for voltage match
NORMAL 7 All contactors closed, current allowed
ERROR 9 Safety-triggered, contactors forced open

State Transitions

Error Handling

Overcurrent Protection

Special handling: when disconnecting under overcurrent, BMS waits for the fuse to trigger and current to interrupt before opening contactors. This prevents contactor welding from breaking current exceeding the contactor's maximum breaking rating.

POSIX Port Impact