diff --git a/Core/Src/CAN_Communication.c b/Core/Src/CAN_Communication.c index cb1a4ed..204e2a4 100644 --- a/Core/Src/CAN_Communication.c +++ b/Core/Src/CAN_Communication.c @@ -185,9 +185,9 @@ void HAL_FDCAN_ErrorCallback(FDCAN_HandleTypeDef* hcan) {} void CAN_SendAbxStatus(FDCAN_HandleTypeDef* hcan) { uint8_t buffer[4]; buffer[0] = ctrltsstate.currentTSState | (1 << 7); - buffer[1] = 160; - buffer[2] = (uint8_t)(shuntvoltage1 / 2000); - buffer[3] = current_soc; + buffer[1] = current_soc; + buffer[2] = (uint8_t)(min_voltage >> 8); + buffer[3] = (int8_t)(max_temp >> 4); CAN_Transmit(hcan, AMS_STATUS_ID, buffer, 4); }