@@ -85,11 +85,10 @@ void setup()
8585 // SFE_UBLOX_STATUS_DATA_RECEIVED if the data we requested was read / polled successfully
8686 // SFE_UBLOX_STATUS_DATA_SENT if the data we sent was writted successfully (ACK'd)
8787 // Other values indicate errors. Please see the sfe_ublox_status_e enum for further details.
88- // If you see a failure you can of course simply try sending the same command again.
8988
9089 // Referring to the u-blox M8 Receiver Description and Protocol Specification we see that
9190 // the dynamic model is configured using the UBX-CFG-NAV5 message. So let's load our
92- // custom packet with the correct information so we can read (poll) the current settings.
91+ // custom packet with the correct information so we can read (poll / get ) the current settings.
9392
9493 customCfg.cls = UBX_CLASS_CFG; // This is the message Class
9594 customCfg.id = UBX_CFG_NAV5; // This is the message ID
@@ -102,18 +101,9 @@ void setup()
102101 // Now let's read the current navigation model settings. The results will be loaded into customCfg.
103102 if (myGPS.sendCommand (&customCfg, maxWait) != SFE_UBLOX_STATUS_DATA_RECEIVED) // We are expecting data and an ACK
104103 {
105- Serial.println (F (" sendCommand (poll) failed! Trying again..." ));
106- // We need to reset the packet before we try again as the values could have changed
107- customCfg.cls = UBX_CLASS_CFG;
108- customCfg.id = UBX_CFG_NAV5;
109- customCfg.len = 0 ;
110- customCfg.startingSpot = 0 ;
111- if (myGPS.sendCommand (&customCfg, maxWait) != SFE_UBLOX_STATUS_DATA_RECEIVED) // We are expecting data and an ACK
112- {
113- Serial.println (F (" sendCommand (poll) failed again! Freezing." ));
114- while (1 )
115- ;
116- }
104+ Serial.println (F (" sendCommand (poll) failed! Freezing..." ));
105+ while (1 )
106+ ;
117107 }
118108
119109 // Referring to the message definition for UBX-CFG-NAV5 we see that we need to change
0 commit comments