Skip to content

Commit 6296ca8

Browse files
committed
Modify CFGPROT for LG290P firmware 6 - see #747
1 parent 7b974ca commit 6296ca8

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

Firmware/RTK_Everywhere/GNSS_LG290P.ino

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -601,8 +601,13 @@ bool GNSS_LG290P::enterConfigMode(unsigned long waitForSemaphoreTimeout_millis)
601601
} while (isBlocking && ((millis() - start) < waitForSemaphoreTimeout_millis));
602602

603603
// This will fail if the library is still blocking, but it is worth a punt...
604-
return (_lg290p->sendOkCommand("$PQTMCFGPROT",
605-
",W,1,2,00000000,00000000")); // Disable NMEA and RTCM on the LG290P UART2
604+
605+
if (lg290pFirmwareVersion >= 6) // See #747
606+
// Disable NMEA and RTCM on the LG290P UART2, but leave the undocumented Bit 1 enabled
607+
return (_lg290p->sendOkCommand("$PQTMCFGPROT", ",W,1,2,00000007,00000002"));
608+
609+
// Disable NMEA and RTCM on the LG290P UART2
610+
return (_lg290p->sendOkCommand("$PQTMCFGPROT", ",W,1,2,00000000,00000000"));
606611
}
607612
return (false);
608613
}
@@ -613,8 +618,14 @@ bool GNSS_LG290P::enterConfigMode(unsigned long waitForSemaphoreTimeout_millis)
613618
bool GNSS_LG290P::exitConfigMode()
614619
{
615620
if (online.gnss)
616-
return (_lg290p->sendOkCommand("$PQTMCFGPROT",
617-
",W,1,2,00000005,00000005")); // Enable NMEA and RTCM on the LG290P UART2
621+
{
622+
if (lg290pFirmwareVersion >= 6) // See #747
623+
// Enable NMEA and RTCM on the LG290P UART2, plus the undocumented Bit 1
624+
return (_lg290p->sendOkCommand("$PQTMCFGPROT", ",W,1,2,00000007,00000007"));
625+
626+
// Enable NMEA and RTCM on the LG290P UART2
627+
return (_lg290p->sendOkCommand("$PQTMCFGPROT", ",W,1,2,00000005,00000005"));
628+
}
618629
return (false);
619630
}
620631

0 commit comments

Comments
 (0)