1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-26 01:35:35 +03:00

GPS: Switched from HDOP/VDOP to EPH/EPV values - absolute accuracy; Add logging of GPS EPH/EPV to blackbox; EPH/EPV values for NMEA and I2C-NAV boards are marked as invalid as they are not real accuracy values; GPS data processing code refactoring for simplicity

This commit is contained in:
Konstantin Sharlaimov (DigitalEntity) 2016-01-18 17:34:54 +10:00
parent 5f7cebb181
commit 8b8060bae1
13 changed files with 84 additions and 49 deletions

View file

@ -1631,14 +1631,22 @@ static bool processInCommand(void)
} else {
DISABLE_STATE(GPS_FIX);
}
gpsSol.flags.validVelNE = 0;
gpsSol.flags.validVelD = 0;
gpsSol.flags.validEPE = 0;
gpsSol.numSat = read8();
gpsSol.llh.lat = read32();
gpsSol.llh.lon = read32();
gpsSol.llh.alt = read16();
gpsSol.groundSpeed = read16();
gpsSol.velNED[X] = 0;
gpsSol.velNED[Y] = 0;
gpsSol.velNED[Z] = 0;
gpsSol.eph = 100;
gpsSol.epv = 100;
// Feed data to navigation
sensorsSet(SENSOR_GPS);
onNewGPSData(gpsSol.llh.lat, gpsSol.llh.lon, gpsSol.llh.alt, 0, 0, 0, false, false, 9999);
onNewGPSData();
break;
#endif
#ifdef NAV