Update to v1.8.0 #100
@ -101,7 +101,13 @@ ReturnValue_t GPSHyperionHandler::scanForReply(const uint8_t *start, size_t len,
|
||||
gpsSet.latitude.value = gpsData.latitude;
|
||||
// Negative longitude -> West direction
|
||||
gpsSet.longitude.value = gpsData.longitude;
|
||||
if(gpsData.altitude > 600000.0 or gpsData.altitude < 400000.0) {
|
||||
gpsSet.altitude.setValid(false);
|
||||
}
|
||||
else {
|
||||
gpsSet.altitude.setValid(true);
|
||||
gpsSet.altitude.value = gpsData.altitude;
|
||||
}
|
||||
gpsSet.fixMode.value = gpsData.fix_mode;
|
||||
gpsSet.satInUse.value = gpsData.sats_in_use;
|
||||
Clock::TimeOfDay_t timeStruct = {};
|
||||
@ -120,6 +126,7 @@ ReturnValue_t GPSHyperionHandler::scanForReply(const uint8_t *start, size_t len,
|
||||
gpsSet.hours = gpsData.hours;
|
||||
gpsSet.minutes = gpsData.minutes;
|
||||
gpsSet.seconds = gpsData.seconds;
|
||||
gpsSet.unixSeconds = timeval.tv_sec;
|
||||
if(debugHyperionGps) {
|
||||
sif::info << "GPS Data" << std::endl;
|
||||
printf("Valid status: %d\n", gpsData.is_valid);
|
||||
|
Loading…
Reference in New Issue
Block a user