mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2026-07-31 07:44:24 +02:00
Garmin: decode more fit fields
Message 318 contains solar charging information that could be used as a proxy for sunlight intensity (#5874).
This commit is contained in:
+90
-6
@@ -42,22 +42,40 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT8, "active_time_zone"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT32, "utc_offset"),
|
||||
new FieldDefinitionPrimitive(2, BaseType.UINT32, "time_offset", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(3, BaseType.ENUM, "summer_time_mode"),
|
||||
new FieldDefinitionPrimitive(4, BaseType.ENUM, "time_mode", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(5, BaseType.SINT8, "time_zone_offset", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(8, BaseType.UINT16, "alarms_time", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(9, BaseType.ENUM, "alarms_unk5", FieldDefinitionFactory.FIELD.ARRAY), // [5, 5]
|
||||
new FieldDefinitionPrimitive(11, BaseType.ENUM, "message_tones"),
|
||||
new FieldDefinitionPrimitive(12, BaseType.ENUM, "backlight_mode"),
|
||||
new FieldDefinitionPrimitive(13, BaseType.UINT8, "backlight_timeout"), // s
|
||||
new FieldDefinitionPrimitive(14, BaseType.UINT8, "backlight"), // %
|
||||
new FieldDefinitionPrimitive(15, BaseType.UINT8, "contrast"), // %
|
||||
new FieldDefinitionPrimitive(21, BaseType.ENUM, "gnss_mode"),
|
||||
new FieldDefinitionPrimitive(23, BaseType.ENUM, "map_orientation"),
|
||||
new FieldDefinitionPrimitive(25, BaseType.ENUM, "map_locations"),
|
||||
new FieldDefinitionPrimitive(26, BaseType.ENUM, "timezone"), // mapping ?
|
||||
new FieldDefinitionPrimitive(28, BaseType.ENUM, "alarms_enabled", FieldDefinitionFactory.FIELD.ARRAY), // [1,1]
|
||||
new FieldDefinitionPrimitive(30, BaseType.ENUM, "map_auto_zoom"),
|
||||
new FieldDefinitionPrimitive(35, BaseType.ENUM, "start_of_week"),
|
||||
new FieldDefinitionPrimitive(36, BaseType.ENUM, "activity_tracker_enabled"),
|
||||
new FieldDefinitionPrimitive(38, BaseType.ENUM, "wifi_auto_upload_enabled"),
|
||||
new FieldDefinitionPrimitive(39, BaseType.UINT32, "clock_time"),
|
||||
new FieldDefinitionPrimitive(40, BaseType.UINT16, "pages_enabled", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(42, BaseType.ENUM, "auto_max_hr"),
|
||||
new FieldDefinitionPrimitive(45, BaseType.ENUM, "auto_goal"),
|
||||
new FieldDefinitionPrimitive(46, BaseType.ENUM, "move_alert_enabled"),
|
||||
new FieldDefinitionPrimitive(47, BaseType.ENUM, "date_mode"),
|
||||
new FieldDefinitionPrimitive(53, BaseType.ENUM, "off_course_warning"),
|
||||
new FieldDefinitionPrimitive(55, BaseType.ENUM, "display_orientation"),
|
||||
new FieldDefinitionPrimitive(56, BaseType.ENUM, "mounting_side"),
|
||||
new FieldDefinitionPrimitive(57, BaseType.UINT16, "default_page", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(58, BaseType.UINT16, "autosync_min_steps"),
|
||||
new FieldDefinitionPrimitive(59, BaseType.UINT16, "autosync_min_time"),
|
||||
new FieldDefinitionPrimitive(75, BaseType.ENUM, "course_segments"),
|
||||
new FieldDefinitionPrimitive(76, BaseType.ENUM, "map_show_track"),
|
||||
new FieldDefinitionPrimitive(77, BaseType.ENUM, "map_track_color"),
|
||||
new FieldDefinitionPrimitive(80, BaseType.ENUM, "lactate_threshold_autodetect_enabled"),
|
||||
new FieldDefinitionPrimitive(86, BaseType.ENUM, "ble_auto_upload_enabled"),
|
||||
new FieldDefinitionPrimitive(89, BaseType.ENUM, "auto_sync_frequency"),
|
||||
@@ -65,8 +83,19 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(92, BaseType.UINT32Z, "alarms_repeat", FieldDefinitionFactory.FIELD.ARRAY),
|
||||
new FieldDefinitionPrimitive(94, BaseType.UINT8, "number_of_screens"),
|
||||
new FieldDefinitionPrimitive(95, BaseType.ENUM, "smart_notification_display_orientation"),
|
||||
new FieldDefinitionPrimitive(101, BaseType.ENUM, "goal_notification"),
|
||||
new FieldDefinitionPrimitive(117, BaseType.ENUM, "map_show_details"),
|
||||
new FieldDefinitionPrimitive(134, BaseType.ENUM, "tap_interface"),
|
||||
new FieldDefinitionPrimitive(174, BaseType.ENUM, "tap_sensitivity")
|
||||
new FieldDefinitionPrimitive(144, BaseType.ENUM, "activity_true_up"),
|
||||
new FieldDefinitionPrimitive(148, BaseType.ENUM, "map_show_contour"),
|
||||
new FieldDefinitionPrimitive(164, BaseType.UINT8, "hr_low_alert_limit"), // BPM
|
||||
new FieldDefinitionPrimitive(174, BaseType.ENUM, "tap_sensitivity"),
|
||||
new FieldDefinitionPrimitive(177, BaseType.UINT8, "sleep_backlight_brightness"), // %
|
||||
new FieldDefinitionPrimitive(178, BaseType.UINT8, "sleep_backlight_timeout"), // s
|
||||
new FieldDefinitionPrimitive(189, BaseType.ENUM, "screen_brightness"),
|
||||
new FieldDefinitionPrimitive(192, BaseType.ENUM, "touch_enabled"),
|
||||
new FieldDefinitionPrimitive(217, BaseType.ENUM, "gnss_default_mode"),
|
||||
new FieldDefinitionPrimitive(237, BaseType.ENUM, "stress_alert")
|
||||
));
|
||||
|
||||
public static final NativeFITMessage USER_PROFILE = new NativeFITMessage(3, "USER_PROFILE", Arrays.asList(
|
||||
@@ -101,6 +130,8 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(41, BaseType.UINT32, "time_last_lthr_update"),
|
||||
new FieldDefinitionPrimitive(47, BaseType.ENUM, "depth_setting", FieldDefinitionFactory.FIELD.MEASUREMENT_SYSTEM),
|
||||
new FieldDefinitionPrimitive(49, BaseType.UINT32, "dive_count"),
|
||||
new FieldDefinitionPrimitive(53, BaseType.UINT8, "moderate_activity"),
|
||||
new FieldDefinitionPrimitive(54, BaseType.UINT8, "vigorous_activity"),
|
||||
new FieldDefinitionPrimitive(62, BaseType.ENUM, "gender_x"),
|
||||
new FieldDefinitionPrimitive(254, BaseType.UINT16, "message_index")
|
||||
));
|
||||
@@ -193,6 +224,7 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(0, BaseType.ENUM, "sport"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.ENUM, "sub_sport"),
|
||||
new FieldDefinitionPrimitive(3, BaseType.STRING, 24, "name"),
|
||||
new FieldDefinitionPrimitive(10, BaseType.UINT8, 3, "color"),
|
||||
new FieldDefinitionPrimitive(15, BaseType.ENUM, "popularity_routing"),
|
||||
new FieldDefinitionPrimitive(17, BaseType.ENUM, "navigation_prompt"),
|
||||
new FieldDefinitionPrimitive(18, BaseType.ENUM, "sharp_bend_warnings"),
|
||||
@@ -504,10 +536,10 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(24, BaseType.ENUM, "lap_trigger"), // 0 manual
|
||||
new FieldDefinitionPrimitive(25, BaseType.ENUM, "sport"), // 5 swimming
|
||||
new FieldDefinitionPrimitive(26, BaseType.UINT8, "event_group"),
|
||||
new FieldDefinitionPrimitive(25, BaseType.SINT32, "nec_lat", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(26, BaseType.SINT32, "nec_long", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(27, BaseType.SINT32, "swc_lat", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(28, BaseType.SINT32, "swc_long", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(27, BaseType.SINT32, "nec_lat", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(28, BaseType.SINT32, "nec_long", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(29, BaseType.SINT32, "swc_lat", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(30, BaseType.SINT32, "swc_long", FieldDefinitionFactory.FIELD.COORDINATE),
|
||||
new FieldDefinitionPrimitive(32, BaseType.UINT16, "num_lengths"),
|
||||
new FieldDefinitionPrimitive(33, BaseType.UINT16, "normalized_power"), // watt
|
||||
new FieldDefinitionPrimitive(34, BaseType.UINT16, "left_right_balance"),
|
||||
@@ -601,6 +633,7 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(152, BaseType.UINT8, "execution_score"),
|
||||
new FieldDefinitionPrimitive(153, BaseType.FLOAT32, "avg_grit"),
|
||||
new FieldDefinitionPrimitive(154, BaseType.FLOAT32, "avg_flow"),
|
||||
new FieldDefinitionPrimitive(155, BaseType.UINT16, "calories"), // kcal
|
||||
new FieldDefinitionPrimitive(156, BaseType.UINT8, "total_fractional_ascent", 100, 0), // m
|
||||
new FieldDefinitionPrimitive(157, BaseType.UINT8, "total_fractional_descent", 100, 0), // m
|
||||
new FieldDefinitionPrimitive(158, BaseType.UINT16, "avg_core_temperature", 100, 0), // °C
|
||||
@@ -743,6 +776,7 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(2, BaseType.UINT8, "cadence"),
|
||||
new FieldDefinitionPrimitive(3, BaseType.UINT8, "elevation"),
|
||||
new FieldDefinitionPrimitive(4, BaseType.UINT8, "heart_rate"),
|
||||
new FieldDefinitionPrimitive(5, BaseType.ENUM, "calorie"),
|
||||
new FieldDefinitionPrimitive(6, BaseType.UINT8, "power"),
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
@@ -981,6 +1015,8 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(34, BaseType.UINT16, "vigorous_activity_minutes"),
|
||||
new FieldDefinitionPrimitive(35, BaseType.UINT32, "total_ascent", 1000, 0), // m
|
||||
new FieldDefinitionPrimitive(36, BaseType.UINT32, "total_descent", 1000, 0), // m
|
||||
new FieldDefinitionPrimitive(37, BaseType.UINT16, "moderate_activity"), // min
|
||||
new FieldDefinitionPrimitive(38, BaseType.UINT16, "vigorous_activity"), // min
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
@@ -1138,7 +1174,9 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(0, BaseType.ENUM, "metric"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.ENUM, "sport"),
|
||||
new FieldDefinitionPrimitive(2, BaseType.UINT32, "distance", 100, 0), // m
|
||||
new FieldDefinitionPrimitive(5, BaseType.UINT32, "record")
|
||||
new FieldDefinitionPrimitive(5, BaseType.UINT32, "record"),
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP),
|
||||
new FieldDefinitionPrimitive(254, BaseType.UINT16, "message_index")
|
||||
));
|
||||
|
||||
public static final NativeFITMessage CONNECTIVITY = new NativeFITMessage(127, "CONNECTIVITY", Arrays.asList(
|
||||
@@ -1203,6 +1241,12 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage FILES = new NativeFITMessage(138, "FILES", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(1, BaseType.STRING, 30, "directory"),
|
||||
new FieldDefinitionPrimitive(2, BaseType.STRING, 30, "file"),
|
||||
new FieldDefinitionPrimitive(254, BaseType.UINT16, "message_index")
|
||||
));
|
||||
|
||||
// https://github.com/GoldenCheetah/GoldenCheetah/blob/71e3928bc614f3209d9977d90cc50b942999b855/src/FileIO/FitRideFile.cpp#L1998
|
||||
public static final NativeFITMessage PHYSIOLOGICAL_METRICS = new NativeFITMessage(140, "PHYSIOLOGICAL_METRICS", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT8, "new_hr_max"), // BPM
|
||||
@@ -1369,8 +1413,10 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(21, BaseType.UINT16, "wheel_size_auto"), // mm
|
||||
new FieldDefinitionPrimitive(32, BaseType.UINT16, "product"),
|
||||
new FieldDefinitionPrimitive(33, BaseType.UINT16, "manufacturer"),
|
||||
new FieldDefinitionPrimitive(34, BaseType.UINT16, "firmware_version"),
|
||||
new FieldDefinitionPrimitive(45, BaseType.ENUM, "use_for_speed"),
|
||||
new FieldDefinitionPrimitive(46, BaseType.ENUM, "use_for_distance"),
|
||||
new FieldDefinitionPrimitive(50, BaseType.UINT8, 6, "bluetooth_address"),
|
||||
new FieldDefinitionPrimitive(51, BaseType.ENUM, "connection_type"),
|
||||
new FieldDefinitionPrimitive(52, BaseType.ENUM, "sensor_type"),
|
||||
new FieldDefinitionPrimitive(91, BaseType.STRING, "product_name"),
|
||||
@@ -1932,6 +1978,16 @@ public class NativeFITMessage {
|
||||
|
||||
));
|
||||
|
||||
public static final NativeFITMessage MONITORING_ALTITUDE = new NativeFITMessage(279, "MONITORING_ALTITUDE", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT32, "altitude", 5, 500), // m
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage ACCLIMATIZATION = new NativeFITMessage(281, "ACCLIMATIZATION", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(11, BaseType.UINT16, "altitude"), // m
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage JUMP = new NativeFITMessage(285, "JUMP", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.FLOAT32, "distance"), // m
|
||||
new FieldDefinitionPrimitive(1, BaseType.FLOAT32, "heigh"), // m
|
||||
@@ -2100,6 +2156,13 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage SOLAR_CHARGE = new NativeFITMessage(318, "SOLAR_CHARGE", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT16, "percent"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT16, "status"),
|
||||
new FieldDefinitionPrimitive(3, BaseType.UINT32, "gain"), // ms
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage TANK_UPDATE = new NativeFITMessage(319, "TANK_UPDATE", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT32Z, "sensor"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT16, "pressure", 100, 0), // bar
|
||||
@@ -2148,6 +2211,15 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(0, BaseType.FLOAT32, "value")
|
||||
));
|
||||
|
||||
public static final NativeFITMessage RACE_PREDICTION = new NativeFITMessage(339, "RACE_PREDICTION", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT32, "local_timestamp"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT16, "time_5k"), // s
|
||||
new FieldDefinitionPrimitive(2, BaseType.UINT16, "time_10k"), // s
|
||||
new FieldDefinitionPrimitive(3, BaseType.UINT16, "time_half_marathon"), // s
|
||||
new FieldDefinitionPrimitive(4, BaseType.UINT16, "time_full_marathon"), // s
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage SLEEP_STATS = new NativeFITMessage(346, "SLEEP_STATS", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT8, "combined_awake_score"),
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT8, "awake_time_score"),
|
||||
@@ -2388,6 +2460,12 @@ public class NativeFITMessage {
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage SLEEP_DEMAND = new NativeFITMessage(410, "SLEEP_DEMAND", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT16, "normal"), // min
|
||||
new FieldDefinitionPrimitive(1, BaseType.UINT16, "demand"), // min
|
||||
new FieldDefinitionPrimitive(253, BaseType.UINT32, "timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP)
|
||||
));
|
||||
|
||||
public static final NativeFITMessage NAP = new NativeFITMessage(412, "NAP", Arrays.asList(
|
||||
new FieldDefinitionPrimitive(0, BaseType.UINT32, "start_timestamp", FieldDefinitionFactory.FIELD.TIMESTAMP),
|
||||
new FieldDefinitionPrimitive(1, BaseType.SINT16, "start_tz_offset"), // min
|
||||
@@ -2483,6 +2561,7 @@ public class NativeFITMessage {
|
||||
put(129, WEATHER_ALERT);
|
||||
put(131, CADENCE_ZONE);
|
||||
put(132, HR);
|
||||
put(138, FILES);
|
||||
put(140, PHYSIOLOGICAL_METRICS);
|
||||
put(141, EPO_STATUS);
|
||||
put(142, SEGMENT_LAP);
|
||||
@@ -2544,6 +2623,8 @@ public class NativeFITMessage {
|
||||
put(274, SLEEP_DATA_RAW);
|
||||
put(268, DIVE_SUMMARY);
|
||||
put(275, SLEEP_STAGE);
|
||||
put(279, MONITORING_ALTITUDE);
|
||||
put(281, ACCLIMATIZATION);
|
||||
put(285, JUMP);
|
||||
put(289, AAD_ACCEL_FEATURES);
|
||||
put(290, BEAT_INTERVALS);
|
||||
@@ -2562,6 +2643,7 @@ public class NativeFITMessage {
|
||||
put(314, HSA_BODY_BATTERY_DATA);
|
||||
put(315, HSA_EVENT);
|
||||
put(317, CLIMB_PRO);
|
||||
put(318, SOLAR_CHARGE);
|
||||
put(319, TANK_UPDATE);
|
||||
put(321, POWER_MODE);
|
||||
put(323, TANK_SUMMARY);
|
||||
@@ -2569,6 +2651,7 @@ public class NativeFITMessage {
|
||||
put(336, ECG_SUMMARY);
|
||||
put(337, ECG_RAW_SAMPLE);
|
||||
put(338, ECG_SMOOTH_SAMPLE);
|
||||
put(339, RACE_PREDICTION);
|
||||
put(346, SLEEP_STATS);
|
||||
put(356, FUNCTIONAL_METRICS);
|
||||
put(358, RACE_EVENT);
|
||||
@@ -2591,6 +2674,7 @@ public class NativeFITMessage {
|
||||
put(402, HILL_SCORE);
|
||||
put(403, ENDURANCE_SCORE);
|
||||
put(409, HSA_WRIST_TEMPERATURE_DATA);
|
||||
put(410, SLEEP_DEMAND);
|
||||
put(412, NAP);
|
||||
put(428, WORKOUT_SCHEDULE);
|
||||
put(470, SLEEP_DISRUPTION_SEVERITY_PERIOD);
|
||||
|
||||
+80
@@ -0,0 +1,80 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitAcclimatization extends RecordData {
|
||||
public FitAcclimatization(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 281) {
|
||||
throw new IllegalArgumentException("FitAcclimatization expects native messages of " + 281 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getAltitude() {
|
||||
return getFieldByNumber(11, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(281);
|
||||
}
|
||||
|
||||
public Builder setAltitude(final Integer value) {
|
||||
setFieldByNumber(11, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitAcclimatization build() {
|
||||
return (FitAcclimatization) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitAcclimatization build(final int localMessageType) {
|
||||
return (FitAcclimatization) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+290
@@ -54,6 +54,11 @@ public class FitDeviceSettings extends RecordData {
|
||||
return getArrayFieldByNumber(2, Number.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getSummerTimeMode() {
|
||||
return getFieldByNumber(3, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Number[] getTimeMode() {
|
||||
return getArrayFieldByNumber(4, Number.class);
|
||||
@@ -74,21 +79,76 @@ public class FitDeviceSettings extends RecordData {
|
||||
return getArrayFieldByNumber(9, Number.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMessageTones() {
|
||||
return getFieldByNumber(11, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getBacklightMode() {
|
||||
return getFieldByNumber(12, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getBacklightTimeout() {
|
||||
return getFieldByNumber(13, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getBacklight() {
|
||||
return getFieldByNumber(14, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getContrast() {
|
||||
return getFieldByNumber(15, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getGnssMode() {
|
||||
return getFieldByNumber(21, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapOrientation() {
|
||||
return getFieldByNumber(23, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapLocations() {
|
||||
return getFieldByNumber(25, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTimezone() {
|
||||
return getFieldByNumber(26, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Number[] getAlarmsEnabled() {
|
||||
return getArrayFieldByNumber(28, Number.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapAutoZoom() {
|
||||
return getFieldByNumber(30, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getStartOfWeek() {
|
||||
return getFieldByNumber(35, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getActivityTrackerEnabled() {
|
||||
return getFieldByNumber(36, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getWifiAutoUploadEnabled() {
|
||||
return getFieldByNumber(38, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getClockTime() {
|
||||
return getFieldByNumber(39, Long.class);
|
||||
@@ -99,6 +159,16 @@ public class FitDeviceSettings extends RecordData {
|
||||
return getArrayFieldByNumber(40, Number.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getAutoMaxHr() {
|
||||
return getFieldByNumber(42, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getAutoGoal() {
|
||||
return getFieldByNumber(45, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMoveAlertEnabled() {
|
||||
return getFieldByNumber(46, Integer.class);
|
||||
@@ -109,6 +179,11 @@ public class FitDeviceSettings extends RecordData {
|
||||
return getFieldByNumber(47, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getOffCourseWarning() {
|
||||
return getFieldByNumber(53, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getDisplayOrientation() {
|
||||
return getFieldByNumber(55, Integer.class);
|
||||
@@ -134,6 +209,21 @@ public class FitDeviceSettings extends RecordData {
|
||||
return getFieldByNumber(59, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getCourseSegments() {
|
||||
return getFieldByNumber(75, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapShowTrack() {
|
||||
return getFieldByNumber(76, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapTrackColor() {
|
||||
return getFieldByNumber(77, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getLactateThresholdAutodetectEnabled() {
|
||||
return getFieldByNumber(80, Integer.class);
|
||||
@@ -169,16 +259,71 @@ public class FitDeviceSettings extends RecordData {
|
||||
return getFieldByNumber(95, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getGoalNotification() {
|
||||
return getFieldByNumber(101, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapShowDetails() {
|
||||
return getFieldByNumber(117, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTapInterface() {
|
||||
return getFieldByNumber(134, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getActivityTrueUp() {
|
||||
return getFieldByNumber(144, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMapShowContour() {
|
||||
return getFieldByNumber(148, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getHrLowAlertLimit() {
|
||||
return getFieldByNumber(164, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTapSensitivity() {
|
||||
return getFieldByNumber(174, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getSleepBacklightBrightness() {
|
||||
return getFieldByNumber(177, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getSleepBacklightTimeout() {
|
||||
return getFieldByNumber(178, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getScreenBrightness() {
|
||||
return getFieldByNumber(189, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTouchEnabled() {
|
||||
return getFieldByNumber(192, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getGnssDefaultMode() {
|
||||
return getFieldByNumber(217, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getStressAlert() {
|
||||
return getFieldByNumber(237, Integer.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
@@ -202,6 +347,11 @@ public class FitDeviceSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSummerTimeMode(final Integer value) {
|
||||
setFieldByNumber(3, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimeMode(final Number[] value) {
|
||||
setFieldByNumber(4, (Object[]) value);
|
||||
return this;
|
||||
@@ -222,21 +372,76 @@ public class FitDeviceSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMessageTones(final Integer value) {
|
||||
setFieldByNumber(11, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setBacklightMode(final Integer value) {
|
||||
setFieldByNumber(12, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setBacklightTimeout(final Integer value) {
|
||||
setFieldByNumber(13, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setBacklight(final Integer value) {
|
||||
setFieldByNumber(14, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setContrast(final Integer value) {
|
||||
setFieldByNumber(15, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setGnssMode(final Integer value) {
|
||||
setFieldByNumber(21, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapOrientation(final Integer value) {
|
||||
setFieldByNumber(23, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapLocations(final Integer value) {
|
||||
setFieldByNumber(25, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimezone(final Integer value) {
|
||||
setFieldByNumber(26, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setAlarmsEnabled(final Number[] value) {
|
||||
setFieldByNumber(28, (Object[]) value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapAutoZoom(final Integer value) {
|
||||
setFieldByNumber(30, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setStartOfWeek(final Integer value) {
|
||||
setFieldByNumber(35, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setActivityTrackerEnabled(final Integer value) {
|
||||
setFieldByNumber(36, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setWifiAutoUploadEnabled(final Integer value) {
|
||||
setFieldByNumber(38, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setClockTime(final Long value) {
|
||||
setFieldByNumber(39, value);
|
||||
return this;
|
||||
@@ -247,6 +452,16 @@ public class FitDeviceSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setAutoMaxHr(final Integer value) {
|
||||
setFieldByNumber(42, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setAutoGoal(final Integer value) {
|
||||
setFieldByNumber(45, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMoveAlertEnabled(final Integer value) {
|
||||
setFieldByNumber(46, value);
|
||||
return this;
|
||||
@@ -257,6 +472,11 @@ public class FitDeviceSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setOffCourseWarning(final Integer value) {
|
||||
setFieldByNumber(53, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setDisplayOrientation(final Integer value) {
|
||||
setFieldByNumber(55, value);
|
||||
return this;
|
||||
@@ -282,6 +502,21 @@ public class FitDeviceSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setCourseSegments(final Integer value) {
|
||||
setFieldByNumber(75, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapShowTrack(final Integer value) {
|
||||
setFieldByNumber(76, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapTrackColor(final Integer value) {
|
||||
setFieldByNumber(77, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setLactateThresholdAutodetectEnabled(final Integer value) {
|
||||
setFieldByNumber(80, value);
|
||||
return this;
|
||||
@@ -317,16 +552,71 @@ public class FitDeviceSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setGoalNotification(final Integer value) {
|
||||
setFieldByNumber(101, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapShowDetails(final Integer value) {
|
||||
setFieldByNumber(117, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTapInterface(final Integer value) {
|
||||
setFieldByNumber(134, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setActivityTrueUp(final Integer value) {
|
||||
setFieldByNumber(144, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMapShowContour(final Integer value) {
|
||||
setFieldByNumber(148, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setHrLowAlertLimit(final Integer value) {
|
||||
setFieldByNumber(164, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTapSensitivity(final Integer value) {
|
||||
setFieldByNumber(174, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSleepBacklightBrightness(final Integer value) {
|
||||
setFieldByNumber(177, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSleepBacklightTimeout(final Integer value) {
|
||||
setFieldByNumber(178, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setScreenBrightness(final Integer value) {
|
||||
setFieldByNumber(189, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTouchEnabled(final Integer value) {
|
||||
setFieldByNumber(192, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setGnssDefaultMode(final Integer value) {
|
||||
setFieldByNumber(217, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setStressAlert(final Integer value) {
|
||||
setFieldByNumber(237, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitDeviceSettings build() {
|
||||
return (FitDeviceSettings) super.build();
|
||||
|
||||
+10
@@ -64,6 +64,11 @@ public class FitDeviceUsed extends RecordData {
|
||||
return getFieldByNumber(4, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getCalorie() {
|
||||
return getFieldByNumber(5, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getPower() {
|
||||
return getFieldByNumber(6, Integer.class);
|
||||
@@ -107,6 +112,11 @@ public class FitDeviceUsed extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setCalorie(final Integer value) {
|
||||
setFieldByNumber(5, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setPower(final Integer value) {
|
||||
setFieldByNumber(6, value);
|
||||
return this;
|
||||
|
||||
+90
@@ -0,0 +1,90 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitFiles extends RecordData {
|
||||
public FitFiles(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 138) {
|
||||
throw new IllegalArgumentException("FitFiles expects native messages of " + 138 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public String getDirectory() {
|
||||
return getFieldByNumber(1, String.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public String getFile() {
|
||||
return getFieldByNumber(2, String.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMessageIndex() {
|
||||
return getFieldByNumber(254, Integer.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(138);
|
||||
}
|
||||
|
||||
public Builder setDirectory(final String value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setFile(final String value) {
|
||||
setFieldByNumber(2, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMessageIndex(final Integer value) {
|
||||
setFieldByNumber(254, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitFiles build() {
|
||||
return (FitFiles) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitFiles build(final int localMessageType) {
|
||||
return (FitFiles) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+80
@@ -0,0 +1,80 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitGnssMonitor extends RecordData {
|
||||
public FitGnssMonitor(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 325) {
|
||||
throw new IllegalArgumentException("FitGnssMonitor expects native messages of " + 325 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTracked() {
|
||||
return getFieldByNumber(0, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(325);
|
||||
}
|
||||
|
||||
public Builder setTracked(final Integer value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitGnssMonitor build() {
|
||||
return (FitGnssMonitor) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitGnssMonitor build(final int localMessageType) {
|
||||
return (FitGnssMonitor) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+32
-22
@@ -177,24 +177,24 @@ public class FitLap extends RecordData {
|
||||
|
||||
@Nullable
|
||||
public Double getNecLat() {
|
||||
return getFieldByNumber(25, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getNecLong() {
|
||||
return getFieldByNumber(26, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getSwcLat() {
|
||||
return getFieldByNumber(27, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getSwcLong() {
|
||||
public Double getNecLong() {
|
||||
return getFieldByNumber(28, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getSwcLat() {
|
||||
return getFieldByNumber(29, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getSwcLong() {
|
||||
return getFieldByNumber(30, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getNumLengths() {
|
||||
return getFieldByNumber(32, Integer.class);
|
||||
@@ -660,6 +660,11 @@ public class FitLap extends RecordData {
|
||||
return getFieldByNumber(154, Float.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getCalories() {
|
||||
return getFieldByNumber(155, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Float getTotalFractionalAscent() {
|
||||
return getFieldByNumber(156, Float.class);
|
||||
@@ -874,25 +879,25 @@ public class FitLap extends RecordData {
|
||||
}
|
||||
|
||||
public Builder setNecLat(final Double value) {
|
||||
setFieldByNumber(25, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setNecLong(final Double value) {
|
||||
setFieldByNumber(26, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSwcLat(final Double value) {
|
||||
setFieldByNumber(27, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSwcLong(final Double value) {
|
||||
public Builder setNecLong(final Double value) {
|
||||
setFieldByNumber(28, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSwcLat(final Double value) {
|
||||
setFieldByNumber(29, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setSwcLong(final Double value) {
|
||||
setFieldByNumber(30, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setNumLengths(final Integer value) {
|
||||
setFieldByNumber(32, value);
|
||||
return this;
|
||||
@@ -1358,6 +1363,11 @@ public class FitLap extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setCalories(final Integer value) {
|
||||
setFieldByNumber(155, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTotalFractionalAscent(final Float value) {
|
||||
setFieldByNumber(156, value);
|
||||
return this;
|
||||
|
||||
+90
@@ -0,0 +1,90 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitMetricsInfo extends RecordData {
|
||||
public FitMetricsInfo(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 241) {
|
||||
throw new IllegalArgumentException("FitMetricsInfo expects native messages of " + 241 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getLocalTimestamp() {
|
||||
return getFieldByNumber(0, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTrainingPaused() {
|
||||
return getFieldByNumber(1, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(241);
|
||||
}
|
||||
|
||||
public Builder setLocalTimestamp(final Long value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTrainingPaused(final Integer value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitMetricsInfo build() {
|
||||
return (FitMetricsInfo) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitMetricsInfo build(final int localMessageType) {
|
||||
return (FitMetricsInfo) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+80
@@ -0,0 +1,80 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitMonitorAltitude extends RecordData {
|
||||
public FitMonitorAltitude(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 279) {
|
||||
throw new IllegalArgumentException("FitMonitorAltitude expects native messages of " + 279 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getAltitude() {
|
||||
return getFieldByNumber(0, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(279);
|
||||
}
|
||||
|
||||
public Builder setAltitude(final Double value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitMonitorAltitude build() {
|
||||
return (FitMonitorAltitude) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitMonitorAltitude build(final int localMessageType) {
|
||||
return (FitMonitorAltitude) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+20
@@ -192,6 +192,16 @@ public class FitMonitoring extends RecordData {
|
||||
return getFieldByNumber(36, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getModerateActivity() {
|
||||
return getFieldByNumber(37, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getVigorousActivity() {
|
||||
return getFieldByNumber(38, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
@@ -355,6 +365,16 @@ public class FitMonitoring extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setModerateActivity(final Integer value) {
|
||||
setFieldByNumber(37, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setVigorousActivity(final Integer value) {
|
||||
setFieldByNumber(38, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
|
||||
+80
@@ -0,0 +1,80 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitMonitoringAltitude extends RecordData {
|
||||
public FitMonitoringAltitude(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 279) {
|
||||
throw new IllegalArgumentException("FitMonitoringAltitude expects native messages of " + 279 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Double getAltitude() {
|
||||
return getFieldByNumber(0, Double.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(279);
|
||||
}
|
||||
|
||||
public Builder setAltitude(final Double value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitMonitoringAltitude build() {
|
||||
return (FitMonitoringAltitude) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitMonitoringAltitude build(final int localMessageType) {
|
||||
return (FitMonitoringAltitude) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+20
@@ -59,6 +59,16 @@ public class FitPersonalRecord extends RecordData {
|
||||
return getFieldByNumber(5, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getMessageIndex() {
|
||||
return getFieldByNumber(254, Integer.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
@@ -87,6 +97,16 @@ public class FitPersonalRecord extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setMessageIndex(final Integer value) {
|
||||
setFieldByNumber(254, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitPersonalRecord build() {
|
||||
return (FitPersonalRecord) super.build();
|
||||
|
||||
+120
@@ -0,0 +1,120 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitRacePrediction extends RecordData {
|
||||
public FitRacePrediction(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 339) {
|
||||
throw new IllegalArgumentException("FitRacePrediction expects native messages of " + 339 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getLocalTimestamp() {
|
||||
return getFieldByNumber(0, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTime5k() {
|
||||
return getFieldByNumber(1, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTime10k() {
|
||||
return getFieldByNumber(2, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTimeHalfMarathon() {
|
||||
return getFieldByNumber(3, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTimeFullMarathon() {
|
||||
return getFieldByNumber(4, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(339);
|
||||
}
|
||||
|
||||
public Builder setLocalTimestamp(final Long value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTime5k(final Integer value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTime10k(final Integer value) {
|
||||
setFieldByNumber(2, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimeHalfMarathon(final Integer value) {
|
||||
setFieldByNumber(3, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimeFullMarathon(final Integer value) {
|
||||
setFieldByNumber(4, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitRacePrediction build() {
|
||||
return (FitRacePrediction) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitRacePrediction build(final int localMessageType) {
|
||||
return (FitRacePrediction) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+120
@@ -0,0 +1,120 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitRacePredictions extends RecordData {
|
||||
public FitRacePredictions(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 339) {
|
||||
throw new IllegalArgumentException("FitRacePredictions expects native messages of " + 339 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getLocalTimestamp() {
|
||||
return getFieldByNumber(0, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTime5k() {
|
||||
return getFieldByNumber(1, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTime10k() {
|
||||
return getFieldByNumber(2, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTimeHalfMarathon() {
|
||||
return getFieldByNumber(3, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getTimeFullMarathon() {
|
||||
return getFieldByNumber(4, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(339);
|
||||
}
|
||||
|
||||
public Builder setLocalTimestamp(final Long value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTime5k(final Integer value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTime10k(final Integer value) {
|
||||
setFieldByNumber(2, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimeHalfMarathon(final Integer value) {
|
||||
setFieldByNumber(3, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimeFullMarathon(final Integer value) {
|
||||
setFieldByNumber(4, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitRacePredictions build() {
|
||||
return (FitRacePredictions) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitRacePredictions build(final int localMessageType) {
|
||||
return (FitRacePredictions) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+6
@@ -92,6 +92,7 @@ public class FitRecordDataFactory {
|
||||
case 129 -> new FitWeatherAlert(recordDefinition, recordHeader);
|
||||
case 131 -> new FitCadenceZone(recordDefinition, recordHeader);
|
||||
case 132 -> new FitHr(recordDefinition, recordHeader);
|
||||
case 138 -> new FitFiles(recordDefinition, recordHeader);
|
||||
case 140 -> new FitPhysiologicalMetrics(recordDefinition, recordHeader);
|
||||
case 141 -> new FitEpoStatus(recordDefinition, recordHeader);
|
||||
case 142 -> new FitSegmentLap(recordDefinition, recordHeader);
|
||||
@@ -153,6 +154,8 @@ public class FitRecordDataFactory {
|
||||
case 273 -> new FitSleepDataInfo(recordDefinition, recordHeader);
|
||||
case 274 -> new FitSleepDataRaw(recordDefinition, recordHeader);
|
||||
case 275 -> new FitSleepStage(recordDefinition, recordHeader);
|
||||
case 279 -> new FitMonitoringAltitude(recordDefinition, recordHeader);
|
||||
case 281 -> new FitAcclimatization(recordDefinition, recordHeader);
|
||||
case 285 -> new FitJump(recordDefinition, recordHeader);
|
||||
case 289 -> new FitAadAccelFeatures(recordDefinition, recordHeader);
|
||||
case 290 -> new FitBeatIntervals(recordDefinition, recordHeader);
|
||||
@@ -171,6 +174,7 @@ public class FitRecordDataFactory {
|
||||
case 314 -> new FitHsaBodyBatteryData(recordDefinition, recordHeader);
|
||||
case 315 -> new FitHsaEvent(recordDefinition, recordHeader);
|
||||
case 317 -> new FitClimbPro(recordDefinition, recordHeader);
|
||||
case 318 -> new FitSolarCharge(recordDefinition, recordHeader);
|
||||
case 319 -> new FitTankUpdate(recordDefinition, recordHeader);
|
||||
case 321 -> new FitPowerMode(recordDefinition, recordHeader);
|
||||
case 323 -> new FitTankSummary(recordDefinition, recordHeader);
|
||||
@@ -178,6 +182,7 @@ public class FitRecordDataFactory {
|
||||
case 336 -> new FitEcgSummary(recordDefinition, recordHeader);
|
||||
case 337 -> new FitEcgRawSample(recordDefinition, recordHeader);
|
||||
case 338 -> new FitEcgSmoothSample(recordDefinition, recordHeader);
|
||||
case 339 -> new FitRacePrediction(recordDefinition, recordHeader);
|
||||
case 346 -> new FitSleepStats(recordDefinition, recordHeader);
|
||||
case 356 -> new FitFunctionalMetrics(recordDefinition, recordHeader);
|
||||
case 358 -> new FitRaceEvent(recordDefinition, recordHeader);
|
||||
@@ -200,6 +205,7 @@ public class FitRecordDataFactory {
|
||||
case 402 -> new FitHillScore(recordDefinition, recordHeader);
|
||||
case 403 -> new FitEnduranceScore(recordDefinition, recordHeader);
|
||||
case 409 -> new FitHsaWristTemperatureData(recordDefinition, recordHeader);
|
||||
case 410 -> new FitSleepDemand(recordDefinition, recordHeader);
|
||||
case 412 -> new FitNap(recordDefinition, recordHeader);
|
||||
case 428 -> new FitWorkoutSchedule(recordDefinition, recordHeader);
|
||||
case 470 -> new FitSleepDisruptionSeverityPeriod(recordDefinition, recordHeader);
|
||||
|
||||
+20
@@ -74,6 +74,11 @@ public class FitSensorSettings extends RecordData {
|
||||
return getFieldByNumber(33, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getFirmwareVersion() {
|
||||
return getFieldByNumber(34, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getUseForSpeed() {
|
||||
return getFieldByNumber(45, Integer.class);
|
||||
@@ -84,6 +89,11 @@ public class FitSensorSettings extends RecordData {
|
||||
return getFieldByNumber(46, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getBluetoothAddress() {
|
||||
return getFieldByNumber(50, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getConnectionType() {
|
||||
return getFieldByNumber(51, Integer.class);
|
||||
@@ -147,6 +157,11 @@ public class FitSensorSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setFirmwareVersion(final Integer value) {
|
||||
setFieldByNumber(34, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setUseForSpeed(final Integer value) {
|
||||
setFieldByNumber(45, value);
|
||||
return this;
|
||||
@@ -157,6 +172,11 @@ public class FitSensorSettings extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setBluetoothAddress(final Integer value) {
|
||||
setFieldByNumber(50, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setConnectionType(final Integer value) {
|
||||
setFieldByNumber(51, value);
|
||||
return this;
|
||||
|
||||
+90
@@ -0,0 +1,90 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitSleepDemand extends RecordData {
|
||||
public FitSleepDemand(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 410) {
|
||||
throw new IllegalArgumentException("FitSleepDemand expects native messages of " + 410 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getNormal() {
|
||||
return getFieldByNumber(0, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getDemand() {
|
||||
return getFieldByNumber(1, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(410);
|
||||
}
|
||||
|
||||
public Builder setNormal(final Integer value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setDemand(final Integer value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitSleepDemand build() {
|
||||
return (FitSleepDemand) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitSleepDemand build(final int localMessageType) {
|
||||
return (FitSleepDemand) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+90
@@ -0,0 +1,90 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitSleepNeed extends RecordData {
|
||||
public FitSleepNeed(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 410) {
|
||||
throw new IllegalArgumentException("FitSleepNeed expects native messages of " + 410 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getNormal() {
|
||||
return getFieldByNumber(0, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getNeed() {
|
||||
return getFieldByNumber(1, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(410);
|
||||
}
|
||||
|
||||
public Builder setNormal(final Integer value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setNeed(final Integer value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitSleepNeed build() {
|
||||
return (FitSleepNeed) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitSleepNeed build(final int localMessageType) {
|
||||
return (FitSleepNeed) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+100
@@ -0,0 +1,100 @@
|
||||
/* Copyright (C) 2026 Freeyourgadget
|
||||
|
||||
This file is part of Gadgetbridge.
|
||||
|
||||
Gadgetbridge is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
Gadgetbridge is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>. */
|
||||
package nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.messages;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.FitRecordDataBuilder;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordData;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordDefinition;
|
||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.RecordHeader;
|
||||
|
||||
/**
|
||||
* WARNING: This class was auto-generated, please avoid modifying it directly.
|
||||
* See {@link nodomain.freeyourgadget.gadgetbridge.service.devices.garmin.fit.codegen.FitCodeGen}
|
||||
*
|
||||
* @noinspection unused
|
||||
*/
|
||||
public class FitSolarCharge extends RecordData {
|
||||
public FitSolarCharge(final RecordDefinition recordDefinition, final RecordHeader recordHeader) {
|
||||
super(recordDefinition, recordHeader);
|
||||
|
||||
final int nativeNumber = recordDefinition.getNativeFITMessage().getNumber();
|
||||
if (nativeNumber != 318) {
|
||||
throw new IllegalArgumentException("FitSolarCharge expects native messages of " + 318 + ", got " + nativeNumber);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getPercent() {
|
||||
return getFieldByNumber(0, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getStatus() {
|
||||
return getFieldByNumber(1, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getGain() {
|
||||
return getFieldByNumber(3, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Long getTimestamp() {
|
||||
return getFieldByNumber(253, Long.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* @noinspection unused
|
||||
*/
|
||||
public static class Builder extends FitRecordDataBuilder {
|
||||
public Builder() {
|
||||
super(318);
|
||||
}
|
||||
|
||||
public Builder setPercent(final Integer value) {
|
||||
setFieldByNumber(0, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setStatus(final Integer value) {
|
||||
setFieldByNumber(1, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setGain(final Long value) {
|
||||
setFieldByNumber(3, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setTimestamp(final Long value) {
|
||||
setFieldByNumber(253, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitSolarCharge build() {
|
||||
return (FitSolarCharge) super.build();
|
||||
}
|
||||
|
||||
@Override
|
||||
public FitSolarCharge build(final int localMessageType) {
|
||||
return (FitSolarCharge) super.build(localMessageType);
|
||||
}
|
||||
}
|
||||
}
|
||||
+10
@@ -54,6 +54,11 @@ public class FitSport extends RecordData {
|
||||
return getFieldByNumber(3, String.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getColor() {
|
||||
return getFieldByNumber(10, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getPopularityRouting() {
|
||||
return getFieldByNumber(15, Integer.class);
|
||||
@@ -112,6 +117,11 @@ public class FitSport extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setColor(final Integer value) {
|
||||
setFieldByNumber(10, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setPopularityRouting(final Integer value) {
|
||||
setFieldByNumber(15, value);
|
||||
return this;
|
||||
|
||||
+20
@@ -196,6 +196,16 @@ public class FitUserProfile extends RecordData {
|
||||
return getFieldByNumber(49, Long.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getModerateActivity() {
|
||||
return getFieldByNumber(53, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getVigorousActivity() {
|
||||
return getFieldByNumber(54, Integer.class);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Integer getGenderX() {
|
||||
return getFieldByNumber(62, Integer.class);
|
||||
@@ -369,6 +379,16 @@ public class FitUserProfile extends RecordData {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setModerateActivity(final Integer value) {
|
||||
setFieldByNumber(53, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setVigorousActivity(final Integer value) {
|
||||
setFieldByNumber(54, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder setGenderX(final Integer value) {
|
||||
setFieldByNumber(62, value);
|
||||
return this;
|
||||
|
||||
Reference in New Issue
Block a user