mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge.git
synced 2025-01-25 16:15:55 +01:00
makibes hr3 should now support the english version
This commit is contained in:
parent
2c718ecd01
commit
45184c4bbc
@ -216,7 +216,7 @@ public final class MakibesHR3Constants {
|
||||
public static final byte ARG_SEND_NOTIFICATION_SOURCE_WEIBO = (byte) 0x13;
|
||||
public static final byte ARG_SEND_NOTIFICATION_SOURCE_KAKOTALK = (byte) 0x14;
|
||||
// ARG_SET_NOTIFICATION_SOURCE_*
|
||||
// 02 (This is 00 and 01 during connection. I don't know what it does. Maybe clears notifications?)
|
||||
// 02 (This is 00 and 01 during connection. Doesn't seem to do anything.)
|
||||
// ASCII
|
||||
public static final byte CMD_SEND_NOTIFICATION = (byte) 0x72;
|
||||
|
||||
|
@ -18,7 +18,9 @@ package nodomain.freeyourgadget.gadgetbridge.devices.makibeshr3;
|
||||
|
||||
import java.text.DateFormat;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.List;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
@ -145,9 +147,15 @@ public class MakibesHR3Coordinator extends AbstractDeviceCoordinator {
|
||||
public DeviceType getSupportedType(GBDeviceCandidate candidate) {
|
||||
String name = candidate.getDevice().getName();
|
||||
|
||||
// TODO: Device discovery
|
||||
if ((name != null) && name.equals("Y808")) {
|
||||
return DeviceType.MAKIBESHR3;
|
||||
List<String> deviceNames = new ArrayList<String>(){{
|
||||
add("Y808"); // Chinese version
|
||||
add("MAKIBES HR3"); // English version
|
||||
}};
|
||||
|
||||
if (name != null) {
|
||||
if (deviceNames.contains(name)) {
|
||||
return DeviceType.MAKIBESHR3;
|
||||
}
|
||||
}
|
||||
|
||||
return DeviceType.UNKNOWN;
|
||||
|
Loading…
Reference in New Issue
Block a user