Add 10ms delay after closing relays

This commit is contained in:
jazzpi
2022-08-02 23:29:44 +02:00
parent 8b0ca85f3d
commit e3a226be54
2 changed files with 57 additions and 30 deletions

View File

@ -12,6 +12,7 @@
#include "stm32g441xx.h"
#include "stm32g4xx_hal.h"
#include "stm32g4xx_hal_gpio.h"
#define TS_INACTIVE 0
#define TS_PRECHARGE 2
@ -51,4 +52,8 @@ void AIR_Discharge_Position();
void AIR_Active_Position();
void AIR_Error_Position();
typedef enum { RELAY_AIR_NEG, RELAY_AIR_POS, RELAY_PRECHARGE } Relay;
void Set_Relay_Position(Relay relay, GPIO_PinState position);
#endif /* INC_AIR_STATE_MASCHINE_H_ */