mirror of https://github.com/espruino/BangleApps
Save mileage adjustment
parent
5cbc826e95
commit
06b493d1ec
|
@ -10,7 +10,7 @@ Currently the app displays the following data:
|
|||
- trip distance traveled
|
||||
- total distance traveled
|
||||
|
||||
Button 1 resets all measurements except total distance traveled. The latter gets preserved by being written to storage every 0.2 miles and upon exiting the app.
|
||||
Button 1 resets all measurements except total distance traveled. The latter gets preserved by being written to storage every 0.1 miles and upon exiting the app.
|
||||
|
||||
I do not have access to a cadence sensor at the moment, so only the speed part is currently implemented. Values displayed are imperial or metric (depending on locale),
|
||||
the wheel circumference can be adjusted in the global settings app.
|
||||
|
|
|
@ -67,7 +67,7 @@ class CSCSensor {
|
|||
if (dRevs>0) {
|
||||
qChanged = true;
|
||||
this.totaldist += dRevs*this.wheelCirc/63360.0;
|
||||
if ((this.totaldist-this.settings.totaldist)>0.2) {
|
||||
if ((this.totaldist-this.settings.totaldist)>0.1) {
|
||||
this.settings.totaldist = this.totaldist;
|
||||
storage.writeJSON(SETTINGS_FILE, this.settings);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue