1
0
Fork 0

Merge pull request #2713 from hughbarney/master

clkinfogps: disable debug, README updated, Lato: save a fast and slow version
master
Gordon Williams 2023-05-03 08:18:32 +01:00 committed by GitHub
commit dc7f079314
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 272 additions and 10 deletions

View File

@ -1 +1,2 @@
0.01: First version
0.02: turned off debugging

View File

@ -4,22 +4,25 @@
A clock info that displays the Ordanance Survey (OS) grid reference
- At the start of the walk update the GPS with using one of the AGPS apps. This will
significantly reduce the time to the first fix.
- I suggest installing the GPS power widget so that you can be assured
when the GPS is draining power.
- The primary use is for walking where a GPS fix that is 2 minutes old is
perfectly fine for providing an OS map grid reference.
- Saves power by only turning the GPS on for the time it takes to get a fix.
- In a static test from 100% charge the battery fell to 20% over 48 hours.
- It then switches the GPS off for 90 seconds before trying to get the next fix
- At the start of the walk update the GPS with using one of the AGPS apps. This will
significantly reduce the time to the first fix.
- Displays the GPS time and number of satelites while waiting for a fix.
- The fix is invalidated after 4 minutes and will display 00:00:00 0
or the gps time while the gps is powered on and searching for a fix.
- If the display is shows solid 00:00:00 0 then tap the clkinfo to restart it
as it will have timed out after 4 minutes
- I suggest installing the GPS power widget so that you can be assured
when the GPS is draining power.
- It is unlikley that this style of gps clock info will work well with the Recorder
app as that would hold the GPS power permantly on all the time during the
recording.
- The design is intended to be minimal so if you want to complicate matters
please fork the app.
## Screenshots

View File

@ -5,7 +5,7 @@
var geo = require("geotools");
var debug = function(o) {
console.log(o);
//console.log(o);
};
var resetLastFix = function() {
@ -49,7 +49,7 @@
};
var onGPS = function(fix) {
//console.log(fix);
debug(fix);
last_fix.time = fix.time;
// we got a fix
@ -100,20 +100,20 @@
text: gpsText()
}); },
run : function() {
console.log("run");
debug("run");
// if the timer is already runnuing reset it, we can get multiple run calls by tapping
clearTimer();
Bangle.setGPSPower(1,"clkinfo");
},
show: function () {
console.log("show");
debug("show");
resetLastFix();
fixTs = Math.round(getTime());
Bangle.on("GPS",onGPS);
this.run();
},
hide: function() {
console.log("hide");
debug("hide");
clearTimer();
Bangle.setGPSPower(0,"clkinfo");
Bangle.removeListener("GPS", onGPS);

View File

@ -1,7 +1,7 @@
{
"id": "clkinfogps",
"name": "GPS Grid Ref Clockinfo",
"version":"0.01",
"version":"0.02",
"description": "Clockinfo that displays the GPS OS Grid Reference",
"icon": "app.png",
"screenshots": [{"url":"screenshot1.png"}],

138
apps/lato/lato.fast.js Normal file

File diff suppressed because one or more lines are too long

120
apps/lato/lato.slow.js Normal file

File diff suppressed because one or more lines are too long