I like to record data into the FIT and show them in graph. The related codes below.
I see the data's in the FIT file (with fitviewer) and also with the Garmin's Monkey graph. The app in the store in beta status, the setting is working well but not the graph. I am officialy out of ideas , maybe someone found the problem in my code or have idea, what is wrong. I think I dig enough without step forward.
I do not like to make a public version yet, so that is the last step that I wanna try.
The XML file:
<fitContributions> <fitField id="0" displayInChart="true" sortOrder="0" precision="0" chartTitle="@Strings.fitChartTitle0" dataLabel="@Strings.fitDataLabel0" unitLabel="@Strings.fitUnitLabel0" fillColor="#00ff37" /> <fitField id="1" displayInChart="true" sortOrder="1" precision="2" chartTitle="@Strings.fitChartTitle1" dataLabel="@Strings.fitDataLabel1" unitLabel="@Strings.fitUnitLabel1" fillColor="#ff00c8" /> </fitContributions>
The AppView
_fitGears = createField( WatchUi.loadResource(Rez.Strings.fitChartTitle0).toString(), 0, FitContributor.DATA_TYPE_UINT32, { :mesgType => FitContributor.MESG_TYPE_RECORD, :units => WatchUi.loadResource(Rez.Strings.fitUnitLabel0).toString(), } ); _fitRatio = createField( WatchUi.loadResource(Rez.Strings.fitChartTitle1).toString(), 1, FitContributor.DATA_TYPE_FLOAT, { :mesgType => FitContributor.MESG_TYPE_RECORD, :units => WatchUi.loadResource(Rez.Strings.fitUnitLabel1).toString(), } ); _fitGears.setData(0); _fitRatio.setData(0.0);
The data is refreshing from compute()