Skip to content

Commit

Permalink
Compass now uses falling edge for reset function so exiting app doesn…
Browse files Browse the repository at this point in the history
…'t reset it - #2832
  • Loading branch information
gfwilliams committed Jun 22, 2023
1 parent f98d678 commit 93b40bb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions apps/compass/ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
0.06: Add button for force compass calibration
0.07: Use 360-heading to output the correct heading value (fix #1866)
0.08: Added adjustment for Bangle.js magnetometer heading fix
0.09: use falling edge of button to reset compass (allows exit without compass reset)
2 changes: 1 addition & 1 deletion apps/compass/compass.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ g.clear(1);
g.setFont("6x8").setFontAlign(0,0,3).drawString(/*LANG*/"RESET", g.getWidth()-5, g.getHeight()/2);
setWatch(function() {
Bangle.resetCompass();
}, (process.env.HWVERSION==2) ? BTN1 : BTN2, {repeat:true});
}, (process.env.HWVERSION==2) ? BTN1 : BTN2, {repeat:true, edge:"falling"});

Bangle.loadWidgets();
Bangle.drawWidgets();
Expand Down
2 changes: 1 addition & 1 deletion apps/compass/metadata.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "compass",
"name": "Compass",
"version": "0.08",
"version": "0.09",
"description": "Simple compass that points North",
"icon": "compass.png",
"screenshots": [{"url":"screenshot_compass.png"}],
Expand Down

0 comments on commit 93b40bb

Please sign in to comment.