Zepp OS: Map some unknown menu items and shortcut cards

This commit is contained in:
José Rebelo
2025-06-29 16:32:49 +01:00
parent cb5e611fbf
commit 5df1e0b467
5 changed files with 13 additions and 3 deletions
@@ -25,7 +25,7 @@ public class ZeppOsMenuType {
* These somewhat match the ones in HuamiMenuType, but not all. The band sends and
* receives those as 8-digit upper case hex strings.
*/
public static final Map<String, String> displayItemNameLookup = new HashMap<String, String>() {{
public static final Map<String, String> displayItemNameLookup = new HashMap<>() {{
put("00000001", "personal_activity_intelligence");
put("00000002", "hr");
put("00000003", "workout");
@@ -81,9 +81,11 @@ public class ZeppOsMenuType {
put("000F4258", "real_time_heart_rate");
put("000F4263", "watch_storage_space");
put("000F4259", "water_time");
put("000F653B", "meditation");
put("0010660A", "zepp_flow");
}};
public static final Map<String, String> shortcutsNameLookup = new HashMap<String, String>() {{
public static final Map<String, String> shortcutsNameLookup = new HashMap<>() {{
put("00000001", "hr");
put("00000002", "weather");
put("00000003", "pai");
@@ -313,7 +313,7 @@ public class ZeppOsSupport extends AbstractDeviceSupport
}
}
LOG.warn("Unhandled config {}, will pass to HuamiSupport", config);
LOG.warn("Unhandled config {}", config);
super.onSendConfiguration(config);
}
@@ -93,6 +93,7 @@ public class ZeppOsShortcutCardsService extends AbstractZeppOsService {
ZEPP_PAY("37", "1"),
CALORIES("38", "1"),
HRV("1047865", "1"),
ZEPP_FLOW("1074698", "1"),
;
private final String appNum;
+6
View File
@@ -1103,6 +1103,8 @@
<item>@string/menuitem_real_time_heart_rate</item>
<item>@string/menuitem_watch_storage_space</item>
<item>@string/menuitem_water_time</item>
<item>@string/activity_type_meditation</item>
<item>@string/menuitem_zepp_flow</item>
<!-- dummy item -->
<item>@string/menuitem_more</item>
</string-array>
@@ -1166,6 +1168,8 @@
<item>real_time_heart_rate</item>
<item>watch_storage_space</item>
<item>water_time</item>
<item>meditation</item>
<item>zepp_flow</item>
<!-- dummy item -->
<item>more</item>
</string-array>
@@ -1206,6 +1210,7 @@
<item>@string/menuitem_workout_shortcuts</item>
<item>@string/menuitem_apps_shortcuts</item>
<item>@string/menuitem_alexa</item>
<item>@string/menuitem_zepp_flow</item>
</string-array>
<string-array name="pref_zepp_os_shortcut_cards_values">
@@ -1244,6 +1249,7 @@
<item>workout_shortcuts</item>
<item>apps_shortcuts</item>
<item>alexa</item>
<item>zepp_flow</item>
</string-array>
<string-array name="pref_huami2021_control_center">
+1
View File
@@ -2123,6 +2123,7 @@
<string name="menuitem_mutephone">Mute Phone</string>
<string name="menuitem_takephoto">Camera Remote</string>
<string name="menuitem_alexa">Alexa</string>
<string name="menuitem_zepp_flow">Zepp Flow</string>
<string name="menuitem_dnd">DND</string>
<string name="menuitem_stopwatch">Stopwatch</string>
<string name="menuitem_goal">Activity Goal</string>