mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2026-07-31 07:44:24 +02:00
Zepp OS: Movement evaluation support in workout summary
This commit is contained in:
committed by
José Rebelo
parent
4d0c496b8d
commit
11cea14088
+11
@@ -287,6 +287,17 @@ object ActivitySummaryGroup {
|
||||
)
|
||||
)
|
||||
|
||||
// Movement Evaluation
|
||||
put(
|
||||
ActivitySummaryEntries.GROUP_MOVEMENT_EVALUATION, listOf<String>(
|
||||
ActivitySummaryEntries.MOVEMENT_CONSISTENCY,
|
||||
ActivitySummaryEntries.MOVEMENT_STABILITY,
|
||||
ActivitySummaryEntries.MOVEMENT_CONTINUITY,
|
||||
ActivitySummaryEntries.MOVEMENT_RHYTHM,
|
||||
ActivitySummaryEntries.MOVEMENT_SPEED_DECAY,
|
||||
)
|
||||
)
|
||||
|
||||
// Other
|
||||
put(
|
||||
ActivitySummaryEntries.GROUP_OTHER, listOf<String>(
|
||||
|
||||
+8
@@ -220,6 +220,14 @@ public class ZeppOsActivitySummaryParser extends HuamiActivitySummaryParser {
|
||||
summaryData.add(SWOLF_INDEX, summaryProto.getSwimmingData().getSwolf(), UNIT_NONE);
|
||||
}
|
||||
|
||||
if(summaryProto.hasMovementEvaluation()) {
|
||||
summaryData.add(MOVEMENT_CONSISTENCY, summaryProto.getMovementEvaluation().getConsistency(), UNIT_NONE);
|
||||
summaryData.add(MOVEMENT_STABILITY, summaryProto.getMovementEvaluation().getStability(), UNIT_NONE);
|
||||
summaryData.add(MOVEMENT_CONTINUITY, summaryProto.getMovementEvaluation().getContinuity(), UNIT_NONE);
|
||||
summaryData.add(MOVEMENT_RHYTHM, summaryProto.getMovementEvaluation().getRhythm(), UNIT_NONE);
|
||||
summaryData.add(MOVEMENT_SPEED_DECAY, summaryProto.getMovementEvaluation().getSpeedDecay(), UNIT_NONE);
|
||||
}
|
||||
|
||||
if (forDetails && !StringUtils.isBlank(summary.getRawDetailsPath())) {
|
||||
try {
|
||||
enrichWithDetails(summary);
|
||||
|
||||
+8
@@ -179,6 +179,13 @@ public class ActivitySummaryEntries {
|
||||
public static final String CYCLING_POWER_MIN = "cyclingPowerMin";
|
||||
public static final String CYCLING_POWER_MAX = "cyclingPowerMax";
|
||||
|
||||
|
||||
public static final String MOVEMENT_CONSISTENCY = "movementConsistency";
|
||||
public static final String MOVEMENT_STABILITY = "movementStability";
|
||||
public static final String MOVEMENT_CONTINUITY = "movementContinuity";
|
||||
public static final String MOVEMENT_RHYTHM = "movementRhythm";
|
||||
public static final String MOVEMENT_SPEED_DECAY = "movementSpeedDecay";
|
||||
|
||||
public static final String SETS = "workoutSets";
|
||||
public static final String REPETITIONS = "workout_repetitions";
|
||||
public static final String REVOLUTIONS = "workout_revolutions";
|
||||
@@ -252,6 +259,7 @@ public class ActivitySummaryEntries {
|
||||
public static final String GROUP_INTERVALS = "workout_intervals";
|
||||
public static final String GROUP_DIVING = "activity_type_diving";
|
||||
public static final String GROUP_RECOVERY_HEART_RATE = "recovery_heart_rate";
|
||||
public static final String GROUP_MOVEMENT_EVALUATION = "movement_evaluation";
|
||||
public static final String AVG_DEPTH = "diving_avg_depth";
|
||||
public static final String START_CNS = "diving_start_cns";
|
||||
public static final String END_CNS = "diving_end_cns";
|
||||
|
||||
@@ -18,6 +18,7 @@ message WorkoutSummary {
|
||||
TrainingEffect trainingEffect = 21;
|
||||
HeartRateZones heartRateZones = 22;
|
||||
Elevation elevation = 23;
|
||||
MovementEvaluation movementEvaluation = 42;
|
||||
}
|
||||
|
||||
message Location {
|
||||
@@ -109,3 +110,11 @@ message SwimmingData {
|
||||
uint32 laneLength = 8;
|
||||
uint32 laneLengthUnit = 9; // 0: meter, 1: yard
|
||||
}
|
||||
|
||||
message MovementEvaluation {
|
||||
float consistency = 1;
|
||||
float stability = 2;
|
||||
float continuity = 3;
|
||||
float rhythm = 4;
|
||||
float speedDecay = 5;
|
||||
}
|
||||
@@ -4404,4 +4404,10 @@
|
||||
<string name="pref_huawei_arterial_stiffness_detection">Arterial stiffness detection</string>
|
||||
<string name="pref_huawei_arterial_stiffness_detection_enable_title">Enable arterial stiffness detection</string>
|
||||
<string name="pref_huawei_arterial_stiffness_detection_enable_summary">Activate arterial stiffness detection on the device</string>
|
||||
<string name="movementConsistency">Consistency</string>
|
||||
<string name="movementStability">Stability</string>
|
||||
<string name="movementContinuity">Continuity</string>
|
||||
<string name="movementRhythm">Rhythm</string>
|
||||
<string name="movementSpeedDecay">Speed decay</string>
|
||||
<string name="movement_evaluation">Movement Evaluation</string>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user