diff --git a/CHANGELOG.md b/CHANGELOG.md index dfc11264..c81f1639 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,6 +21,10 @@ will consitute of a breaking change warranting a new major release: - Rotational rate limit for the GS target pointing is now seperated from controller limit. It is also reduced to 0.75°/s now. +## Fixed + +- Fixed wrong sign in calculation of total current within the `PWR Controller`. + # [v7.7.3] 2024-03-18 - Bumped `eive-fsfw` diff --git a/mission/controller/PowerController.cpp b/mission/controller/PowerController.cpp index 8fb774dc..e4ad9f81 100644 --- a/mission/controller/PowerController.cpp +++ b/mission/controller/PowerController.cpp @@ -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) {