106 int16_t minimumCellVoltage_mV,
107 int16_t maximumCellVoltage_mV,
122 int16_t minimumCellTemperature_ddegC,
123 int16_t maximumCellTemperature_ddegC,
190 int16_t minimumCellVoltage_mV,
191 int16_t maximumCellVoltage_mV,
200 if (minimumCellVoltage_mV <= pConfigLimitValues->limitLowerCellVoltage_mV) {
204 if (minimumCellVoltage_mV <= pConfigLimitValues->cutoffLowerCellVoltage_mV) {
233 int16_t minimumCellTemperature_ddegC,
234 int16_t maximumCellTemperature_ddegC,
244 if (minimumCellTemperature_ddegC <= pConfigLimitValues->limitLowTemperatureDischarge_ddegC) {
248 if (minimumCellTemperature_ddegC <= pConfigLimitValues->cutoffLowTemperatureDischarge_ddegC) {
261 if (minimumCellTemperature_ddegC <= pConfigLimitValues->limitLowTemperatureCharge_ddegC) {
265 if (minimumCellTemperature_ddegC <= pConfigLimitValues->cutoffLowTemperatureCharge_ddegC) {
346 #if BMS_CHECK_SOF_CURRENT_LIMITS == true
369 uint8_t nrClosedStrings = 0;
370 float minDischarge_mA = FLT_MAX;
371 float minCharge_mA = FLT_MAX;
373 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
387 &temperatureBasedSof,
414 #if BMS_CHECK_SOF_CURRENT_LIMITS == true
425 &temperatureBasedSof,
445 &temperatureBasedSof,
465 &temperatureBasedSof,
509 #ifdef UNITY_UNIT_TEST
510 extern void TEST_SOF_CalculateCurves(
const SOF_CONFIG_s *pConfigurationValues,
SOF_CURVE_s *pCalculatedSofCurveValues) {
513 extern void TEST_SOF_CalculateVoltageBasedCurrentLimit(
514 int16_t minimumCellVoltage_mV,
515 int16_t maximumCellVoltage_mV,
520 minimumCellVoltage_mV,
521 maximumCellVoltage_mV,
522 pAllowedVoltageBasedCurrent,
524 pCalculatedSofCurves);
526 extern void TEST_SOF_CalculateTemperatureBasedCurrentLimit(
527 int16_t minimumCellTemperature_ddegC,
528 int16_t maximumCellTemperature_ddegC,
533 minimumCellTemperature_ddegC,
534 maximumCellTemperature_ddegC,
535 pAllowedTemperatureBasedCurrent,
537 pCalculatedSofCurves);