diff options
author | Stanley Huang <stanleyhuangyc@live.com> | 2018-04-11 11:38:01 +1000 |
---|---|---|
committer | Stanley Huang <stanleyhuangyc@live.com> | 2018-04-11 11:38:01 +1000 |
commit | 26196c5808a0c1dd2fba7e357d9a7ba8aa7037d7 (patch) | |
tree | 32e9248b622e33bec44a8766e06c9dbaa0761f79 /libraries | |
parent | 668e49d0471c9caa7243d51d416dde34bb0e00f3 (diff) | |
download | 2021-arduino-obd-26196c5808a0c1dd2fba7e357d9a7ba8aa7037d7.tar.gz 2021-arduino-obd-26196c5808a0c1dd2fba7e357d9a7ba8aa7037d7.tar.bz2 2021-arduino-obd-26196c5808a0c1dd2fba7e357d9a7ba8aa7037d7.zip |
Update
Diffstat (limited to 'libraries')
-rw-r--r-- | libraries/TinyGPS/TinyGPS.cpp | 4 | ||||
-rw-r--r-- | libraries/TinyGPS/TinyGPS.h | 6 |
2 files changed, 3 insertions, 7 deletions
diff --git a/libraries/TinyGPS/TinyGPS.cpp b/libraries/TinyGPS/TinyGPS.cpp index c45ed19..3ff6635 100644 --- a/libraries/TinyGPS/TinyGPS.cpp +++ b/libraries/TinyGPS/TinyGPS.cpp @@ -166,7 +166,7 @@ unsigned long TinyGPS::parse_degrees() { char *p; unsigned long left = gpsatol(_term); - unsigned long tenk_minutes = (left % 100UL) * 100000UL; + unsigned long tenk_minutes = (left % 100UL) * 10000UL; for (p=_term; gpsisdigit(*p); ++p); if (*p == '.') { @@ -177,7 +177,7 @@ unsigned long TinyGPS::parse_degrees() mult /= 10; } } - return (left / 100) * 1000000 + tenk_minutes / 6; + return (left / 100) * 100000 + tenk_minutes / 6; } #define COMBINE(sentence_type, term_number) (((unsigned)(sentence_type) << 5) | term_number) diff --git a/libraries/TinyGPS/TinyGPS.h b/libraries/TinyGPS/TinyGPS.h index 6399d18..dad262d 100644 --- a/libraries/TinyGPS/TinyGPS.h +++ b/libraries/TinyGPS/TinyGPS.h @@ -23,11 +23,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA #ifndef TinyGPS_h #define TinyGPS_h -#if defined(ARDUINO) && ARDUINO >= 100 #include "Arduino.h" -#else -#include "WProgram.h" -#endif #define _GPS_VERSION 12 // software version of this library #define _GPS_MPH_PER_KNOT 1.15077945 @@ -35,7 +31,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA #define _GPS_KMPH_PER_KNOT 1.852 #define _GPS_MILES_PER_METER 0.00062137112 #define _GPS_KM_PER_METER 0.001 -//#define _GPS_NO_STATS +#define _GPS_NO_STATS class TinyGPS { |