STR Validity Fix #839

Closed
meggert wants to merge 2 commits from str-valid-fixes into main
3 changed files with 13 additions and 4 deletions

View File

@ -16,6 +16,11 @@ will consitute of a breaking change warranting a new major release:
# [unreleased]
## Fixed
- As the `STR Handler` does not set an untrustworthy quaternion to invalid, the `ACS Controller`
needs to do this on its own.
# [v7.5.2] 2023-12-14
## Fixed

View File

@ -380,8 +380,10 @@ void AcsController::performDetumble() {
}
void AcsController::performPointingCtrl() {
bool strValid = (sensorValues.strSet.caliQw.isValid() and sensorValues.strSet.caliQx.isValid() and
sensorValues.strSet.caliQy.isValid() and sensorValues.strSet.caliQz.isValid());
bool strValid =
((sensorValues.strSet.caliQw.isValid() and sensorValues.strSet.caliQx.isValid() and
sensorValues.strSet.caliQy.isValid() and sensorValues.strSet.caliQz.isValid()) and
(sensorValues.strSet.isTrustWorthy.isValid() and sensorValues.strSet.isTrustWorthy.value));
uint8_t useMekf = false;
switch (mode) {
case acs::PTG_IDLE:

View File

@ -73,8 +73,10 @@ void FusedRotationEstimation::estimateFusedRotationRate(
void FusedRotationEstimation::estimateFusedRotationRateStr(
ACS::SensorValues *sensorValues, const double timeDelta,
acsctrl::FusedRotRateSourcesData *fusedRotRateSourcesData) {
if (not(sensorValues->strSet.caliQw.isValid() and sensorValues->strSet.caliQx.isValid() and
sensorValues->strSet.caliQy.isValid() and sensorValues->strSet.caliQz.isValid())) {
if (not((sensorValues->strSet.caliQw.isValid() and sensorValues->strSet.caliQx.isValid() and
sensorValues->strSet.caliQy.isValid() and sensorValues->strSet.caliQz.isValid()) and
(sensorValues->strSet.isTrustWorthy.isValid() and
sensorValues->strSet.isTrustWorthy.value))) {
{
PoolReadGuard pg(fusedRotRateSourcesData);
if (pg.getReadResult() == returnvalue::OK) {