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
{{ message }}
This repository was archived by the owner on Jan 28, 2021. It is now read-only.
This changes allow to use the SFE_UBLOX_GPS to be used as data storage and disable the implicit update of data that happened previously even with autoPVT set to true
Changes:
- add implicitUpdate parameter to setAutoPVT to control when the actual processing of the data happens
- add assumeAutoPVT method for use-cases where the receiver can't be controlled (no UART Tx line from MCU to receiver)
- change getPVT to respect autoPVTImplicitUpdate==false
- remove "virtual" from getPVT as it is not required anymore after the above changes
Copy file name to clipboardExpand all lines: src/SparkFun_Ublox_Arduino_Library.h
+4-1Lines changed: 4 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -226,8 +226,10 @@ class SFE_UBLOX_GPS
226
226
227
227
boolean waitForResponse(uint8_t requestedClass, uint8_t requestedID, uint16_t maxTime = 250); //Poll the module until and ack is received
228
228
229
+
boolean assumeAutoPVT(boolean enabled, boolean implicitUpdate = true); //In case no config access to the GPS is possible and PVT is send cyclically already
229
230
boolean setAutoPVT(boolean enabled, uint16_t maxWait = 250); //Enable/disable automatic PVT reports at the navigation frequency
230
-
virtual boolean getPVT(uint16_t maxWait = 1000); //Query module for latest group of datums and load global vars: lat, long, alt, speed, SIV, accuracies, etc. If autoPVT is disabled, performs an explicit poll and waits, if enabled does not block. Retruns true if new PVT is available.
231
+
boolean setAutoPVT(boolean enabled, boolean implicitUpdate, uint16_t maxWait = 250); //Enable/disable automatic PVT reports at the navigation frequency, with implicitUpdate == false accessing stale data will not issue parsing of data in the rxbuffer of your interface, instead you have to call checkUblox when you want to perform an update
232
+
boolean getPVT(uint16_t maxWait = 1000); //Query module for latest group of datums and load global vars: lat, long, alt, speed, SIV, accuracies, etc. If autoPVT is disabled, performs an explicit poll and waits, if enabled does not block. Retruns true if new PVT is available.
231
233
232
234
int32_tgetLatitude(uint16_t maxWait = 250); //Returns the current latitude in degrees * 10^-7. Auto selects between HighPrecision and Regular depending on ability of module.
233
235
int32_tgetLongitude(uint16_t maxWait = 250); //Returns the current longitude in degrees * 10-7. Auto selects between HighPrecision and Regular depending on ability of module.
@@ -399,6 +401,7 @@ class SFE_UBLOX_GPS
399
401
constuint8_t I2C_POLLING_WAIT_MS = 25; //Limit checking of new characters to every X ms
400
402
unsignedlong lastCheck = 0;
401
403
boolean autoPVT = false; //Whether autoPVT is enabled or not
404
+
boolean autoPVTImplicitUpdate = true; // Whether autoPVT is triggered by accessing stale data (=true) or by a call to checkUblox (=false)
402
405
boolean commandAck = false; //This goes true after we send a command and it's ack'd
0 commit comments