mirror of
https://github.com/richonguzman/LoRa_APRS_iGate.git
synced 2026-08-07 09:22:57 +02:00
gps distance correction with different overlay
This commit is contained in:
+8
-4
@@ -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 " _ / _ / _ ";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user