89 int16_t packMaximumVoltage_mV = INT16_MIN;
90 int16_t packMinimumVoltage_mV = INT16_MAX;
91 int16_t packMaximumTemperature_ddegC = INT16_MIN;
92 int16_t packMinimumTemperature_ddegC = INT16_MAX;
132 float signalData = (float)packMinimumVoltage_mV;
135 signalData = (signalData + offset) * factor;
136 uint64_t data = (int64_t)signalData;
141 signalData = (float)packMaximumVoltage_mV;
144 signalData = (signalData + offset) * factor;
145 data = (int64_t)signalData;
150 signalData = (float)packMinimumTemperature_ddegC;
153 signalData = (signalData + offset) * factor;
154 data = (int64_t)signalData;
159 signalData = (float)packMaximumTemperature_ddegC;
162 signalData = (signalData + offset) * factor;
163 data = (int64_t)signalData;
187 uint64_t message = 0u;
192 const uint8_t stringNumber = *pMuxId;
199 signalData = (signalData + offset) * factor;
200 uint64_t data = (int64_t)signalData;
208 signalData = (signalData + offset) * factor;
209 data = (int64_t)signalData;
217 signalData = (signalData + offset) * factor;
218 data = (int64_t)signalData;
226 signalData = (signalData + offset) * factor;
227 data = (int64_t)signalData;
247 #ifdef UNITY_UNIT_TEST
#define BS_NR_OF_STRINGS
Number of parallel strings in the battery pack.
uint8_t BMS_GetNumberOfConnectedStrings(void)
Returns number of connected strings.
bool BMS_IsStringClosed(uint8_t stringNumber)
Returns string state (closed or open)
uint32_t CAN_TxMinimumMaximumValues(uint32_t id, uint8_t dlc, CAN_ENDIANNESS_e endianness, uint8_t *pCanData, uint8_t *pMuxId, const CAN_SHIM_s *const kpkCanShim)
can tx callback function for min/max values
uint32_t CAN_TxStringMinimumMaximumValues(uint32_t id, uint8_t dlc, CAN_ENDIANNESS_e endianness, uint8_t *pCanData, uint8_t *pMuxId, const CAN_SHIM_s *const kpkCanShim)
can tx callback function for string minimum and maximum values
void CAN_TxSetMessageDataWithSignalData(uint64_t *pMessage, uint64_t bitStart, uint8_t bitLength, uint64_t canSignal, CAN_ENDIANNESS_e endianness)
Puts CAN signal data in a 64-bit variable. This function is used to compose a 64-bit CAN message....
void CAN_TxSetCanDataWithMessageData(uint64_t message, uint8_t *pCanData, CAN_ENDIANNESS_e endianness)
Copy CAN data from a 64-bit variable to 8 bytes. This function is used to copy a 64-bit CAN message t...
Headers for the helper functions for the CAN module.
#define DATA_READ_DATA(...)
#define FAS_ASSERT(x)
Assertion macro that asserts that x is true.
#define NULL_PTR
Null pointer.
DATA_BLOCK_MIN_MAX_s * pTableMinMax
int16_t minimumTemperature_ddegC[BS_NR_OF_STRINGS]
int16_t maximumTemperature_ddegC[BS_NR_OF_STRINGS]
int16_t maximumCellVoltage_mV[BS_NR_OF_STRINGS]
int16_t minimumCellVoltage_mV[BS_NR_OF_STRINGS]