@@ -67,8 +67,9 @@ void setup()
67
67
lcd.setCursor (0 , 1 );
68
68
lcd.print (" GPS Detected" );
69
69
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
72
73
73
74
boolean response = true ;
74
75
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()
83
84
}
84
85
else
85
86
{
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. " ));
87
88
while (1 )
88
89
; // Freeze
89
90
}
@@ -92,7 +93,7 @@ void setup()
92
93
response = myGPS.getSurveyStatus (2000 ); // Query module for SVIN status with 2000ms timeout (request can take a long time)
93
94
if (response == false )
94
95
{
95
- Serial.println (F (" Failed to get Survey In status" ));
96
+ Serial.println (F (" Failed to get Survey In status. Freezing. " ));
96
97
while (1 )
97
98
; // Freeze
98
99
}
@@ -111,7 +112,7 @@ void setup()
111
112
{
112
113
Serial.println (F (" Survey start failed" ));
113
114
lcd.setCursor (0 , 3 );
114
- lcd.print (F (" Survey start failed" ));
115
+ lcd.print (F (" Survey start failed. Freezing. " ));
115
116
while (1 )
116
117
;
117
118
}
@@ -170,13 +171,16 @@ void setup()
170
171
Serial.println (F (" Base survey complete! RTCM now broadcasting." ));
171
172
lcd.clear ();
172
173
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
+
173
177
}
174
178
175
179
void loop ()
176
180
{
177
181
myGPS.checkUblox (); // See if new data is available. Process bytes as they come in.
178
182
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.
180
184
181
185
delay (250 ); // Don't pound too hard on the I2C bus
182
186
}
0 commit comments