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
If you are using Serial, and the module is already outputting messages at high navigation rate, .begin can often fail due to traffic congestion.
You can:
- use a long maxWait (5 seconds seems to work well)
- use a short maxWait and set assumeSuccess to true
if ((!connected ) && assumeSuccess) // Advanced users can assume success if required. Useful if the port is outputting messages at high navigation rate.
489
+
{
490
+
#ifndef SFE_UBLOX_REDUCED_PROG_MEM
491
+
if ((_printDebug == true) || (_printLimitedDebug == true)) // This is important. Print this if doing limited debugging
492
+
{
493
+
_debugSerial->println(F("begin: third attempt failed. Assuming success..."));
if ((!connected ) && assumeSuccess) // Advanced users can assume success if required. Useful if the port is outputting messages at high navigation rate.
541
+
{
542
+
#ifndef SFE_UBLOX_REDUCED_PROG_MEM
543
+
if ((_printDebug == true) || (_printLimitedDebug == true)) // This is important. Print this if doing limited debugging
544
+
{
545
+
_debugSerial->println(F("begin: third attempt failed. Assuming success..."));
if ((!connected ) && assumeSuccess) // Advanced users can assume success if required. Useful if the port is outputting messages at high navigation rate.
621
+
{
622
+
#ifndef SFE_UBLOX_REDUCED_PROG_MEM
623
+
if ((_printDebug == true) || (_printLimitedDebug == true)) // This is important. Print this if doing limited debugging
624
+
{
625
+
_debugSerial->println(F("begin: third attempt failed. Assuming success..."));
Copy file name to clipboardExpand all lines: src/SparkFun_u-blox_GNSS_Arduino_Library.h
+4-3
Original file line number
Diff line number
Diff line change
@@ -598,12 +598,13 @@ class SFE_UBLOX_GNSS
598
598
//New in v2.0: allow the payload size for packetCfg to be changed
599
599
voidsetPacketCfgPayloadSize(size_t payloadSize); // Set packetCfgPayloadSize
600
600
601
+
//Begin communication with the GNSS. Advanced users can assume success if required. Useful if the port is already outputting messages at high navigation rate.
601
602
//By default use the default I2C address, and use Wire port
0 commit comments