Skip to content
This repository was archived by the owner on Jan 28, 2021. It is now read-only.

Commit 0e07bcc

Browse files
committed
Fixed incorrect call to processRTCMframe() in lib. Updated ex 3 and 4 to enable RTCM after survey in.
Lib was calling processRTCM instead of processRTCMframe. See discussion on forum: https://forum.sparkfun.com/viewtopic.php?t=49874
1 parent f37ffc7 commit 0e07bcc

File tree

3 files changed

+13
-7
lines changed

3 files changed

+13
-7
lines changed

Diff for: examples/ZED-F9P/Example3_StartRTCMBase/Example3_StartRTCMBase.ino

+2
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,8 @@ void setup()
137137
Serial.println("Survey valid!");
138138

139139
Serial.println("Base survey complete! RTCM now broadcasting.");
140+
141+
myGPS.setI2COutput(COM_TYPE_UBX | COM_TYPE_RTCM3); //Set the I2C port to output UBX and RTCM sentences (not really an option, turns on NMEA as well)
140142
}
141143

142144
void loop()

Diff for: examples/ZED-F9P/Example4_BaseWithLCD/Example4_BaseWithLCD.ino

+10-6
Original file line numberDiff line numberDiff line change
@@ -67,8 +67,9 @@ void setup()
6767
lcd.setCursor(0, 1);
6868
lcd.print("GPS Detected");
6969

70-
myGPS.setI2COutput(COM_TYPE_UBX); //Set the I2C port to output UBX only (turn off NMEA noise)
71-
myGPS.saveConfiguration(); //Save the current settings to flash and BBR
70+
//myGPS.setI2COutput(COM_TYPE_RTCM3); //Set the I2C port to output RTCM3 sentences (turn off NMEA noise)
71+
myGPS.setI2COutput(COM_TYPE_UBX); //Set the I2C port to output UBX sentences (turn off NMEA noise)
72+
myGPS.saveConfiguration(); //Save the current settings to flash and BBR
7273

7374
boolean response = true;
7475
response &= myGPS.enableRTCMmessage(UBX_RTCM_1005, COM_PORT_I2C, 1); //Enable message 1005 to output through I2C port, message every second
@@ -83,7 +84,7 @@ void setup()
8384
}
8485
else
8586
{
86-
Serial.println(F("RTCM failed to enable. Are you sure you have an NEO-M8P?"));
87+
Serial.println(F("RTCM failed to enable. Are you sure you have an ZED-F9P? Freezing."));
8788
while (1)
8889
; //Freeze
8990
}
@@ -92,7 +93,7 @@ void setup()
9293
response = myGPS.getSurveyStatus(2000); //Query module for SVIN status with 2000ms timeout (request can take a long time)
9394
if (response == false)
9495
{
95-
Serial.println(F("Failed to get Survey In status"));
96+
Serial.println(F("Failed to get Survey In status. Freezing."));
9697
while (1)
9798
; //Freeze
9899
}
@@ -111,7 +112,7 @@ void setup()
111112
{
112113
Serial.println(F("Survey start failed"));
113114
lcd.setCursor(0, 3);
114-
lcd.print(F("Survey start failed"));
115+
lcd.print(F("Survey start failed. Freezing."));
115116
while (1)
116117
;
117118
}
@@ -170,13 +171,16 @@ void setup()
170171
Serial.println(F("Base survey complete! RTCM now broadcasting."));
171172
lcd.clear();
172173
lcd.print(F("Transmitting RTCM"));
174+
175+
myGPS.setI2COutput(COM_TYPE_UBX | COM_TYPE_RTCM3); //Set the I2C port to output UBX and RTCM sentences (not really an option, turns on NMEA as well)
176+
173177
}
174178

175179
void loop()
176180
{
177181
myGPS.checkUblox(); //See if new data is available. Process bytes as they come in.
178182

179-
//Do anything you want. Call checkUblox() every second. NEO-M8P-2 has TX buffer of 4k bytes.
183+
//Do anything you want. Call checkUblox() every second. ZED-F9P has TX buffer of 4k bytes.
180184

181185
delay(250); //Don't pound too hard on the I2C bus
182186
}

Diff for: src/SparkFun_Ublox_Arduino_Library.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ void SFE_UBLOX_GPS::process(uint8_t incoming)
329329
}
330330
else if (currentSentence == RTCM)
331331
{
332-
processRTCM(incoming); //Deal with RTCM bytes
332+
processRTCMframe(incoming); //Deal with RTCM bytes
333333
}
334334
}
335335

0 commit comments

Comments
 (0)