fixes from PR #851, #858 ported to NMEA GPS

apply fixes and upgrades from PR #851, #858 to NMEA GPS code
This commit is contained in:
a-f-G-U-C
2021-09-08 14:02:13 +00:00
committed by GitHub
parent 6f763c6418
commit f6f9b9cd03
2 changed files with 125 additions and 28 deletions

View File

@@ -12,6 +12,15 @@
class NMEAGPS : public GPS
{
TinyGPSPlus reader;
uint8_t fixQual = 0; // fix quality from GPGGA
#ifndef TINYGPS_OPTION_NO_CUSTOM_FIELDS
// (20210908) TinyGps++ can only read the GPGSA "FIX TYPE" field
// via optional feature "custom fields", currently disabled (bug #525)
TinyGPSCustom gsafixtype; // custom extract fix type from GPGSA
TinyGPSCustom gsapdop; // custom extract PDOP from GPGSA
uint8_t fixType = 0; // fix type from GPGSA
#endif
public:
virtual bool setupGPS();
@@ -38,4 +47,6 @@ class NMEAGPS : public GPS
* @return true if we've acquired a new location
*/
virtual bool lookForLocation();
virtual bool hasLock();
};