Skip to content

Commit

Permalink
Version 1.34
Browse files Browse the repository at this point in the history
  • Loading branch information
gcormier9 committed Apr 8, 2022
1 parent f86b0d5 commit 5646e4f
Show file tree
Hide file tree
Showing 7 changed files with 87 additions and 7 deletions.
25 changes: 24 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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 | | ✓ | ✓ | ✓ |
Expand Down Expand Up @@ -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.

Expand Down
5 changes: 3 additions & 2 deletions monkey.jungle
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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
Expand Down Expand Up @@ -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
Expand Down Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion resources/settings/properties.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<properties>
<property id="AppVersion" type="string">1.33</property>
<property id="AppVersion" type="string">1.34</property>
<property id="HeaderHeight" type="number">30</property>
<property id="SingleBackgroundColor" type="boolean">false</property>
<property id="LapDistance" type="number">0</property>
Expand Down
2 changes: 1 addition & 1 deletion resources/strings/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<string id="PARAM_TARGET_PACE">Target Pace (in seconds per km or mile)</string>
<string id="PARAM_DESC_TARGET_PACE">Example: 330 for 5min and 30sec (km/mile is chosen automatically based on watch settings</string>
<string id="PARAM_PACE_RANGE">Pace Range (in seconds)</string>
<string id="PARAM_PACE_RANGE">Pace Range (+/- in seconds)</string>
<string id="PARAM_DESC_PACE_RANGE">Use to display speed/pace in color if outside the range</string>

<string id="PARAM_LAP_DISTANCE">Lap Distance (in meters)</string>
Expand Down
56 changes: 56 additions & 0 deletions source-highmem-fr245m/GRunApp.mc
Original file line number Diff line number Diff line change
@@ -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 ];
}
}
2 changes: 1 addition & 1 deletion source-lowmem-fr245/GRunApp.mc
Original file line number Diff line number Diff line change
Expand Up @@ -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();
}
Expand Down
2 changes: 1 addition & 1 deletion source/GRunView.mc
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 5646e4f

Please sign in to comment.