Final check and tidy
parent
c1b076f0c6
commit
a766807607
|
|
@ -55,7 +55,6 @@ function distance(a,b){
|
||||||
return d;
|
return d;
|
||||||
}
|
}
|
||||||
|
|
||||||
//function drawFix(speed,sats,alt,alt_units,age,fix) {
|
|
||||||
function drawFix(dat) {
|
function drawFix(dat) {
|
||||||
|
|
||||||
if (!canDraw) return;
|
if (!canDraw) return;
|
||||||
|
|
@ -240,8 +239,6 @@ function onGPS(fix) {
|
||||||
age = Math.max(0,Math.round(getTime())-(lf.time.getTime()/1000));
|
age = Math.max(0,Math.round(getTime())-(lf.time.getTime()/1000));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// {speed:,sats:,alt:,alt_units:,age:,fix:}
|
|
||||||
if ( cfg.modeA ) {
|
if ( cfg.modeA ) {
|
||||||
if ( showMax )
|
if ( showMax )
|
||||||
drawFix({
|
drawFix({
|
||||||
|
|
@ -300,10 +297,6 @@ function setButtons(){
|
||||||
onGPS(lf);
|
onGPS(lf);
|
||||||
}, BTN1, { edge:"falling",repeat:true});
|
}, BTN1, { edge:"falling",repeat:true});
|
||||||
|
|
||||||
|
|
||||||
// Show launcher when middle button pressed
|
|
||||||
// setWatch(Bangle.showLauncher, BTN2, {repeat:false,edge:"falling"});
|
|
||||||
|
|
||||||
// Power saving on/off
|
// Power saving on/off
|
||||||
setWatch(function(e){
|
setWatch(function(e){
|
||||||
pwrSav=!pwrSav;
|
pwrSav=!pwrSav;
|
||||||
|
|
@ -418,7 +411,7 @@ Bangle.on('lcdPower',function(on) {
|
||||||
|
|
||||||
var gpssetup;
|
var gpssetup;
|
||||||
try {
|
try {
|
||||||
gpssetup = require("gpssetup")
|
gpssetup = require("gpssetup");
|
||||||
} catch(e) {
|
} catch(e) {
|
||||||
gpssetup = false;
|
gpssetup = false;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue