mirror of
https://github.com/richonguzman/LoRa_APRS_iGate.git
synced 2026-03-17 10:44:47 +01:00
gps distance correction with different overlay
This commit is contained in:
parent
9ce8fe6d97
commit
09eacd652d
|
|
@ -160,10 +160,14 @@ String getReceivedGPS(String packet) {
|
||||||
}
|
}
|
||||||
|
|
||||||
String getDistance(String packet) {
|
String getDistance(String packet) {
|
||||||
if (packet.indexOf(":!/") > 10) {
|
int gpsIndexEx = packet.indexOf(":!");
|
||||||
return decodeEncodedGPS(packet);
|
int gpsIndexEq = packet.indexOf(":=");
|
||||||
} else if (packet.indexOf(":=") > 10 || packet.indexOf(":!") > 10) {
|
if (gpsIndexEx > 10 || gpsIndexEq > 10) {
|
||||||
return getReceivedGPS(packet);
|
if ((gpsIndexEx + 15 == packet.indexOf("G")) || (gpsIndexEx + 15 == packet.indexOf("Q")) || (gpsIndexEq + 15 == packet.indexOf("G")) || (gpsIndexEq + 15 == packet.indexOf("Q"))) {
|
||||||
|
return decodeEncodedGPS(packet);
|
||||||
|
} else {
|
||||||
|
return getReceivedGPS(packet);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
return " _ / _ / _ ";
|
return " _ / _ / _ ";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue