diff --git a/README.md b/README.md index 2319fdd..ad80d99 100644 --- a/README.md +++ b/README.md @@ -130,7 +130,7 @@ High-Memory devices also supports the following fields: | fenixchronos | fÄ“nix Chronos | 28.7 KB | ✓ | | ✓ | ✓ | | fr55 | Forerunner 55 | 28.7 KB | ✓ | | | | | fr245 | Forerunner 245 | 28.7 KB | ✓ | | ✓ | | -| fr245m | Forerunner 245 Music | 28.7 KB | ✓ | | ✓ | | +| fr245m | Forerunner 245 Music | 124.7 KB | | ✓ | ✓ | ✓ | | fr645 | Forerunner 645 | 28.7 KB | ✓ | | ✓ | | | fr645m | Forerunner 645 Music | 60.7 KB | | ✓ | ✓ | | | fr745 | Forerunner 745 | 124.7 KB | | ✓ | ✓ | ✓ | @@ -288,6 +288,29 @@ Calculate the vertical speed in meter/min or feet/min depending on the watch set ## Release Notes +### Version 1.34 + - fr245m was listed has a low memory device, instead of high-memory device. + - Display average cadence using `info.averageCadence * 2` to workaround Garmin CIQ + +| Memory Usage on va3 (28.6 KB) | Current | Peak | +| --------------------------------- |:-------:|:-------:| +| At startup | 25.5 kB | 27.3 kB | +| 10 sec running | 25.5 kB | 27.7 kB | +| After setting change | 25.5 kB | 28.4 kB | + +| Memory Usage on fenix5 (28.6 KB) | Current | Peak | +| --------------------------------- |:-------:|:-------:| +| At startup | 25.5 kB | 27.4 kB | +| 10 sec running | 25.5 kB | 27.8 kB | +| After setting change | 25.5 kB | 28.4 kB | + + +| Memory Usage on fr945 (124.6 KB) | Current | Peak | +| --------------------------------- |:-------:|:-------:| +| At startup | 30.6 kB | 32.8 kB | +| 10 sec running | 30.6 kB | 33.1 kB | +| After setting change | 30.6 kB | 33.8 kB | + ### Version 1.33 - Version 1.32 was invalid as I forgot to remove troubleshooting code. diff --git a/monkey.jungle b/monkey.jungle index 51a018e..fb20a9b 100644 --- a/monkey.jungle +++ b/monkey.jungle @@ -52,6 +52,8 @@ fenix6pro.sourcePath = source;source-highmem;source-highmem-fenix6pro fenix6spro.sourcePath = source;source-highmem;source-highmem-fenix6xpro fenix6xpro.sourcePath = source;source-highmem;source-highmem-fenix6xpro +fr245m.sourcePath = source;source-highmem;source-highmem-fr245m + # High Memory (60.7 KB) fr645m.sourcePath = source;source-highmem;source-highmem-fr645m fr745.sourcePath = source;source-highmem;source-highmem-fr945 @@ -66,7 +68,6 @@ fenix5s.sourcePath = source;source-lowmem-fenix5s fenixchronos.sourcePath = source;source-lowmem-fenixchronos fr55.sourcePath = source;source-lowmem-fr55 fr245.sourcePath = source;source-lowmem-fr245 -fr245m.sourcePath = source;source-lowmem-fr245 fr645.sourcePath = source;source-lowmem-fr645 fr935.sourcePath = source;source-lowmem-fr645 vivoactive3.sourcePath = source;source-lowmem-vivoactive3 @@ -116,6 +117,7 @@ fenix5plus.resourcePath = resources;resources-highmem;resources-highmem-power fenix5splus.resourcePath = resources;resources-highmem;resources-highmem-power # High Memory (60.7 KB) with "Training Effect" support +fr245m.resourcePath = resources;resources-highmem;resources-highmem-te fr645m.resourcePath = resources;resources-highmem;resources-highmem-te # High Memory (124.7 KB) with "Power" and "Training Effect" support @@ -169,7 +171,6 @@ edge130plus.resourcePath = resources;resources-lowmem-power # Low Memory (28.7 KB) with "Training Effect" support fr245.resourcePath = resources;resources-lowmem-te -fr245m.resourcePath = resources;resources-lowmem-te fr645.resourcePath = resources;resources-lowmem-te # Low Memory (28.7 KB) with "Power" and "Training Effect" support diff --git a/resources/settings/properties.xml b/resources/settings/properties.xml index 0285552..6d5bbe0 100644 --- a/resources/settings/properties.xml +++ b/resources/settings/properties.xml @@ -1,5 +1,5 @@ - 1.33 + 1.34 30 false 0 diff --git a/resources/strings/strings.xml b/resources/strings/strings.xml index 35e4e29..774f870 100644 --- a/resources/strings/strings.xml +++ b/resources/strings/strings.xml @@ -4,7 +4,7 @@ Target Pace (in seconds per km or mile) Example: 330 for 5min and 30sec (km/mile is chosen automatically based on watch settings - Pace Range (in seconds) + Pace Range (+/- in seconds) Use to display speed/pace in color if outside the range Lap Distance (in meters) diff --git a/source-highmem-fr245m/GRunApp.mc b/source-highmem-fr245m/GRunApp.mc new file mode 100644 index 0000000..a60a870 --- /dev/null +++ b/source-highmem-fr245m/GRunApp.mc @@ -0,0 +1,56 @@ +using Toybox.Application; +using Toybox.Graphics; + + +class GRunApp extends Application.AppBase +{ + protected var gRunView; + + function initialize() + { + //System.println("Garmin Forerunner 245m (High Memory)"); + AppBase.initialize(); + gRunView = new GRunViewHighMem(); + } + + + public static function getTextDimensions(dc, value, font) + { + var textDimensions = dc.getTextDimensions(value, font); + + var yFactor = 1.9; + if (font < 7) + { + textDimensions[0] += 2; + + if (font < 5) { yFactor = 1.4; } + else { yFactor = 1.6; } + } + + textDimensions[1] = textDimensions[1] - (yFactor * dc.getFontDescent(font)); + return textDimensions; + } + + + public static function getYOffset(font) + { + var yOffset = -2; + if (font >= 7) { yOffset = -4; } + if (font == 1) { yOffset = -1; } + + return yOffset; + } + + + function onSettingsChanged() + { + AppBase.onSettingsChanged(); + gRunView.initializeUserData(); + } + + + function getInitialView() + { + return [ gRunView ]; + } +} \ No newline at end of file diff --git a/source-lowmem-fr245/GRunApp.mc b/source-lowmem-fr245/GRunApp.mc index 56cb8f7..f87c7ce 100644 --- a/source-lowmem-fr245/GRunApp.mc +++ b/source-lowmem-fr245/GRunApp.mc @@ -8,7 +8,7 @@ class GRunApp extends Application.AppBase function initialize() { - //System.println("Garmin Forerunner 245/245m (Low Memory)"); + //System.println("Garmin Forerunner 245/245 (Low Memory)"); AppBase.initialize(); gRunView = new GRunView(); } diff --git a/source/GRunView.mc b/source/GRunView.mc index 67a25b5..ba63eef 100644 --- a/source/GRunView.mc +++ b/source/GRunView.mc @@ -605,7 +605,7 @@ class GRunView extends WatchUi.DataField // Average cadence during the current activity in revolutions per minute (rpm) if ( (value == 33 /* OPTION_AVERAGE_CADENCE */) && (info.averageCadence != null) ) { - return info.averageCadence; + return info.averageCadence * 2; } // Calculate if we are ahead of behing the target pace