Class: Toybox.FitContributor.Field
- Inherits:
-
Toybox.Lang.Object
Overview
A Field records custom FIT data from an Application or Data Field to a FIT file on the device's file system.
Once a Field is created with the createField() method, you can submit the next Field value with setData(), which will get written to the FIT file at the next opportunity. Depending on the device, writes to the FIT file may occur once per second or when new data is available (Smart Recording). Best practice is to only call setData() when values have changed to accommodate Smart Recording.
If setData() is called before the previous data is written out, the previous value will be lost and replaced by the current data. For this reason, we do not recommend using this feature for time-sensitive data requiring sub-second granularity.
See Also:
Instance Method Summary collapse
-
setData(input as Lang.Object) as Void
Set the value to write to this Field.
Instance Method Details
setData(input as Lang.Object) as Void
Set the value to write to this Field.