2022-07-03 17:33:09 +02:00
|
|
|
/*
|
|
|
|
* Check_Shunt_Limits.c
|
|
|
|
*
|
|
|
|
* Created on: Jun 16, 2022
|
|
|
|
* Author: max
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "Check_Shunt_Limits.h"
|
|
|
|
|
|
|
|
void CheckShuntLimits() {
|
2022-07-25 18:48:26 +02:00
|
|
|
uint32_t now = HAL_GetTick();
|
|
|
|
if (((shuntlastmessage + SHUNT_TIMEOUT) < now) && (now > 2000)) {
|
|
|
|
AMS_Error_Handler(AMS_ERRORCODE_TIMEOUT_SHUNT, 0, NULL);
|
2022-07-03 17:33:09 +02:00
|
|
|
}
|
|
|
|
/*if(shuntcurrent > SHUNT_OVERCURRENT)
|
|
|
|
{
|
|
|
|
AMS_Error_Handler(0x07);
|
|
|
|
}
|
|
|
|
if(shuntbusbartemp > SHUNT_OVERTEMP)
|
|
|
|
{
|
|
|
|
AMS_Error_Handler(0x08);
|
|
|
|
}*/
|
|
|
|
}
|