Merge branch 'dev-7.5.0' into higher-acs-modes-only-str
Some checks failed
EIVE/eive-obsw/pipeline/pr-dev-7.5.0 There was a failure building this commit

This commit is contained in:
2023-12-04 13:19:28 +01:00
5 changed files with 23 additions and 29 deletions

View File

@ -15,13 +15,12 @@ void SensorProcessing::processMgm(const float *mgm0Value, bool mgm0valid, const
// ------------------------------------------------
double magIgrfModel[3] = {0.0, 0.0, 0.0};
bool gpsValid = false;
if (gpsDataProcessed->source.value != acs::gps::Source::NONE) {
if (gpsDataProcessed->source.value != acs::GpsSource::NONE) {
// There seems to be a bug here, which causes the model vector to drift until infinity, if the
// model class is not initialized new every time. Works for now, but should be investigated.
Igrf13Model igrf13;
igrf13.schmidtNormalization();
igrf13.updateCoeffGH(timeAbsolute);
// ToDo
// maybe put a condition here, to only update after a full day, this
// class function has around 700 steps to perform
igrf13.magFieldComp(gpsDataProcessed->gdLongitude.value, gpsDataProcessed->gcLatitude.value,
gpsDataProcessed->altitude.value, timeAbsolute, magIgrfModel);
gpsValid = true;