This commit is contained in:
hamza
2024-07-07 21:16:36 +03:00
parent 5a84a349d9
commit b5410639eb
9 changed files with 34 additions and 22 deletions

View File

@ -25,6 +25,8 @@
#define MAX_CHARGING_CHECK_DURATION 2000 // ms
// Time to wait between closing relays
#define RELAY_CLOSE_WAIT 10 // ms
// Max time to wait for CAN messages. If we reach it then we emergency shutdown.
#define CAN_TIMEOUT 100000
typedef enum { // states -> 3 bit. valid transitions: (all could transition to error)
STATE_INACTIVE, // INACTIVE -> PRECHARGE, CHARGING, ERROR