Skip to content

Commit aa98c11

Browse files
committed
Function rename
1 parent 2b3fc31 commit aa98c11

File tree

4 files changed

+21
-14
lines changed

4 files changed

+21
-14
lines changed

Firmware/RTK_Everywhere/GNSS_Mosaic.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2719,7 +2719,7 @@ void GNSS_MOSAIC::update()
27192719
{
27202720
if (spartnCorrectionsReceived) // If corrections were being received
27212721
{
2722-
configureLBand(pointPerfectLbandEnabled()); // Restart L-Band using stored frequency
2722+
configureLBand(pointPerfectLbandNeeded()); // Restart L-Band using stored frequency
27232723
spartnCorrectionsReceived = false;
27242724
}
27252725
}

Firmware/RTK_Everywhere/HTTP_Client.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,7 @@ void httpClientUpdate()
608608
httpClientSetState(HTTP_CLIENT_COMPLETE);
609609
} // Valid certificates
610610
} // End handle keys type response
611-
else if (pointPerfectNtripEnabled() == true)
611+
else if (pointPerfectNtripNeeded() == true)
612612
{
613613
// We received a JSON blob containing NTRIP credentials
614614
systemPrintf("PointPerfect response: %s\r\n", response.c_str());

Firmware/RTK_Everywhere/MQTT_Client.ino

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -229,8 +229,8 @@ bool mqttClientEnabled(const char **line)
229229
break;
230230
}
231231

232-
// MQTT requires use of point perfect corrections
233-
if (pointPerfectIsEnabled() == false)
232+
// Stop MQTT client if user changes PointPerfect service
233+
if (pointPerfectMqttNeeded() == false)
234234
{
235235
if (line)
236236
*line = ", PointPerfect corrections are disabled!";
@@ -1007,7 +1007,7 @@ void mqttClientUpdate()
10071007
mqttClientRestart();
10081008
break;
10091009
}
1010-
1010+
10111011
// Check for new data
10121012
mqttClient->poll();
10131013

Firmware/RTK_Everywhere/menuPP.ino

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -517,8 +517,8 @@ void updateLBand()
517517
#ifdef COMPILE_L_BAND
518518
if (present.lband_neo)
519519
{
520-
//Start L-Band if it is enabled
521-
if (online.lband_neo == false && pointPerfectLbandEnabled() == true)
520+
// Start L-Band if it is enabled
521+
if (online.lband_neo == false && pointPerfectLbandNeeded() == true)
522522
{
523523
static bool lband_neo_can_not_begin = false;
524524

@@ -625,7 +625,7 @@ void updateLBand()
625625

626626
online.lband_neo = true;
627627
}
628-
else if (online.lband_neo && pointPerfectIsEnabled())
628+
else if (online.lband_neo && pointPerfectServiceUsesKeys())
629629
{
630630
// L-Band is online. Apply the keys if they have changed
631631
// This may be redundant as PROVISIONING_KEYS_REMAINING also applies the keys
@@ -644,7 +644,7 @@ void updateLBand()
644644
if (present.gnss_mosaicX5)
645645
{
646646
// Start L-Band if service is enabled
647-
if (online.lband_gnss == false && pointPerfectLbandEnabled())
647+
if (online.lband_gnss == false && pointPerfectLbandNeeded())
648648
{
649649
if (lband_gnss_can_not_begin)
650650
return;
@@ -711,7 +711,7 @@ void updateLBand()
711711
}
712712

713713
// Stop L-Band is service is disabled
714-
else if (online.lband_gnss == true && pointPerfectLbandEnabled() == false)
714+
else if (online.lband_gnss == true && pointPerfectLbandNeeded() == false)
715715
{
716716
Serial.println("\n\r Taking L-Band offline");
717717

@@ -831,16 +831,24 @@ bool pointPerfectServiceUsesKeys()
831831
return false;
832832
}
833833

834-
// Determine if this service type uses L-Band
835-
bool pointPerfectLbandEnabled()
834+
// Determine if this service type uses MQTT for corrections
835+
bool pointPerfectMqttNeeded()
836+
{
837+
if (settings.pointPerfectService == PP_NICKNAME_IP_MQTT)
838+
return true;
839+
return false;
840+
}
841+
842+
// Determine if this service type uses L-Band for corrections
843+
bool pointPerfectLbandNeeded()
836844
{
837845
if (settings.pointPerfectService == PP_NICKNAME_FLEX_LBAND_NA || settings.pointPerfectService == PP_NICKNAME_GLOBAL)
838846
return true;
839847
return false;
840848
}
841849

842850
// Determine if this service type uses NTRIP for corrections
843-
bool pointPerfectNtripEnabled()
851+
bool pointPerfectNtripNeeded()
844852
{
845853
if (settings.pointPerfectService == PP_NICKNAME_FLEX_RTCM || settings.pointPerfectService == PP_NICKNAME_LIVE)
846854
return true;
@@ -918,7 +926,6 @@ bool productVariantNeedsPpl()
918926
return false;
919927
}
920928

921-
922929
// Given a service nick name, return whether this platform supports it
923930
// Helps with printing the menu
924931
bool productVariantSupportsService(uint8_t ppNickName)

0 commit comments

Comments
 (0)