rot rate limit change

This commit is contained in:
Marius Eggert 2024-03-20 16:18:03 +01:00
parent d1fc876f03
commit 46c125d9fe
3 changed files with 5 additions and 1 deletions

View File

@ -554,6 +554,9 @@ ReturnValue_t AcsParameters::getParameter(uint8_t domainId, uint8_t parameterId,
case 0xE:
parameterWrapper->set(gsTargetModeControllerParameters.altitudeTgt);
break;
case 0xF:
parameterWrapper->set(gsTargetModeControllerParameters.rotRateLimit);
break;
default:
return INVALID_IDENTIFIER_ID;
}

View File

@ -898,6 +898,7 @@ class AcsParameters : public HasParametersIF {
double latitudeTgt = 48.7495 * DEG2RAD; // [rad] Latitude
double longitudeTgt = 9.10384 * DEG2RAD; // [rad] Longitude
double altitudeTgt = 500; // [m]
double rotRateLimit = .5 * DEG2RAD;
} gsTargetModeControllerParameters;
struct NadirModeControllerParameters : PointingLawParameters {

View File

@ -251,7 +251,7 @@ void Guidance::limitReferenceRotation(const double xAxisIX[3], double quatIX[4])
QuaternionOperations::inverse(quatIXprev, quatXprevI);
QuaternionOperations::multiply(quatIX, quatXprevI, quatXprevX);
QuaternionOperations::normalize(quatXprevX);
double phiMax = acsParameters->gsTargetModeControllerParameters.omMax *
double phiMax = acsParameters->gsTargetModeControllerParameters.rotRateLimit *
acsParameters->onBoardParams.sampleTime;
if (2 * std::acos(quatXprevX[3]) < phiMax) {
return;