You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Modern GPS can receive data from a number of GPS satellite systems now. Made a minor code change to TinyGPS.cpp to allow both the US GPS system GPRMC and GPGGA messages and the combined satellite services format GNRMC and GNGGA sentences which supply the same data from any available satellite source.
This came about plugging a BN-880 u-bloc Neo8/8 GPS with onboard HMC5883L compass into the project. The default message set is GNXX. Used U-Center program form u-blox to configure the message output to just GNRMC and GNGGA sentences to reduce CPU parsing overhead. This model GPS has onboard flash to store config changes.
Add 2 new sentences (GNXXX)
#define _GPRMC_TERM "GPRMC"
#define _GPGGA_TERM "GPGGA"
#define _GNRMC_TERM "GNRMC" // support other systems
#define _GNGGA_TERM "GNGGA" // support other systems
Match on either and convert to the standard sentence type. Here is the slightly revised part.
// the first term determines the sentence type
if (_term_number == 0)
{
if (!gpsstrcmp(_term, _GPRMC_TERM) || !gpsstrcmp(_term, _GNRMC_TERM)) // support other systems with GNXXX and convert to standard sentence type
_sentence_type = _GPS_SENTENCE_GPRMC;
else if (!gpsstrcmp(_term, _GPGGA_TERM) || !gpsstrcmp(_term, _GNRMC_TERM)) // support other systems with GNXXX and convert to standard sentence type
_sentence_type = _GPS_SENTENCE_GPGGA;
else
_sentence_type = _GPS_SENTENCE_OTHER;
return false;
}
I still have yet to make the 5883L compass work.
Mike
K7MDL
The text was updated successfully, but these errors were encountered:
Modern GPS can receive data from a number of GPS satellite systems now. Made a minor code change to TinyGPS.cpp to allow both the US GPS system GPRMC and GPGGA messages and the combined satellite services format GNRMC and GNGGA sentences which supply the same data from any available satellite source.
This came about plugging a BN-880 u-bloc Neo8/8 GPS with onboard HMC5883L compass into the project. The default message set is GNXX. Used U-Center program form u-blox to configure the message output to just GNRMC and GNGGA sentences to reduce CPU parsing overhead. This model GPS has onboard flash to store config changes.
Add 2 new sentences (GNXXX)
#define _GPRMC_TERM "GPRMC"
#define _GPGGA_TERM "GPGGA"
#define _GNRMC_TERM "GNRMC" // support other systems
#define _GNGGA_TERM "GNGGA" // support other systems
Match on either and convert to the standard sentence type. Here is the slightly revised part.
// the first term determines the sentence type
if (_term_number == 0)
{
if (!gpsstrcmp(_term, _GPRMC_TERM) || !gpsstrcmp(_term, _GNRMC_TERM)) // support other systems with GNXXX and convert to standard sentence type
_sentence_type = _GPS_SENTENCE_GPRMC;
else if (!gpsstrcmp(_term, _GPGGA_TERM) || !gpsstrcmp(_term, _GNRMC_TERM)) // support other systems with GNXXX and convert to standard sentence type
_sentence_type = _GPS_SENTENCE_GPGGA;
else
_sentence_type = _GPS_SENTENCE_OTHER;
return false;
}
I still have yet to make the 5883L compass work.
K7MDL
The text was updated successfully, but these errors were encountered: