From bbf55ae81d3a383404886cb3c8bd7bb6fcd8288d Mon Sep 17 00:00:00 2001 From: Pawel Jalocha Date: Sun, 30 Aug 2020 13:15:08 +0100 Subject: [PATCH] Pass every 5th for satellite info to be visible in Stratux --- main/gps.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/main/gps.cpp b/main/gps.cpp index 9497db8..cd6679c 100644 --- a/main/gps.cpp +++ b/main/gps.cpp @@ -549,7 +549,10 @@ static void GPS_NMEA(void) // wh #endif #ifndef WITH_GPS_NMEA_PASS // these NMEA from GPS we want to pass to the console - if( NMEA.isP() || NMEA.isGxRMC() || NMEA.isGxGGA() || NMEA.isGxGSA() || NMEA.isGPTXT() ) + static uint8_t Count=0; + bool RatePass=0; + Count++; if(Count>=5) { Count=0; RatePass=1; } + if( NMEA.isP() || NMEA.isGxRMC() || NMEA.isGxGGA() || NMEA.isGxGSA() || (RatePass && (NMEA.isGPTXT() || NMEA.isGxGSV())) ) // we would need to patch the GGA here for the GPS which does not calc. nor correct for GeoidSepar #endif { if(Parameters.Verbose)