Fix for Current Calculation in PWR Ctrl #880

Merged
meggert merged 2 commits from fix-soc into main 2024-03-21 09:14:55 +01:00
2 changed files with 5 additions and 1 deletions

View File

@ -16,6 +16,10 @@ will consitute of a breaking change warranting a new major release:
# [unreleased]
## Fixed
- Fixed wrong sign in calculation of total current within the `PWR Controller`.
# [v7.7.3] 2024-03-18
- Bumped `eive-fsfw`

View File

@ -182,7 +182,7 @@ void PowerController::calculateStateOfCharge() {
}
// calculate total battery current
iBat = p60CoreHk.batteryCurrent.value + bpxBatteryHk.dischargeCurrent.value;
iBat = p60CoreHk.batteryCurrent.value - bpxBatteryHk.dischargeCurrent.value;
result = calculateOpenCircuitVoltageCharge();
if (result != returnvalue::OK) {