1
+ // This function gets called when an RTCM packet passes parser check in processUart1Message() task
2
+ // Pass data along to NTRIP Server, or ESP-NOW radio
3
+ void processRTCM (uint8_t *rtcmData, uint16_t dataLength)
4
+ {
5
+ // Give this byte to the various possible transmission methods
6
+ for (int x = 0 ; x < dataLength; x++)
7
+ {
8
+ for (int serverIndex = 0 ; serverIndex < NTRIP_SERVER_MAX; serverIndex++)
9
+ ntripServerProcessRTCM (serverIndex, rtcmData[x]);
10
+ }
1
11
12
+ for (int x = 0 ; x < dataLength; x++)
13
+ espnowProcessRTCM (rtcmData[x]);
14
+
15
+ rtcmLastPacketSent = millis ();
16
+ rtcmPacketsSent++;
2
17
3
- // This function gets called from the SparkFun u-blox Arduino Library.
4
- // As each RTCM byte comes in you can specify what to do with it
5
- // Useful for passing the RTCM correction data to a radio, Ntrip broadcaster, etc.
6
- void DevUBLOXGNSS::processRTCM (uint8_t incoming)
7
- {
8
18
// Check for too many digits
9
19
if (settings.enableResetDisplay == true )
10
20
{
@@ -16,22 +26,4 @@ void DevUBLOXGNSS::processRTCM(uint8_t incoming)
16
26
if (rtcmPacketsSent > 999 )
17
27
rtcmPacketsSent = 1 ; // Trim to three digits to avoid log icon and increasing bar
18
28
}
19
-
20
- // Determine if we should check this byte with the RTCM checker or simply pass it along
21
- bool passAlongIncomingByte = true ;
22
-
23
- if (settings.enableRtcmMessageChecking == true )
24
- passAlongIncomingByte &= checkRtcmMessage (incoming);
25
-
26
- // Give this byte to the various possible transmission methods
27
- if (passAlongIncomingByte)
28
- {
29
- rtcmLastReceived = millis ();
30
- rtcmBytesSent++;
31
-
32
- for (int serverIndex = 0 ; serverIndex < NTRIP_SERVER_MAX; serverIndex++)
33
- ntripServerProcessRTCM (serverIndex, incoming);
34
-
35
- espnowProcessRTCM (incoming);
36
- }
37
- }
29
+ }
0 commit comments