update for gps
Some checks are pending
EIVE/eive-obsw/pipeline/head Build started...
EIVE/eive-obsw/pipeline/pr-develop This commit looks good

- GPSD/NTPD finally seem to work now. Still keep code to set it manually for  now
This commit is contained in:
2022-04-07 10:55:29 +02:00
parent a6d20de0a5
commit c3aa9fb908
2 changed files with 102 additions and 2 deletions

View File

@ -4,6 +4,8 @@
#include "fsfw/datapool/PoolReadGuard.h"
#include "fsfw/timemanager/Clock.h"
#include "mission/utility/compileTime.h"
#if FSFW_DEV_HYPERION_GPS_CREATE_NMEA_CSV == 1
#include <filesystem>
#include <fstream>
@ -184,8 +186,9 @@ void GPSHyperionLinuxController::readGpsDataFromGpsd() {
// If the received time does not change anymore for whatever reason, do not set it here
// to avoid stale times. Also, don't do it too often often to avoid jumping times
if (timeIsConstantCounter < 20 and timeUpdateCd.hasTimedOut()) {
// Update the system time here for now. NTP seems to be unable to do so for whatever reason
settimeofday(&time, nullptr);
// Update the system time here for now. NTP seems to be unable to do so for whatever reason.
// Further tests have shown that the time seems to be set by NTPD after sme time..
// Clock::setClock(&time);
timeUpdateCd.resetTimer();
}