diff --git a/apps/waypoints/waypoints.app.js b/apps/waypoints/waypoints.app.js index e45649827b3..0d1ce063462 100644 --- a/apps/waypoints/waypoints.app.js +++ b/apps/waypoints/waypoints.app.js @@ -335,8 +335,7 @@ function mainMenu() { } function updateGps() { - let have = false, lat = "lat ", alt = "?", - speed = "speed ", hdop = "?"; + let lat = "lat ", alt = "?"; if (cancel_gps) return; @@ -347,7 +346,6 @@ function updateGps() { alt = "" + fix.alt.toFixed(0); // speed = "" + fix.speed.toFixed(1); // hdop = "" + fix.hdop.toFixed(0); - have = true; } else { lat = "NO FIX\n" + "" + (getTime() - gps_start).toFixed(0) + "s "; @@ -364,8 +362,7 @@ function updateGps() { } function updateGoto() { - let have = false, lat = "lat ", alt = "?", - speed = "speed ", hdop = "?"; + let have = false, lat = "lat ", alt = "?"; if (cancel_gps) return; @@ -603,6 +600,7 @@ var s, res; function askCoordinate(t1, t2, callback) { //let sign = 1; ask01(t1, function(sign) { + let d, m, s; switch (fmt.geo_mode) { case 0: s = "DDD.dddd"; break; case 1: s = "DDD MM.mmm"; break; @@ -614,14 +612,14 @@ function askCoordinate(t1, t2, callback) { res = parseFloat(key); break; case 1: - let d = parseInt(key.substr(0, 3)); - let m = parseFloat(key.substr(3,99)); + d = parseInt(key.substr(0, 3)); + m = parseFloat(key.substr(3,99)); res = d + m/60.0; break; case 2: d = parseInt(key.substr(0, 3)); m = parseInt(key.substr(4, 2)); - let s = parseInt(key.substr(7, 2)); + s = parseInt(key.substr(7, 2)); res = d + m/60.0 + s/3600.0; } res = sign * res;