Commit Graph

264 Commits

Author SHA1 Message Date
Petr Kracík a1f664dd0b Make clang happy 2021-11-20 20:55:34 +01:00
Petr Kracík d34d29ab38 Added support for generic Stream class 2021-11-20 19:03:31 +01:00
Dylan Herrada f5030a2692
Bump to 1.5.4 2021-02-09 16:39:53 -05:00
lady ada 7800a6e30f tweak header description 2021-02-07 16:54:12 -05:00
lady ada 8546ac5058 reduce excess newlines. fix header 2021-02-07 15:41:52 -05:00
lady ada 9ce89f0490 add starting text, ask for version last, fix baudrate to 115200 to match tutorial 2021-02-07 15:23:12 -05:00
Dylan Herrada 490a2810b6
Bump to 1.5.3 2020-11-03 15:43:01 -05:00
Matt Goodrich 737f8b7d2c
Merge pull request #129 from foodini/patch-1
Fix issue with millisecond parsing.
2020-10-27 17:15:50 -04:00
Ron Barry 1666dae26b
Fix issue with millisecond parsing.
By calling atof() on p, we're converting the entire time string  (101520.123 for 10:15:20am and 123 milliseconds) to a float, then multiplying by 1000 to get ms. This results in a value that overflows and exhibits all sorts of strange behavior as seconds and minutes turn over. It's clearly not what was intended. From the if statement wrapping the conversion, it is clear that the author intended to make the atof() conversion on the dec pointer, instead. Making this change actually does fix the parsing so that Adafruit_GPS' milliseconds property correctly matches the value in the NMEA sentence.

You guys do great work. Thanks for everything!
2020-10-18 01:41:23 -07:00
dherrada 8d7ea109f1
Bump to 1.5.2 2020-07-21 09:44:40 -04:00
lady ada ea6dca6840 get more data 2020-07-19 12:35:42 -04:00
Matt Goodrich 9419a019bc
Update library.properties 2020-06-04 15:27:08 -04:00
Limor "Ladyada" Fried 2b20565cfd
Merge pull request #121 from drak7/master
Bugfix for parseCoord
2020-06-04 15:14:30 -04:00
Matt Goodrich e5ad8934d8 Bugfix for parseCoord 2020-06-04 14:43:11 -04:00
Matt Goodrich e730f81c3f
Update for 1.5.0 release 2020-05-07 19:35:54 -04:00
Matt Goodrich c65c00ae15
Merge pull request #117 from optorres/fix-warnings-2
Fix boolean deprecation and -Wdouble-promotion warnings
2020-02-25 14:30:22 -05:00
Matt Goodrich 8738b307ab
Merge pull request #116 from edgar-bonet/millis-rollover
Correct handling of millis() rollover
2020-02-25 11:55:56 -05:00
Owen Torres a0cf6d860a Fix formatting 2020-02-23 18:53:32 -05:00
Owen Torres e3caa7d491 Fix boolean deprecation and -Wdouble-promotion warnings 2020-02-23 18:39:46 -05:00
Edgar Bonet 76526b0b15 Document time limits of secondsSince*()
The values returned by Adafruit_GPS::secondsSince{Fix,Time,Date}()
wrap around if larger than 2^32 ms.
2020-02-21 21:04:56 +01:00
Edgar Bonet 939534d580 Correct handling of millis() rollover
millis() returns an unsigned long integer, and C++ guarantees that
arithmetics on this type work modulo (ULONG_MAX+1). This behavior
ensures that computing a delay as

    millis() - previousMillis

yields the correct result across millis() rollover events, as long as
the time actually elapsed is less than about 49.7 days.
2020-02-20 22:03:34 +01:00
Matt Goodrich 96625de7d3
Merge pull request #115 from sellensr/master
Bug Fixes
2020-02-10 11:30:35 -05:00
Rick Sellens fdda5b6e1e clang 2020-02-07 20:20:30 -05:00
Rick Sellens 59c1a4acbd casts to make unambiguous on UNO 2020-02-07 20:04:33 -05:00
Rick Sellens 8c550d278e fix to parsing bug on RMB sentence 2020-02-07 14:54:26 -05:00
Rick Sellens a047465a73 More rigor in parseTime()
previous version ran ok with M0, but generated exceptions in ESP32 when decimals not found.
2020-02-07 14:26:39 -05:00
Rick Sellens 07fd81fd91 explicit cast eliminates ambiguity
ESP32 wire lib includes requestFrom(int,int,int) and requestFrom(uint16_t,uint8_t,bool) and throws a warning trying to resolve.
2020-01-31 07:30:30 -05:00
Rick Sellens 50abddc691 comments to solve: https://github.com/adafruit/Adafruit_GPS/issues/76
Corrections to original comments that were off by a factor of 10.
2020-01-30 20:14:52 -05:00
Rick Sellens d0f7f47dc9 Warning about scaling 2020-01-30 17:09:35 -05:00
Rick Sellens d14e220c1b Add noCRLF option to build()
new optional argument will leave the carriage return and linefeed off the end of an NMEA sentence.
2020-01-30 14:29:17 -05:00
Rick Sellens deb312b293 Clear thisSentence and thisSource at start of each check
that way previous sentence identifiers won't bleed through on failure.
2020-01-29 19:52:13 -05:00
Rick Sellens 84eaad66e4 Fail Check if sentence not recognized
Previous check would pass for unknown but properly formatted sentence.
2020-01-29 19:44:05 -05:00
Matt Goodrich a57c52f242
Merge pull request #113 from sellensr/master
Add data values and history to NMEA_EXTENSIONS, plus more sentences
2020-01-29 16:57:10 -05:00
Rick Sellens ebb09d0480 clang 2020-01-29 13:23:02 -05:00
Rick Sellens 1afe1df764 clang 2020-01-29 13:10:43 -05:00
Rick Sellens 8ae6a7b75a clang 2020-01-29 12:57:20 -05:00
Rick Sellens 7d889e3a9d Reorder and document
Align the order in the .h with the order in the various .cpp
Note that ! is also a valid starting character for an NMEA sentence.
2020-01-29 12:03:25 -05:00
Rick Sellens 1d58e4e66e run data_init() under common_init() 2020-01-29 10:35:00 -05:00
Rick Sellens 0fca64d082 Comment out old Lat Lon parsing
new parse() uses generalized parseCoord()
2020-01-29 10:27:05 -05:00
Rick Sellens 3876f29fc1 New parse() with more sentences
move other parsing functions in NMEA_parse.cpp
fix parseTime to be insensitive to number of decimal places and return bool.
add isEmpty() checks where needed.
reorder some declarations.
2020-01-29 10:18:41 -05:00
Rick Sellens 4b6e181770 New version of build() with more sentences
move addChecksum() to NMEA_build.cpp
2020-01-29 10:03:59 -05:00
Rick Sellens 0b0996bbb0 Add NMEA_EXTRAS for command line compile control 2020-01-29 09:59:47 -05:00
Rick Sellens 2a5b5bdd1c Update source and sentence lists 2020-01-29 09:57:49 -05:00
Rick Sellens 6f41d311cd Add no comms constructor, destructor, data values 2020-01-29 09:56:21 -05:00
Rick Sellens bc038a14cf Example updates 2020-01-29 09:33:26 -05:00
Rick Sellens 6ea92a021d Create keywords.txt 2020-01-29 09:31:41 -05:00
Matt Goodrich 24715012b3
Merge pull request #112 from optorres/fix-warnings
Fix a few warnings
2020-01-27 17:03:26 -05:00
Owen Torres 748707b6ee Fix -Wdouble-promotion warnings
We want to avoid using doubles where unnessesary since many embedded
targets have only a single precision FPU or no FPU at all.

Passing doubles is unavoidable with the printf family of functions,
so use an explicit cast to silence the warning.
2020-01-27 19:01:45 +00:00
Owen Torres 61fe38d503 Remove unused variables 2020-01-27 18:54:28 +00:00
Owen Torres 17bb6d1ed2 Replace boolean with standard bool
This causes deprecation warnings when compiling with the STM32duino
Arduino core.
2020-01-27 18:54:28 +00:00