1
0
Fork 0

Update app.js

master
nujw 2021-10-22 11:16:13 +13:00 committed by GitHub
parent e797480d16
commit 4088f7ec76
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 9 deletions

View File

@ -5,7 +5,7 @@ Mike Bennett mike[at]kereru.com
0.06 : Add Posn screen 0.06 : Add Posn screen
0.07 : Add swipe to change screens same as BTN3 0.07 : Add swipe to change screens same as BTN3
*/ */
var v = '1.03'; var v = '1.04';
/*kalmanjs, Wouter Bulten, MIT, https://github.com/wouterbulten/kalmanjs */ /*kalmanjs, Wouter Bulten, MIT, https://github.com/wouterbulten/kalmanjs */
var KalmanFilter = (function () { var KalmanFilter = (function () {
@ -621,17 +621,13 @@ Bangle.on('lcdPower',function(on) {
}); });
Bangle.on('swipe',function(dir) { Bangle.on('swipe',function(dir) {
if(dir == 1) { if(dir == 1) prevScrn();
console.log('RIGHT'); else nextScrn();
prevScrn();
}
else {
console.log('LEFT');
nextScrn();
}
}); });
Bangle.on('touch', function(button){ Bangle.on('touch', function(button){
nextFunc(0); // Same function as short BTN1
/*
switch(button){ switch(button){
case 1: // BTN4 case 1: // BTN4
console.log('BTN4'); console.log('BTN4');
@ -646,9 +642,11 @@ console.log('MDL');
nextFunc(0); // Centre - same function as short BTN1 nextFunc(0); // Centre - same function as short BTN1
break; break;
} }
*/
}); });
// == Main Prog // == Main Prog
// Read settings. // Read settings.