mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-12-02 23:12:57 +01:00
Core: replaced device initialization logic with class based decision
Core: cleaned up imports Device management: try single-argument-constructor first Device management: fixed wrong device support class Device management: added missing initial flags for Mi band 2 HRX Device management: removed unused import Device management: removed unused import Device management: improved exception handling Device management: prevent constructors from being optimized out Device management: added UnknownDeviceSupport
This commit is contained in:
parent
d273e6652b
commit
e36bd2eae7
6
app/proguard-rules.pro
vendored
6
app/proguard-rules.pro
vendored
@ -26,6 +26,12 @@
|
|||||||
-keepclassmembers class nodomain.freeyourgadget.gadgetbridge.service.btle.GattCharacteristic {
|
-keepclassmembers class nodomain.freeyourgadget.gadgetbridge.service.btle.GattCharacteristic {
|
||||||
public static *;
|
public static *;
|
||||||
}
|
}
|
||||||
|
# Keep constructors for support classes, as they're called by reflection in DeviceSupportFactory#createServiceDeviceSupport
|
||||||
|
-keep public class * extends nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport
|
||||||
|
-keepclassmembers class * extends nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport {
|
||||||
|
public <init>(nodomain.freeyourgadget.gadgetbridge.model.DeviceType);
|
||||||
|
public <init>();
|
||||||
|
}
|
||||||
-keepattributes JavascriptInterface
|
-keepattributes JavascriptInterface
|
||||||
|
|
||||||
# https://github.com/tony19/logback-android/issues/29
|
# https://github.com/tony19/logback-android/issues/29
|
||||||
|
@ -35,6 +35,7 @@ import java.io.IOException;
|
|||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.EnumSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import de.greenrobot.dao.query.QueryBuilder;
|
import de.greenrobot.dao.query.QueryBuilder;
|
||||||
@ -61,6 +62,8 @@ import nodomain.freeyourgadget.gadgetbridge.model.PaiSample;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.model.SleepRespiratoryRateSample;
|
import nodomain.freeyourgadget.gadgetbridge.model.SleepRespiratoryRateSample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.Spo2Sample;
|
import nodomain.freeyourgadget.gadgetbridge.model.Spo2Sample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.StressSample;
|
import nodomain.freeyourgadget.gadgetbridge.model.StressSample;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
import static nodomain.freeyourgadget.gadgetbridge.GBApplication.getPrefs;
|
import static nodomain.freeyourgadget.gadgetbridge.GBApplication.getPrefs;
|
||||||
@ -459,4 +462,9 @@ public abstract class AbstractDeviceCoordinator implements DeviceCoordinator {
|
|||||||
public boolean supportsNavigation() {
|
public boolean supportsNavigation() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,7 @@ import android.net.Uri;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
|
import java.util.EnumSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
@ -46,6 +47,8 @@ import nodomain.freeyourgadget.gadgetbridge.model.PaiSample;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.model.SleepRespiratoryRateSample;
|
import nodomain.freeyourgadget.gadgetbridge.model.SleepRespiratoryRateSample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.Spo2Sample;
|
import nodomain.freeyourgadget.gadgetbridge.model.Spo2Sample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.StressSample;
|
import nodomain.freeyourgadget.gadgetbridge.model.StressSample;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This interface is implemented at least once for every supported gadget device.
|
* This interface is implemented at least once for every supported gadget device.
|
||||||
@ -555,4 +558,9 @@ public interface DeviceCoordinator {
|
|||||||
List<HeartRateCapability.MeasurementInterval> getHeartRateMeasurementIntervals();
|
List<HeartRateCapability.MeasurementInterval> getHeartRateMeasurementIntervals();
|
||||||
|
|
||||||
boolean supportsNavigation();
|
boolean supportsNavigation();
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
Class<? extends DeviceSupport> getDeviceSupportClass();
|
||||||
|
|
||||||
|
EnumSet<ServiceDeviceSupport.Flags> getInitialFlags();
|
||||||
}
|
}
|
||||||
|
@ -34,6 +34,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivityKind;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivityKind;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.unknown.UnknownDeviceSupport;
|
||||||
|
|
||||||
public class UnknownDeviceCoordinator extends AbstractDeviceCoordinator {
|
public class UnknownDeviceCoordinator extends AbstractDeviceCoordinator {
|
||||||
private final UnknownSampleProvider sampleProvider;
|
private final UnknownSampleProvider sampleProvider;
|
||||||
@ -210,4 +212,10 @@ public class UnknownDeviceCoordinator extends AbstractDeviceCoordinator {
|
|||||||
public int[] getColorPresets() {
|
public int[] getColorPresets() {
|
||||||
return new int[0];
|
return new int[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return UnknownDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -27,6 +27,7 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.asteroidos.AsteroidOSDeviceSupport;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.asteroidos.AsteroidOSDeviceSupport;
|
||||||
|
|
||||||
public class AsteroidOSDeviceCoordinator extends AbstractDeviceCoordinator {
|
public class AsteroidOSDeviceCoordinator extends AbstractDeviceCoordinator {
|
||||||
@ -156,4 +157,10 @@ public class AsteroidOSDeviceCoordinator extends AbstractDeviceCoordinator {
|
|||||||
public boolean supportsMusicInfo() {
|
public boolean supportsMusicInfo() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AsteroidOSDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -44,6 +44,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.banglejs.BangleJSDeviceSupport;
|
||||||
|
|
||||||
public class BangleJSCoordinator extends AbstractBLEDeviceCoordinator {
|
public class BangleJSCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
|
|
||||||
@ -225,4 +227,10 @@ public class BangleJSCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
public boolean supportsNavigation() {
|
public boolean supportsNavigation() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return BangleJSDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -24,6 +24,7 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.binary_sensor.BinarySensorSupport;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.binary_sensor.BinarySensorSupport;
|
||||||
|
|
||||||
public class BinarySensorCoordinator extends AbstractBLEDeviceCoordinator {
|
public class BinarySensorCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@ -150,6 +151,12 @@ public class BinarySensorCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return BinarySensorSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_NONE;
|
return BONDING_STYLE_NONE;
|
||||||
|
@ -38,6 +38,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.casio.gb6900.CasioGB6900DeviceSupport;
|
||||||
|
|
||||||
public class CasioGB6900DeviceCoordinator extends CasioDeviceCoordinator {
|
public class CasioGB6900DeviceCoordinator extends CasioDeviceCoordinator {
|
||||||
protected static final Logger LOG = LoggerFactory.getLogger(CasioGB6900DeviceCoordinator.class);
|
protected static final Logger LOG = LoggerFactory.getLogger(CasioGB6900DeviceCoordinator.class);
|
||||||
@ -153,4 +155,10 @@ public class CasioGB6900DeviceCoordinator extends CasioDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return CasioGB6900DeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -42,6 +42,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.casio.gbx100.CasioGBX100DeviceSupport;
|
||||||
|
|
||||||
public class CasioGBX100DeviceCoordinator extends CasioDeviceCoordinator {
|
public class CasioGBX100DeviceCoordinator extends CasioDeviceCoordinator {
|
||||||
protected static final Logger LOG = LoggerFactory.getLogger(CasioGBX100DeviceCoordinator.class);
|
protected static final Logger LOG = LoggerFactory.getLogger(CasioGBX100DeviceCoordinator.class);
|
||||||
@ -167,4 +169,10 @@ public class CasioGBX100DeviceCoordinator extends CasioDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return CasioGBX100DeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -41,6 +41,8 @@ import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
|||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.casio.CasioConstants;
|
import nodomain.freeyourgadget.gadgetbridge.devices.casio.CasioConstants;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.casio.CasioDeviceCoordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.casio.CasioDeviceCoordinator;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.casio.gwb5600.CasioGWB5600DeviceSupport;
|
||||||
|
|
||||||
public class CasioGWB5600DeviceCoordinator extends CasioDeviceCoordinator {
|
public class CasioGWB5600DeviceCoordinator extends CasioDeviceCoordinator {
|
||||||
|
|
||||||
@ -96,6 +98,12 @@ public class CasioGWB5600DeviceCoordinator extends CasioDeviceCoordinator {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return CasioGWB5600DeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
public InstallHandler findInstallHandler(Uri uri, Context context) {
|
||||||
return null;
|
return null;
|
||||||
|
@ -23,6 +23,8 @@ import android.net.Uri;
|
|||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
|
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.AbstractBLEDeviceCoordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.AbstractBLEDeviceCoordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
|
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
|
||||||
@ -32,6 +34,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.domyos.DomyosT540Support;
|
||||||
|
|
||||||
public class DomyosT540Coordinator extends AbstractBLEDeviceCoordinator {
|
public class DomyosT540Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -129,6 +134,17 @@ public class DomyosT540Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return DomyosT540Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
||||||
// nothing to delete, yet
|
// nothing to delete, yet
|
||||||
|
@ -29,6 +29,8 @@ import androidx.annotation.Nullable;
|
|||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import de.greenrobot.dao.query.QueryBuilder;
|
import de.greenrobot.dao.query.QueryBuilder;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.GBException;
|
import nodomain.freeyourgadget.gadgetbridge.GBException;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.R;
|
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||||
@ -42,6 +44,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.fitpro.FitProDeviceSupport;
|
||||||
|
|
||||||
public class FitProDeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
public class FitProDeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(FitProDeviceCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(FitProDeviceCoordinator.class);
|
||||||
@ -188,4 +193,15 @@ public class FitProDeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return FitProDeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -19,6 +19,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.flipper.zero.support.FlipperZeroSupport;
|
||||||
|
|
||||||
public class FlipperZeroCoordinator extends AbstractBLEDeviceCoordinator {
|
public class FlipperZeroCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -111,6 +113,12 @@ public class FlipperZeroCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return FlipperZeroSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_NONE;
|
return BONDING_STYLE_NONE;
|
||||||
|
@ -15,6 +15,8 @@ import nodomain.freeyourgadget.gadgetbridge.entities.DaoSession;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.entities.Device;
|
import nodomain.freeyourgadget.gadgetbridge.entities.Device;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.galaxy_buds.GalaxyBudsDeviceSupport;
|
||||||
|
|
||||||
public abstract class GalaxyBudsGenericCoordinator extends AbstractBLClassicDeviceCoordinator {
|
public abstract class GalaxyBudsGenericCoordinator extends AbstractBLClassicDeviceCoordinator {
|
||||||
|
|
||||||
@ -111,4 +113,9 @@ public abstract class GalaxyBudsGenericCoordinator extends AbstractBLClassicDevi
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return GalaxyBudsDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -52,6 +52,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivityUser;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivityUser;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.hplus.HPlusSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.GBPrefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.GBPrefs;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
@ -328,5 +331,10 @@ public class HPlusCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return HPlusSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -33,6 +33,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitband5.AmazfitBand5Support;
|
||||||
|
|
||||||
public class AmazfitBand5Coordinator extends HuamiCoordinator {
|
public class AmazfitBand5Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBand5Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBand5Coordinator.class);
|
||||||
@ -160,6 +162,12 @@ public class AmazfitBand5Coordinator extends HuamiCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBand5Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_REQUIRE_KEY;
|
return BONDING_STYLE_REQUIRE_KEY;
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitband7.AmazfitBand7Support;
|
||||||
|
|
||||||
public class AmazfitBand7Coordinator extends Huami2021Coordinator {
|
public class AmazfitBand7Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBand7Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBand7Coordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitBand7Coordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITBAND7;
|
return DeviceType.AMAZFITBAND7;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBand7Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitBand7FWInstallHandler(uri, context);
|
return new AmazfitBand7FWInstallHandler(uri, context);
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip.AmazfitBipSupport;
|
||||||
|
|
||||||
public class AmazfitBipCoordinator extends HuamiCoordinator {
|
public class AmazfitBipCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipCoordinator.class);
|
||||||
@ -99,4 +101,10 @@ public class AmazfitBipCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBipSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -31,6 +31,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip3pro.AmazfitBip3ProSupport;
|
||||||
|
|
||||||
public class AmazfitBip3ProCoordinator extends HuamiCoordinator {
|
public class AmazfitBip3ProCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBip3ProCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBip3ProCoordinator.class);
|
||||||
@ -166,4 +168,10 @@ public class AmazfitBip3ProCoordinator extends HuamiCoordinator {
|
|||||||
"zh_TW",
|
"zh_TW",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBip3ProSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip5.AmazfitBip5Support;
|
||||||
|
|
||||||
public class AmazfitBip5Coordinator extends Huami2021Coordinator {
|
public class AmazfitBip5Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBip5Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBip5Coordinator.class);
|
||||||
@ -40,6 +42,12 @@ public class AmazfitBip5Coordinator extends Huami2021Coordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBip5Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbips.AmazfitBipSSupport;
|
||||||
|
|
||||||
public class AmazfitBipSCoordinator extends HuamiCoordinator {
|
public class AmazfitBipSCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipSCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipSCoordinator.class);
|
||||||
@ -116,6 +118,12 @@ public class AmazfitBipSCoordinator extends HuamiCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBipSSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_REQUIRE_KEY;
|
return BONDING_STYLE_REQUIRE_KEY;
|
||||||
|
@ -33,6 +33,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbipu.AmazfitBipUSupport;
|
||||||
|
|
||||||
public class AmazfitBipUCoordinator extends HuamiCoordinator {
|
public class AmazfitBipUCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipUCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipUCoordinator.class);
|
||||||
@ -164,6 +166,12 @@ public class AmazfitBipUCoordinator extends HuamiCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBipUSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_REQUIRE_KEY;
|
return BONDING_STYLE_REQUIRE_KEY;
|
||||||
|
@ -33,6 +33,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbipupro.AmazfitBipUProSupport;
|
||||||
|
|
||||||
public class AmazfitBipUProCoordinator extends HuamiCoordinator {
|
public class AmazfitBipUProCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipUProCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitBipUProCoordinator.class);
|
||||||
@ -155,6 +157,12 @@ public class AmazfitBipUProCoordinator extends HuamiCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitBipUProSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_REQUIRE_KEY;
|
return BONDING_STYLE_REQUIRE_KEY;
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcheetahpro.AmazfitCheetahProSupport;
|
||||||
|
|
||||||
public class AmazfitCheetahProCoordinator extends Huami2021Coordinator {
|
public class AmazfitCheetahProCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCheetahProCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCheetahProCoordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitCheetahProCoordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITCHEETAHPRO;
|
return DeviceType.AMAZFITCHEETAHPRO;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitCheetahProSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitCheetahProFWInstallHandler(uri, context);
|
return new AmazfitCheetahProFWInstallHandler(uri, context);
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcheetahround.AmazfitCheetahRoundSupport;
|
||||||
|
|
||||||
public class AmazfitCheetahRoundCoordinator extends Huami2021Coordinator {
|
public class AmazfitCheetahRoundCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCheetahRoundCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCheetahRoundCoordinator.class);
|
||||||
@ -40,6 +42,12 @@ public class AmazfitCheetahRoundCoordinator extends Huami2021Coordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitCheetahRoundSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcheetahsquare.AmazfitCheetahSquareSupport;
|
||||||
|
|
||||||
public class AmazfitCheetahSquareCoordinator extends Huami2021Coordinator {
|
public class AmazfitCheetahSquareCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCheetahSquareCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCheetahSquareCoordinator.class);
|
||||||
@ -40,6 +42,12 @@ public class AmazfitCheetahSquareCoordinator extends Huami2021Coordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitCheetahSquareSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcor.AmazfitCorSupport;
|
||||||
|
|
||||||
public class AmazfitCorCoordinator extends HuamiCoordinator {
|
public class AmazfitCorCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCorCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCorCoordinator.class);
|
||||||
@ -107,4 +109,10 @@ public class AmazfitCorCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitCorSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcor2.AmazfitCor2Support;
|
||||||
|
|
||||||
public class AmazfitCor2Coordinator extends HuamiCoordinator {
|
public class AmazfitCor2Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCor2Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitCor2Coordinator.class);
|
||||||
@ -109,4 +111,10 @@ public class AmazfitCor2Coordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitCor2Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitfalcon.AmazfitFalconSupport;
|
||||||
|
|
||||||
public class AmazfitFalconCoordinator extends Huami2021Coordinator {
|
public class AmazfitFalconCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitFalconCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitFalconCoordinator.class);
|
||||||
@ -40,6 +42,12 @@ public class AmazfitFalconCoordinator extends Huami2021Coordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitFalconSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr.AmazfitGTRSupport;
|
||||||
|
|
||||||
public class AmazfitGTRCoordinator extends HuamiCoordinator {
|
public class AmazfitGTRCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTRCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTRCoordinator.class);
|
||||||
@ -109,4 +111,10 @@ public class AmazfitGTRCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTRSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr.AmazfitGTRLiteSupport;
|
||||||
|
|
||||||
public class AmazfitGTRLiteCoordinator extends HuamiCoordinator {
|
public class AmazfitGTRLiteCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTRLiteCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTRLiteCoordinator.class);
|
||||||
@ -107,4 +109,10 @@ public class AmazfitGTRLiteCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTRLiteSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr2.AmazfitGTR2Support;
|
||||||
|
|
||||||
public class AmazfitGTR2Coordinator extends HuamiCoordinator {
|
public class AmazfitGTR2Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR2Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR2Coordinator.class);
|
||||||
@ -114,4 +116,10 @@ public class AmazfitGTR2Coordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTR2Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr2.AmazfitGTR2eSupport;
|
||||||
|
|
||||||
public class AmazfitGTR2eCoordinator extends HuamiCoordinator {
|
public class AmazfitGTR2eCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR2eCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR2eCoordinator.class);
|
||||||
@ -114,4 +116,10 @@ public class AmazfitGTR2eCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTR2eSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr3.AmazfitGTR3Support;
|
||||||
|
|
||||||
public class AmazfitGTR3Coordinator extends Huami2021Coordinator {
|
public class AmazfitGTR3Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR3Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR3Coordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitGTR3Coordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITGTR3;
|
return DeviceType.AMAZFITGTR3;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTR3Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitGTR3FWInstallHandler(uri, context);
|
return new AmazfitGTR3FWInstallHandler(uri, context);
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr3pro.AmazfitGTR3ProSupport;
|
||||||
|
|
||||||
public class AmazfitGTR3ProCoordinator extends Huami2021Coordinator {
|
public class AmazfitGTR3ProCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR3ProCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR3ProCoordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitGTR3ProCoordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITGTR3PRO;
|
return DeviceType.AMAZFITGTR3PRO;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTR3ProSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitGTR3ProFWInstallHandler(uri, context);
|
return new AmazfitGTR3ProFWInstallHandler(uri, context);
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr4.AmazfitGTR4Support;
|
||||||
|
|
||||||
public class AmazfitGTR4Coordinator extends Huami2021Coordinator {
|
public class AmazfitGTR4Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR4Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTR4Coordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitGTR4Coordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITGTR4;
|
return DeviceType.AMAZFITGTR4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTR4Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitGTR4FWInstallHandler(uri, context);
|
return new AmazfitGTR4FWInstallHandler(uri, context);
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtrmini.AmazfitGTRMiniSupport;
|
||||||
|
|
||||||
public class AmazfitGTRMiniCoordinator extends Huami2021Coordinator {
|
public class AmazfitGTRMiniCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTRMiniCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTRMiniCoordinator.class);
|
||||||
@ -40,6 +42,12 @@ public class AmazfitGTRMiniCoordinator extends Huami2021Coordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTRMiniSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
||||||
|
@ -31,6 +31,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts.AmazfitGTSSupport;
|
||||||
|
|
||||||
public class AmazfitGTSCoordinator extends HuamiCoordinator {
|
public class AmazfitGTSCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTSCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTSCoordinator.class);
|
||||||
@ -108,4 +110,10 @@ public class AmazfitGTSCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTSSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts2.AmazfitGTS2Support;
|
||||||
|
|
||||||
public class AmazfitGTS2Coordinator extends HuamiCoordinator {
|
public class AmazfitGTS2Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS2Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS2Coordinator.class);
|
||||||
@ -114,4 +116,10 @@ public class AmazfitGTS2Coordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTS2Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts2.AmazfitGTS2eSupport;
|
||||||
|
|
||||||
public class AmazfitGTS2eCoordinator extends HuamiCoordinator {
|
public class AmazfitGTS2eCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS2eCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS2eCoordinator.class);
|
||||||
@ -114,4 +116,10 @@ public class AmazfitGTS2eCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTS2eSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts3.AmazfitGTS3Support;
|
||||||
|
|
||||||
public class AmazfitGTS3Coordinator extends Huami2021Coordinator {
|
public class AmazfitGTS3Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS3Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS3Coordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitGTS3Coordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITGTS3;
|
return DeviceType.AMAZFITGTS3;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTS3Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitGTS3FWInstallHandler(uri, context);
|
return new AmazfitGTS3FWInstallHandler(uri, context);
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts4.AmazfitGTS4Support;
|
||||||
|
|
||||||
public class AmazfitGTS4Coordinator extends Huami2021Coordinator {
|
public class AmazfitGTS4Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS4Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS4Coordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitGTS4Coordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITGTS4;
|
return DeviceType.AMAZFITGTS4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTS4Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitGTS4FWInstallHandler(uri, context);
|
return new AmazfitGTS4FWInstallHandler(uri, context);
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts4mini.AmazfitGTS4MiniSupport;
|
||||||
|
|
||||||
public class AmazfitGTS4MiniCoordinator extends Huami2021Coordinator {
|
public class AmazfitGTS4MiniCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS4MiniCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitGTS4MiniCoordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitGTS4MiniCoordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITGTS4MINI;
|
return DeviceType.AMAZFITGTS4MINI;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitGTS4MiniSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitGTS4MiniFWInstallHandler(uri, context);
|
return new AmazfitGTS4MiniFWInstallHandler(uri, context);
|
||||||
|
@ -36,6 +36,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitneo.AmazfitNeoSupport;
|
||||||
|
|
||||||
public class AmazfitNeoCoordinator extends HuamiCoordinator {
|
public class AmazfitNeoCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitNeoCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitNeoCoordinator.class);
|
||||||
@ -134,4 +136,10 @@ public class AmazfitNeoCoordinator extends HuamiCoordinator {
|
|||||||
HeartRateCapability.MeasurementInterval.MINUTES_30
|
HeartRateCapability.MeasurementInterval.MINUTES_30
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitNeoSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrex.AmazfitTRexSupport;
|
||||||
|
|
||||||
public class AmazfitTRexCoordinator extends HuamiCoordinator {
|
public class AmazfitTRexCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRexCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRexCoordinator.class);
|
||||||
@ -108,4 +110,10 @@ public class AmazfitTRexCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitTRexSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrex2.AmazfitTRex2Support;
|
||||||
|
|
||||||
public class AmazfitTRex2Coordinator extends Huami2021Coordinator {
|
public class AmazfitTRex2Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRex2Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRex2Coordinator.class);
|
||||||
@ -56,6 +58,12 @@ public class AmazfitTRex2Coordinator extends Huami2021Coordinator {
|
|||||||
return DeviceType.AMAZFITTREX2;
|
return DeviceType.AMAZFITTREX2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitTRex2Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
public AbstractHuami2021FWInstallHandler createFwInstallHandler(final Uri uri, final Context context) {
|
||||||
return new AmazfitTRex2FWInstallHandler(uri, context);
|
return new AmazfitTRex2FWInstallHandler(uri, context);
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrexpro.AmazfitTRexProSupport;
|
||||||
|
|
||||||
public class AmazfitTRexProCoordinator extends HuamiCoordinator {
|
public class AmazfitTRexProCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRexProCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRexProCoordinator.class);
|
||||||
@ -108,4 +110,10 @@ public class AmazfitTRexProCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitTRexProSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrexultra.AmazfitTRexUltraSupport;
|
||||||
|
|
||||||
public class AmazfitTRexUltraCoordinator extends Huami2021Coordinator {
|
public class AmazfitTRexUltraCoordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRexUltraCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitTRexUltraCoordinator.class);
|
||||||
@ -40,6 +42,12 @@ public class AmazfitTRexUltraCoordinator extends Huami2021Coordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitTRexUltraSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(final GBDeviceCandidate candidate) {
|
||||||
|
@ -31,6 +31,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitvergel.AmazfitVergeLSupport;
|
||||||
|
|
||||||
public class AmazfitVergeLCoordinator extends HuamiCoordinator {
|
public class AmazfitVergeLCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitVergeLCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitVergeLCoordinator.class);
|
||||||
@ -108,4 +110,10 @@ public class AmazfitVergeLCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitVergeLSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -34,6 +34,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.amazfitx.AmazfitXFWIns
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitx.AmazfitXSupport;
|
||||||
|
|
||||||
public class AmazfitXCoordinator extends HuamiCoordinator {
|
public class AmazfitXCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(AmazfitXCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(AmazfitXCoordinator.class);
|
||||||
@ -125,6 +127,12 @@ public class AmazfitXCoordinator extends HuamiCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return AmazfitXSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_REQUIRE_KEY;
|
return BONDING_STYLE_REQUIRE_KEY;
|
||||||
|
@ -26,6 +26,8 @@ import androidx.annotation.NonNull;
|
|||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.R;
|
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
||||||
@ -33,6 +35,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband2.MiBand2Support;
|
||||||
|
|
||||||
public class MiBand2Coordinator extends HuamiCoordinator {
|
public class MiBand2Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiBand2Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiBand2Coordinator.class);
|
||||||
@ -104,4 +109,15 @@ public class MiBand2Coordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand2Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,6 +26,8 @@ import org.slf4j.LoggerFactory;
|
|||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
|
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.R;
|
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
||||||
@ -33,6 +35,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband2.MiBand2Support;
|
||||||
|
|
||||||
public class MiBand2HRXCoordinator extends HuamiCoordinator {
|
public class MiBand2HRXCoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiBand2HRXCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiBand2HRXCoordinator.class);
|
||||||
@ -106,4 +111,15 @@ public class MiBand2HRXCoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand2Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -37,6 +37,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.miband.MiBandConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband3.MiBand3Support;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
public class MiBand3Coordinator extends HuamiCoordinator {
|
public class MiBand3Coordinator extends HuamiCoordinator {
|
||||||
@ -149,4 +151,10 @@ public class MiBand3Coordinator extends HuamiCoordinator {
|
|||||||
"zh_TW",
|
"zh_TW",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand3Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -38,6 +38,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband4.MiBand4Support;
|
||||||
|
|
||||||
public class MiBand4Coordinator extends HuamiCoordinator {
|
public class MiBand4Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiBand4Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiBand4Coordinator.class);
|
||||||
@ -164,4 +166,10 @@ public class MiBand4Coordinator extends HuamiCoordinator {
|
|||||||
HeartRateCapability.MeasurementInterval.MINUTES_30
|
HeartRateCapability.MeasurementInterval.MINUTES_30
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand4Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -37,6 +37,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband5.MiBand5Support;
|
||||||
|
|
||||||
public class MiBand5Coordinator extends HuamiCoordinator {
|
public class MiBand5Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiBand5Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiBand5Coordinator.class);
|
||||||
@ -182,4 +184,10 @@ public class MiBand5Coordinator extends HuamiCoordinator {
|
|||||||
HeartRateCapability.MeasurementInterval.MINUTES_30
|
HeartRateCapability.MeasurementInterval.MINUTES_30
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand5Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -21,6 +21,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband6.MiBand6Support;
|
||||||
|
|
||||||
public class MiBand6Coordinator extends HuamiCoordinator {
|
public class MiBand6Coordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiBand6Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiBand6Coordinator.class);
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -173,4 +176,10 @@ public class MiBand6Coordinator extends HuamiCoordinator {
|
|||||||
HeartRateCapability.MeasurementInterval.MINUTES_30
|
HeartRateCapability.MeasurementInterval.MINUTES_30
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand6Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,9 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiConst;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.AbstractHuami2021FWInstallHandler;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband7.MiBand7Support;
|
||||||
|
|
||||||
public class MiBand7Coordinator extends Huami2021Coordinator {
|
public class MiBand7Coordinator extends Huami2021Coordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiBand7Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiBand7Coordinator.class);
|
||||||
@ -71,6 +73,12 @@ public class MiBand7Coordinator extends Huami2021Coordinator {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBand7Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean supportsBluetoothPhoneCalls(final GBDevice device) {
|
public boolean supportsBluetoothPhoneCalls(final GBDevice device) {
|
||||||
return false;
|
return false;
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.devices.huami.HuamiCoordinator;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.zeppe.ZeppESupport;
|
||||||
|
|
||||||
public class ZeppECoordinator extends HuamiCoordinator {
|
public class ZeppECoordinator extends HuamiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(ZeppECoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(ZeppECoordinator.class);
|
||||||
@ -107,4 +109,10 @@ public class ZeppECoordinator extends HuamiCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return ZeppESupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -41,6 +41,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.id115.ID115Support;
|
||||||
|
|
||||||
public class ID115Coordinator extends AbstractBLEDeviceCoordinator {
|
public class ID115Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -163,4 +165,10 @@ public class ID115Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return ID115Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -38,6 +38,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.itag.ITagSupport;
|
||||||
|
|
||||||
public class ITagCoordinator extends AbstractBLEDeviceCoordinator {
|
public class ITagCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -155,6 +157,12 @@ public class ITagCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return ITagSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
||||||
// nothing to delete, yet
|
// nothing to delete, yet
|
||||||
|
@ -40,6 +40,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.jyou.BFH16DeviceSupport;
|
||||||
|
|
||||||
public class BFH16DeviceCoordinator extends AbstractBLEDeviceCoordinator
|
public class BFH16DeviceCoordinator extends AbstractBLEDeviceCoordinator
|
||||||
{
|
{
|
||||||
@ -188,6 +190,12 @@ public class BFH16DeviceCoordinator extends AbstractBLEDeviceCoordinator
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return BFH16DeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean supportsScreenshots() {
|
public boolean supportsScreenshots() {
|
||||||
return false;
|
return false;
|
||||||
|
@ -45,6 +45,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.jyou.TeclastH30.TeclastH30Support;
|
||||||
|
|
||||||
public class TeclastH30Coordinator extends AbstractBLEDeviceCoordinator {
|
public class TeclastH30Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
|
|
||||||
@ -106,6 +108,12 @@ public class TeclastH30Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return TeclastH30Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getDeviceType() {
|
public DeviceType getDeviceType() {
|
||||||
return DeviceType.TECLASTH30;
|
return DeviceType.TECLASTH30;
|
||||||
|
@ -36,6 +36,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.jyou.y5.Y5Support;
|
||||||
|
|
||||||
public class Y5Coordinator extends AbstractBLEDeviceCoordinator {
|
public class Y5Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -146,4 +148,10 @@ public class Y5Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
public boolean supportsFindDevice() {
|
public boolean supportsFindDevice() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return Y5Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -35,6 +35,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.lefun.LefunDeviceSupport;
|
||||||
|
|
||||||
import static nodomain.freeyourgadget.gadgetbridge.devices.lefun.LefunConstants.ADVERTISEMENT_NAME;
|
import static nodomain.freeyourgadget.gadgetbridge.devices.lefun.LefunConstants.ADVERTISEMENT_NAME;
|
||||||
import static nodomain.freeyourgadget.gadgetbridge.devices.lefun.LefunConstants.MANUFACTURER_NAME;
|
import static nodomain.freeyourgadget.gadgetbridge.devices.lefun.LefunConstants.MANUFACTURER_NAME;
|
||||||
@ -170,4 +172,10 @@ public class LefunDeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return LefunDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -38,6 +38,7 @@ import java.text.SimpleDateFormat;
|
|||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.GBApplication;
|
import nodomain.freeyourgadget.gadgetbridge.GBApplication;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.R;
|
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||||
@ -53,6 +54,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.lenovo.watchxplus.WatchXPlusDeviceSupport;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.lenovo.watchxplus.WatchXPlusDeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
@ -200,6 +203,17 @@ public class WatchXPlusDeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return WatchXPlusDeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
|
|
||||||
// find phone settings
|
// find phone settings
|
||||||
/**
|
/**
|
||||||
* @return {@link #FindPhone_OFF}, {@link #FindPhone_ON}, or the duration
|
* @return {@link #FindPhone_OFF}, {@link #FindPhone_ON}, or the duration
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.liveview.LiveviewSupport;
|
||||||
|
|
||||||
public class LiveviewCoordinator extends AbstractBLClassicDeviceCoordinator {
|
public class LiveviewCoordinator extends AbstractBLClassicDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -129,6 +131,12 @@ public class LiveviewCoordinator extends AbstractBLClassicDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return LiveviewSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
||||||
// nothing to delete, yet
|
// nothing to delete, yet
|
||||||
|
@ -49,6 +49,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.makibeshr3.MakibesHR3DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.GBPrefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.GBPrefs;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
@ -276,4 +278,10 @@ public class MakibesHR3Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MakibesHR3DeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,6 +33,7 @@ import org.slf4j.LoggerFactory;
|
|||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import de.greenrobot.dao.query.QueryBuilder;
|
import de.greenrobot.dao.query.QueryBuilder;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.GBApplication;
|
import nodomain.freeyourgadget.gadgetbridge.GBApplication;
|
||||||
@ -50,6 +51,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivityUser;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivityUser;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.miband.MiBandSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
import static nodomain.freeyourgadget.gadgetbridge.model.ActivityUser.PREF_USER_NAME;
|
import static nodomain.freeyourgadget.gadgetbridge.model.ActivityUser.PREF_USER_NAME;
|
||||||
@ -271,6 +275,12 @@ public class MiBandCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiBandSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
private boolean isMi1S(String hardwareVersion) {
|
private boolean isMi1S(String hardwareVersion) {
|
||||||
return MiBandConst.MI_1S.equals(hardwareVersion);
|
return MiBandConst.MI_1S.equals(hardwareVersion);
|
||||||
}
|
}
|
||||||
@ -278,4 +288,9 @@ public class MiBandCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
private boolean isMiPro(String hardwareVersion) {
|
private boolean isMiPro(String hardwareVersion) {
|
||||||
return MiBandConst.MI_PRO.equals(hardwareVersion);
|
return MiBandConst.MI_PRO.equals(hardwareVersion);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.mijia_lywsd02.MijiaLywsd02Support;
|
||||||
|
|
||||||
public class MijiaLywsd02Coordinator extends AbstractBLEDeviceCoordinator {
|
public class MijiaLywsd02Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -134,6 +136,12 @@ public class MijiaLywsd02Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MijiaLywsd02Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
||||||
// nothing to delete, yet
|
// nothing to delete, yet
|
||||||
|
@ -44,7 +44,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.btle.GattService;
|
import nodomain.freeyourgadget.gadgetbridge.service.btle.GattService;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.miscale2.MiScale2DeviceSupport;
|
||||||
|
|
||||||
public class MiScale2DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
public class MiScale2DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(MiScale2DeviceCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(MiScale2DeviceCoordinator.class);
|
||||||
@ -173,4 +175,10 @@ public class MiScale2DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
public boolean supportsFindDevice() {
|
public boolean supportsFindDevice() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return MiScale2DeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -42,6 +42,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.no1f1.No1F1Support;
|
||||||
|
|
||||||
public class No1F1Coordinator extends AbstractBLEDeviceCoordinator {
|
public class No1F1Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
|
|
||||||
@ -155,6 +157,12 @@ public class No1F1Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return No1F1Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) throws GBException {
|
||||||
Long deviceId = device.getId();
|
Long deviceId = device.getId();
|
||||||
|
@ -19,6 +19,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.BatteryConfig;
|
import nodomain.freeyourgadget.gadgetbridge.model.BatteryConfig;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.nothing.Ear1Support;
|
||||||
|
|
||||||
public class Ear1Coordinator extends AbstractBLClassicDeviceCoordinator {
|
public class Ear1Coordinator extends AbstractBLClassicDeviceCoordinator {
|
||||||
|
|
||||||
@ -134,6 +136,12 @@ public class Ear1Coordinator extends AbstractBLClassicDeviceCoordinator {
|
|||||||
return new BatteryConfig[]{battery1, battery2, battery3};
|
return new BatteryConfig[]{battery1, battery2, battery3};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return Ear1Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int[] getSupportedDeviceSpecificSettings(GBDevice device) {
|
public int[] getSupportedDeviceSpecificSettings(GBDevice device) {
|
||||||
return new int[] {
|
return new int[] {
|
||||||
|
@ -39,6 +39,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.nut.NutSupport;
|
||||||
|
|
||||||
public class NutCoordinator extends AbstractBLEDeviceCoordinator {
|
public class NutCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -77,6 +79,12 @@ public class NutCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return NutSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Class<? extends Activity> getPairingActivity() {
|
public Class<? extends Activity> getPairingActivity() {
|
||||||
return null;
|
return null;
|
||||||
|
@ -45,6 +45,8 @@ import nodomain.freeyourgadget.gadgetbridge.entities.PebbleMorpheuzSampleDao;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.pebble.PebbleSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.PebbleUtils;
|
import nodomain.freeyourgadget.gadgetbridge.util.PebbleUtils;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
import nodomain.freeyourgadget.gadgetbridge.util.Prefs;
|
||||||
|
|
||||||
@ -237,4 +239,10 @@ public class PebbleCoordinator extends AbstractBLClassicDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return PebbleSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,6 +33,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.pinetime.PineTimeJFSupport;
|
||||||
|
|
||||||
public class PineTimeJFCoordinator extends AbstractBLEDeviceCoordinator {
|
public class PineTimeJFCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -153,6 +155,12 @@ public class PineTimeJFCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return PineTimeJFSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
||||||
// nothing to delete, yet
|
// nothing to delete, yet
|
||||||
|
@ -34,6 +34,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.qc35.QC35BaseSupport;
|
||||||
|
|
||||||
public class QC35Coordinator extends AbstractBLClassicDeviceCoordinator {
|
public class QC35Coordinator extends AbstractBLClassicDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -68,6 +70,12 @@ public class QC35Coordinator extends AbstractBLClassicDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return QC35BaseSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean supportsActivityDataFetching() {
|
public boolean supportsActivityDataFetching() {
|
||||||
return false;
|
return false;
|
||||||
|
@ -53,6 +53,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.QHybridSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.FileUtils;
|
import nodomain.freeyourgadget.gadgetbridge.util.FileUtils;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.Version;
|
import nodomain.freeyourgadget.gadgetbridge.util.Version;
|
||||||
|
|
||||||
@ -267,6 +269,12 @@ public class QHybridCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return supportedSettings;
|
return supportedSettings;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return QHybridSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int[] getSupportedDeviceSpecificAuthenticationSettings() {
|
public int[] getSupportedDeviceSpecificAuthenticationSettings() {
|
||||||
return new int[]{
|
return new int[]{
|
||||||
|
@ -25,6 +25,8 @@ import org.slf4j.LoggerFactory;
|
|||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.roidmi.RoidmiSupport;
|
||||||
|
|
||||||
public class Roidmi1Coordinator extends RoidmiCoordinator {
|
public class Roidmi1Coordinator extends RoidmiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(Roidmi1Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(Roidmi1Coordinator.class);
|
||||||
@ -56,4 +58,10 @@ public class Roidmi1Coordinator extends RoidmiCoordinator {
|
|||||||
// Roidmi 1 does not have voltage support
|
// Roidmi 1 does not have voltage support
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return RoidmiSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,6 +25,8 @@ import org.slf4j.LoggerFactory;
|
|||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.roidmi.RoidmiSupport;
|
||||||
|
|
||||||
public class Roidmi3Coordinator extends RoidmiCoordinator {
|
public class Roidmi3Coordinator extends RoidmiCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(Roidmi3Coordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(Roidmi3Coordinator.class);
|
||||||
@ -59,4 +61,10 @@ public class Roidmi3Coordinator extends RoidmiCoordinator {
|
|||||||
public boolean supportsRgbLedColor() {
|
public boolean supportsRgbLedColor() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return RoidmiSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -28,6 +28,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.smaq2oss.SMAQ2OSSSupport;
|
||||||
|
|
||||||
public class SMAQ2OSSCoordinator extends AbstractBLEDeviceCoordinator {
|
public class SMAQ2OSSCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(SMAQ2OSSCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(SMAQ2OSSCoordinator.class);
|
||||||
@ -156,4 +158,10 @@ public class SMAQ2OSSCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
public boolean supportsMusicInfo() {
|
public boolean supportsMusicInfo() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return SMAQ2OSSSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,6 +32,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.soflow.SoFlowSupport;
|
||||||
|
|
||||||
public class SoFlowCoordinator extends AbstractBLEDeviceCoordinator {
|
public class SoFlowCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -150,4 +152,10 @@ public class SoFlowCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_lock_unlock
|
R.xml.devicesettings_lock_unlock
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return SoFlowSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
@ -43,6 +43,8 @@ import nodomain.freeyourgadget.gadgetbridge.entities.DaoSession;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.entities.Device;
|
import nodomain.freeyourgadget.gadgetbridge.entities.Device;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.sony.headphones.SonyHeadphonesSupport;
|
||||||
|
|
||||||
public abstract class SonyHeadphonesCoordinator extends AbstractBLClassicDeviceCoordinator {
|
public abstract class SonyHeadphonesCoordinator extends AbstractBLClassicDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -257,4 +259,10 @@ public abstract class SonyHeadphonesCoordinator extends AbstractBLClassicDeviceC
|
|||||||
public boolean preferServiceV2() {
|
public boolean preferServiceV2() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return SonyHeadphonesSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,6 +25,7 @@ import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.SonyHeadphon
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.SonyHeadphonesCoordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.SonyHeadphonesCoordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.sony.headphones.SonyHeadphonesSupport;
|
||||||
|
|
||||||
public class SonyWH1000XM4Coordinator extends SonyHeadphonesCoordinator {
|
public class SonyWH1000XM4Coordinator extends SonyHeadphonesCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
|
@ -35,6 +35,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.sonyswr12.SonySWR12DeviceSupport;
|
||||||
|
|
||||||
public class SonySWR12DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
public class SonySWR12DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
|
|
||||||
@ -144,4 +146,10 @@ public class SonySWR12DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
public int[] getSupportedDeviceSpecificSettings(GBDevice device) {
|
public int[] getSupportedDeviceSpecificSettings(GBDevice device) {
|
||||||
return new int[]{R.xml.devicesettings_sonyswr12};
|
return new int[]{R.xml.devicesettings_sonyswr12};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return SonySWR12DeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -21,6 +21,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.supercars.SuperCarsSupport;
|
||||||
|
|
||||||
public class SuperCarsCoordinator extends AbstractDeviceCoordinator {
|
public class SuperCarsCoordinator extends AbstractDeviceCoordinator {
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(SuperCarsCoordinator.class);
|
private static final Logger LOG = LoggerFactory.getLogger(SuperCarsCoordinator.class);
|
||||||
@ -63,6 +65,12 @@ public class SuperCarsCoordinator extends AbstractDeviceCoordinator {
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return SuperCarsSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Class<? extends Activity> getAppsManagementActivity() {
|
public Class<? extends Activity> getAppsManagementActivity() {
|
||||||
return ControlActivity.class;
|
return ControlActivity.class;
|
||||||
|
@ -36,6 +36,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.tlw64.TLW64Support;
|
||||||
|
|
||||||
public class TLW64Coordinator extends AbstractBLEDeviceCoordinator {
|
public class TLW64Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
|
|
||||||
@ -149,4 +151,10 @@ public class TLW64Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return TLW64Support.class;
|
||||||
|
}
|
||||||
}
|
}
|
@ -24,6 +24,7 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.um25.Support.UM25Support;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.um25.Support.UM25Support;
|
||||||
|
|
||||||
public class UM25Coordinator extends AbstractBLEDeviceCoordinator {
|
public class UM25Coordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@ -150,6 +151,12 @@ public class UM25Coordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return UM25Support.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int getBondingStyle() {
|
public int getBondingStyle() {
|
||||||
return BONDING_STYLE_NONE;
|
return BONDING_STYLE_NONE;
|
||||||
|
@ -21,6 +21,8 @@ import android.content.Context;
|
|||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
import android.os.ParcelUuid;
|
import android.os.ParcelUuid;
|
||||||
|
|
||||||
|
import androidx.annotation.NonNull;
|
||||||
|
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
@ -35,6 +37,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.vesc.VescDeviceSupport;
|
||||||
|
|
||||||
public class VescCoordinator extends AbstractBLEDeviceCoordinator {
|
public class VescCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
public final static String UUID_SERVICE_SERIAL_HM10 = "0000ffe0-0000-1000-8000-00805f9b34fb";
|
public final static String UUID_SERVICE_SERIAL_HM10 = "0000ffe0-0000-1000-8000-00805f9b34fb";
|
||||||
@ -58,6 +62,12 @@ public class VescCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return VescDeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public DeviceType getSupportedType(GBDeviceCandidate candidate) {
|
public DeviceType getSupportedType(GBDeviceCandidate candidate) {
|
||||||
ParcelUuid[] uuids = candidate.getServiceUuids();
|
ParcelUuid[] uuids = candidate.getServiceUuids();
|
||||||
|
@ -23,6 +23,8 @@ import android.net.Uri;
|
|||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
|
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.AbstractBLEDeviceCoordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.AbstractBLEDeviceCoordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
import nodomain.freeyourgadget.gadgetbridge.devices.InstallHandler;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
|
import nodomain.freeyourgadget.gadgetbridge.devices.SampleProvider;
|
||||||
@ -32,6 +34,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.vibratissimo.VibratissimoSupport;
|
||||||
|
|
||||||
public class VibratissimoCoordinator extends AbstractBLEDeviceCoordinator {
|
public class VibratissimoCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -129,6 +134,17 @@ public class VibratissimoCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return VibratissimoSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
protected void deleteDevice(@NonNull GBDevice gbDevice, @NonNull Device device, @NonNull DaoSession session) {
|
||||||
// nothing to delete, yet
|
// nothing to delete, yet
|
||||||
|
@ -34,6 +34,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.vivomovehr.VivomoveHrSupport;
|
||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
@ -143,6 +145,12 @@ public class VivomoveHrCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return VivomoveHrSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean supportsFindDevice() {
|
public boolean supportsFindDevice() {
|
||||||
return true;
|
return true;
|
||||||
|
@ -41,6 +41,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.waspos.WaspOSDeviceSupport;
|
||||||
|
|
||||||
public class WaspOSCoordinator extends AbstractBLEDeviceCoordinator {
|
public class WaspOSCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
|
|
||||||
@ -170,4 +172,10 @@ public class WaspOSCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return WaspOSDeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -27,6 +27,7 @@ import android.os.ParcelUuid;
|
|||||||
|
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
import androidx.annotation.NonNull;
|
import androidx.annotation.NonNull;
|
||||||
import androidx.annotation.Nullable;
|
import androidx.annotation.Nullable;
|
||||||
@ -40,6 +41,9 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.ServiceDeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.watch9.Watch9DeviceSupport;
|
||||||
|
|
||||||
public class Watch9DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
public class Watch9DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@Override
|
@Override
|
||||||
@ -163,6 +167,17 @@ public class Watch9DeviceCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return Watch9DeviceSupport.class;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public EnumSet<ServiceDeviceSupport.Flags> getInitialFlags() {
|
||||||
|
return EnumSet.of(ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
||||||
|
}
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
@Override
|
@Override
|
||||||
public Class<? extends Activity> getCalibrationActivity() {
|
public Class<? extends Activity> getCalibrationActivity() {
|
||||||
|
@ -38,6 +38,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.withingssteelhr.WithingsSteelHRDeviceSupport;
|
||||||
|
|
||||||
public class WithingsSteelHRDeviceCoordinator extends AbstractDeviceCoordinator {
|
public class WithingsSteelHRDeviceCoordinator extends AbstractDeviceCoordinator {
|
||||||
|
|
||||||
@ -184,4 +186,10 @@ public class WithingsSteelHRDeviceCoordinator extends AbstractDeviceCoordinator
|
|||||||
"it_IT",
|
"it_IT",
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return WithingsSteelHRDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -33,6 +33,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.xwatch.XWatchSupport;
|
||||||
|
|
||||||
public class XWatchCoordinator extends AbstractBLEDeviceCoordinator {
|
public class XWatchCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@NonNull
|
@NonNull
|
||||||
@ -135,4 +137,10 @@ public class XWatchCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
public boolean supportsFindDevice() {
|
public boolean supportsFindDevice() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return XWatchSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -37,6 +37,8 @@ import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDeviceCandidate;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
import nodomain.freeyourgadget.gadgetbridge.model.ActivitySample;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.DeviceSupport;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.zetime.ZeTimeDeviceSupport;
|
||||||
|
|
||||||
|
|
||||||
public class ZeTimeCoordinator extends AbstractBLEDeviceCoordinator {
|
public class ZeTimeCoordinator extends AbstractBLEDeviceCoordinator {
|
||||||
@ -170,4 +172,10 @@ public class ZeTimeCoordinator extends AbstractBLEDeviceCoordinator {
|
|||||||
R.xml.devicesettings_transliteration
|
R.xml.devicesettings_transliteration
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@NonNull
|
||||||
|
@Override
|
||||||
|
public Class<? extends DeviceSupport> getDeviceSupportClass() {
|
||||||
|
return ZeTimeDeviceSupport.class;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -24,109 +24,29 @@ package nodomain.freeyourgadget.gadgetbridge.service;
|
|||||||
|
|
||||||
import android.bluetooth.BluetoothAdapter;
|
import android.bluetooth.BluetoothAdapter;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
|
import android.util.Log;
|
||||||
import android.widget.Toast;
|
import android.widget.Toast;
|
||||||
|
|
||||||
|
import org.slf4j.Logger;
|
||||||
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.GBException;
|
import nodomain.freeyourgadget.gadgetbridge.GBException;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.R;
|
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.devices.DeviceCoordinator;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.externalevents.BluetoothConnectReceiver;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
import nodomain.freeyourgadget.gadgetbridge.impl.GBDevice;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
import nodomain.freeyourgadget.gadgetbridge.model.DeviceType;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.asteroidos.AsteroidOSDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.banglejs.BangleJSDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.binary_sensor.BinarySensorSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.casio.gb6900.CasioGB6900DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.casio.gbx100.CasioGBX100DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.casio.gwb5600.CasioGWB5600DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.domyos.DomyosT540Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.fitpro.FitProDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.flipper.zero.support.FlipperZeroSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.galaxy_buds.GalaxyBudsDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.hplus.HPlusSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitband5.AmazfitBand5Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitband7.AmazfitBand7Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip.AmazfitBipLiteSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip.AmazfitBipSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip3pro.AmazfitBip3ProSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbip5.AmazfitBip5Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbips.AmazfitBipSLiteSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbips.AmazfitBipSSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbipu.AmazfitBipUSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitbipupro.AmazfitBipUProSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcheetahpro.AmazfitCheetahProSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcheetahround.AmazfitCheetahRoundSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcheetahsquare.AmazfitCheetahSquareSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcor.AmazfitCorSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitcor2.AmazfitCor2Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitfalcon.AmazfitFalconSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr.AmazfitGTRLiteSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr.AmazfitGTRSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr2.AmazfitGTR2Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr2.AmazfitGTR2eSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr3.AmazfitGTR3Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr3pro.AmazfitGTR3ProSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtr4.AmazfitGTR4Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgtrmini.AmazfitGTRMiniSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts.AmazfitGTSSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts2.AmazfitGTS2MiniSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts2.AmazfitGTS2Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts2.AmazfitGTS2eSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts3.AmazfitGTS3Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts4.AmazfitGTS4Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitgts4mini.AmazfitGTS4MiniSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitneo.AmazfitNeoSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitpop.AmazfitPopSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitpoppro.AmazfitPopProSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrex.AmazfitTRexSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrex2.AmazfitTRex2Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrexpro.AmazfitTRexProSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfittrexultra.AmazfitTRexUltraSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitvergel.AmazfitVergeLSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.amazfitx.AmazfitXSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband2.MiBand2Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband3.MiBand3Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband4.MiBand4Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband5.MiBand5Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband6.MiBand6Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.miband7.MiBand7Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.huami.zeppe.ZeppESupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.id115.ID115Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.itag.ITagSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.jyou.BFH16DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.jyou.TeclastH30.TeclastH30Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.jyou.y5.Y5Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.lefun.LefunDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.lenovo.watchxplus.WatchXPlusDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.liveview.LiveviewSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.makibeshr3.MakibesHR3DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.miband.MiBandSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.mijia_lywsd02.MijiaLywsd02Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.miscale2.MiScale2DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.no1f1.No1F1Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.nothing.Ear1Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.nut.NutSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.pebble.PebbleSupport;
|
import nodomain.freeyourgadget.gadgetbridge.service.devices.pebble.PebbleSupport;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.pinetime.PineTimeJFSupport;
|
import nodomain.freeyourgadget.gadgetbridge.util.DeviceHelper;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.qc35.QC35BaseSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.qhybrid.QHybridSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.roidmi.RoidmiSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.smaq2oss.SMAQ2OSSSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.soflow.SoFlowSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.sony.headphones.SonyHeadphonesSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.sonyswr12.SonySWR12DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.supercars.SuperCarsSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.tlw64.TLW64Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.um25.Support.UM25Support;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.vesc.VescDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.vibratissimo.VibratissimoSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.vivomovehr.VivomoveHrSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.waspos.WaspOSDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.watch9.Watch9DeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.withingssteelhr.WithingsSteelHRDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.xwatch.XWatchSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.service.devices.zetime.ZeTimeDeviceSupport;
|
|
||||||
import nodomain.freeyourgadget.gadgetbridge.util.GB;
|
import nodomain.freeyourgadget.gadgetbridge.util.GB;
|
||||||
|
|
||||||
import java.lang.reflect.Constructor;
|
import java.lang.reflect.Constructor;
|
||||||
|
import java.lang.reflect.InvocationTargetException;
|
||||||
|
import java.util.EnumSet;
|
||||||
|
|
||||||
public class DeviceSupportFactory {
|
public class DeviceSupportFactory {
|
||||||
|
private static final Logger LOG = LoggerFactory.getLogger(DeviceSupportFactory.class);
|
||||||
|
|
||||||
private final BluetoothAdapter mBtAdapter;
|
private final BluetoothAdapter mBtAdapter;
|
||||||
private final Context mContext;
|
private final Context mContext;
|
||||||
|
|
||||||
@ -184,228 +104,28 @@ public class DeviceSupportFactory {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private ServiceDeviceSupport createServiceDeviceSupport(GBDevice device){
|
private ServiceDeviceSupport createServiceDeviceSupport(GBDevice device) throws GBException {
|
||||||
switch (device.getType()) {
|
DeviceCoordinator coordinator = DeviceHelper.getInstance().getCoordinator(device);
|
||||||
case PEBBLE:
|
Class supportClass = coordinator.getDeviceSupportClass();
|
||||||
return new ServiceDeviceSupport(new PebbleSupport());
|
|
||||||
case MIBAND:
|
try {
|
||||||
return new ServiceDeviceSupport(new MiBandSupport(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
Constructor supportConstructor = supportClass.getConstructor(DeviceType.class);
|
||||||
case MIBAND2:
|
DeviceSupport supportInstance = (DeviceSupport) supportConstructor.newInstance(device.getType());
|
||||||
return new ServiceDeviceSupport(new MiBand2Support(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
return new ServiceDeviceSupport(supportInstance, coordinator.getInitialFlags());
|
||||||
case MIBAND3:
|
} catch (NoSuchMethodException e) {
|
||||||
return new ServiceDeviceSupport(new MiBand3Support());
|
// ignore, let next call get the default, zero-argument constructor
|
||||||
case MIBAND4:
|
} catch (ReflectiveOperationException e) {
|
||||||
return new ServiceDeviceSupport(new MiBand4Support());
|
LOG.error("error calling DeviceSupport constructor with argument 'DeviceType'");
|
||||||
case MIBAND5:
|
throw new GBException(e);
|
||||||
return new ServiceDeviceSupport(new MiBand5Support());
|
}
|
||||||
case MIBAND6:
|
|
||||||
return new ServiceDeviceSupport(new MiBand6Support());
|
try {
|
||||||
case AMAZFITCHEETAHPRO:
|
DeviceSupport supportInstance = (DeviceSupport) supportClass.newInstance();
|
||||||
return new ServiceDeviceSupport(new AmazfitCheetahProSupport());
|
return new ServiceDeviceSupport(supportInstance, coordinator.getInitialFlags());
|
||||||
case AMAZFITCHEETAHSQUARE:
|
} catch (ReflectiveOperationException e) {
|
||||||
return new ServiceDeviceSupport(new AmazfitCheetahSquareSupport());
|
LOG.error("error calling DeviceSupport constructor with zero arguments");
|
||||||
case AMAZFITCHEETAHROUND:
|
throw new GBException(e);
|
||||||
return new ServiceDeviceSupport(new AmazfitCheetahRoundSupport());
|
|
||||||
case AMAZFITBIP5:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBip5Support());
|
|
||||||
case AMAZFITTREXULTRA:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitTRexUltraSupport());
|
|
||||||
case AMAZFITGTRMINI:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTRMiniSupport());
|
|
||||||
case AMAZFITFALCON:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitFalconSupport());
|
|
||||||
case AMAZFITGTS3:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTS3Support());
|
|
||||||
case AMAZFITGTR3:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTR3Support());
|
|
||||||
case AMAZFITGTR4:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTR4Support());
|
|
||||||
case MIBAND7:
|
|
||||||
return new ServiceDeviceSupport(new MiBand7Support());
|
|
||||||
case AMAZFITBAND7:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBand7Support());
|
|
||||||
case AMAZFITGTS4:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTS4Support());
|
|
||||||
case AMAZFITGTS4MINI:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTS4MiniSupport());
|
|
||||||
case AMAZFITTREX2:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitTRex2Support());
|
|
||||||
case AMAZFITGTR3PRO:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTR3ProSupport());
|
|
||||||
case AMAZFITBIP:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBipSupport());
|
|
||||||
case AMAZFITBIP_LITE:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBipLiteSupport());
|
|
||||||
case AMAZFITBIPS:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBipSSupport());
|
|
||||||
case AMAZFITBIPS_LITE:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBipSLiteSupport());
|
|
||||||
case AMAZFITBIPU:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBipUSupport());
|
|
||||||
case AMAZFITBIPUPRO:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBipUProSupport());
|
|
||||||
case AMAZFITBIP3PRO:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBip3ProSupport());
|
|
||||||
case AMAZFITPOP:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitPopSupport());
|
|
||||||
case AMAZFITPOPPRO:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitPopProSupport());
|
|
||||||
case AMAZFITGTR:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTRSupport());
|
|
||||||
case AMAZFITGTR_LITE:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTRLiteSupport());
|
|
||||||
case AMAZFITGTR2:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTR2Support());
|
|
||||||
case ZEPP_E:
|
|
||||||
return new ServiceDeviceSupport(new ZeppESupport());
|
|
||||||
case AMAZFITGTR2E:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTR2eSupport());
|
|
||||||
case AMAZFITTREX:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitTRexSupport());
|
|
||||||
case AMAZFITTREXPRO:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitTRexProSupport());
|
|
||||||
case AMAZFITGTS:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTSSupport());
|
|
||||||
case AMAZFITVERGEL:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitVergeLSupport());
|
|
||||||
case AMAZFITGTS2:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTS2Support());
|
|
||||||
case AMAZFITGTS2_MINI:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTS2MiniSupport());
|
|
||||||
case AMAZFITGTS2E:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitGTS2eSupport());
|
|
||||||
case AMAZFITCOR:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitCorSupport());
|
|
||||||
case AMAZFITCOR2:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitCor2Support());
|
|
||||||
case AMAZFITBAND5:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitBand5Support());
|
|
||||||
case AMAZFITX:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitXSupport());
|
|
||||||
case AMAZFITNEO:
|
|
||||||
return new ServiceDeviceSupport(new AmazfitNeoSupport());
|
|
||||||
case VIBRATISSIMO:
|
|
||||||
return new ServiceDeviceSupport(new VibratissimoSupport(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case LIVEVIEW:
|
|
||||||
return new ServiceDeviceSupport(new LiveviewSupport());
|
|
||||||
case HPLUS:
|
|
||||||
case MAKIBESF68:
|
|
||||||
case EXRIZUK8:
|
|
||||||
case Q8:
|
|
||||||
return new ServiceDeviceSupport(new HPlusSupport(device.getType()));
|
|
||||||
case NO1F1:
|
|
||||||
return new ServiceDeviceSupport(new No1F1Support());
|
|
||||||
case TECLASTH30:
|
|
||||||
return new ServiceDeviceSupport(new TeclastH30Support());
|
|
||||||
case XWATCH:
|
|
||||||
return new ServiceDeviceSupport(new XWatchSupport());
|
|
||||||
case FOSSILQHYBRID:
|
|
||||||
return new ServiceDeviceSupport(new QHybridSupport());
|
|
||||||
case ZETIME:
|
|
||||||
return new ServiceDeviceSupport(new ZeTimeDeviceSupport());
|
|
||||||
case ID115:
|
|
||||||
return new ServiceDeviceSupport(new ID115Support());
|
|
||||||
case WATCH9:
|
|
||||||
return new ServiceDeviceSupport(new Watch9DeviceSupport(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case WATCHXPLUS:
|
|
||||||
return new ServiceDeviceSupport(new WatchXPlusDeviceSupport(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case ROIDMI:
|
|
||||||
return new ServiceDeviceSupport(new RoidmiSupport());
|
|
||||||
case ROIDMI3:
|
|
||||||
return new ServiceDeviceSupport(new RoidmiSupport());
|
|
||||||
case Y5:
|
|
||||||
return new ServiceDeviceSupport(new Y5Support());
|
|
||||||
case CASIOGB6900:
|
|
||||||
return new ServiceDeviceSupport(new CasioGB6900DeviceSupport());
|
|
||||||
case CASIOGBX100:
|
|
||||||
return new ServiceDeviceSupport(new CasioGBX100DeviceSupport());
|
|
||||||
case CASIOGWB5600:
|
|
||||||
return new ServiceDeviceSupport(new CasioGWB5600DeviceSupport());
|
|
||||||
case CASIOGMWB5000:
|
|
||||||
return new ServiceDeviceSupport(new CasioGWB5600DeviceSupport());
|
|
||||||
case MISCALE2:
|
|
||||||
return new ServiceDeviceSupport(new MiScale2DeviceSupport());
|
|
||||||
case BFH16:
|
|
||||||
return new ServiceDeviceSupport(new BFH16DeviceSupport());
|
|
||||||
case MIJIA_LYWSD02:
|
|
||||||
return new ServiceDeviceSupport(new MijiaLywsd02Support());
|
|
||||||
case MAKIBESHR3:
|
|
||||||
return new ServiceDeviceSupport(new MakibesHR3DeviceSupport());
|
|
||||||
case ITAG:
|
|
||||||
return new ServiceDeviceSupport(new ITagSupport());
|
|
||||||
case NUTMINI:
|
|
||||||
return new ServiceDeviceSupport(new NutSupport());
|
|
||||||
case BANGLEJS:
|
|
||||||
return new ServiceDeviceSupport(new BangleJSDeviceSupport());
|
|
||||||
case TLW64:
|
|
||||||
return new ServiceDeviceSupport(new TLW64Support());
|
|
||||||
case PINETIME_JF:
|
|
||||||
return new ServiceDeviceSupport(new PineTimeJFSupport());
|
|
||||||
case SG2:
|
|
||||||
return new ServiceDeviceSupport(new HPlusSupport(DeviceType.SG2));
|
|
||||||
case LEFUN:
|
|
||||||
return new ServiceDeviceSupport(new LefunDeviceSupport());
|
|
||||||
case BOHEMIC_SMART_BRACELET:
|
|
||||||
return new ServiceDeviceSupport(new LefunDeviceSupport());
|
|
||||||
case SONY_SWR12:
|
|
||||||
return new ServiceDeviceSupport(new SonySWR12DeviceSupport());
|
|
||||||
case WASPOS:
|
|
||||||
return new ServiceDeviceSupport(new WaspOSDeviceSupport());
|
|
||||||
case SMAQ2OSS:
|
|
||||||
return new ServiceDeviceSupport(new SMAQ2OSSSupport());
|
|
||||||
case UM25:
|
|
||||||
return new ServiceDeviceSupport(new UM25Support());
|
|
||||||
case DOMYOS_T540:
|
|
||||||
return new ServiceDeviceSupport(new DomyosT540Support(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case FITPRO:
|
|
||||||
return new ServiceDeviceSupport(new FitProDeviceSupport(), ServiceDeviceSupport.Flags.THROTTLING, ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case NOTHING_EAR1:
|
|
||||||
return new ServiceDeviceSupport(new Ear1Support());
|
|
||||||
case GALAXY_BUDS:
|
|
||||||
return new ServiceDeviceSupport(new GalaxyBudsDeviceSupport());
|
|
||||||
case GALAXY_BUDS_LIVE:
|
|
||||||
return new ServiceDeviceSupport(new GalaxyBudsDeviceSupport());
|
|
||||||
case GALAXY_BUDS_PRO:
|
|
||||||
case GALAXY_BUDS2:
|
|
||||||
case GALAXY_BUDS2_PRO:
|
|
||||||
return new ServiceDeviceSupport(new GalaxyBudsDeviceSupport(), ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case SONY_WH_1000XM3:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case SONY_WH_1000XM4:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case SONY_WF_SP800N:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport(), ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
|
||||||
case SONY_WF_1000XM3:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case SONY_WH_1000XM2:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case SONY_WF_1000XM4:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case SONY_LINKBUDS_S:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case SONY_WH_1000XM5:
|
|
||||||
return new ServiceDeviceSupport(new SonyHeadphonesSupport());
|
|
||||||
case VESC_NRF:
|
|
||||||
case VESC_HM10:
|
|
||||||
return new ServiceDeviceSupport(new VescDeviceSupport(device.getType()));
|
|
||||||
case BOSE_QC35:
|
|
||||||
return new ServiceDeviceSupport(new QC35BaseSupport());
|
|
||||||
case BINARY_SENSOR:
|
|
||||||
return new ServiceDeviceSupport(new BinarySensorSupport());
|
|
||||||
case FLIPPER_ZERO:
|
|
||||||
return new ServiceDeviceSupport(new FlipperZeroSupport());
|
|
||||||
case SUPER_CARS:
|
|
||||||
return new ServiceDeviceSupport(new SuperCarsSupport());
|
|
||||||
case ASTEROIDOS:
|
|
||||||
return new ServiceDeviceSupport(new AsteroidOSDeviceSupport());
|
|
||||||
case SOFLOW_SO6:
|
|
||||||
return new ServiceDeviceSupport(new SoFlowSupport());
|
|
||||||
case WITHINGS_STEEL_HR:
|
|
||||||
return new ServiceDeviceSupport(new WithingsSteelHRDeviceSupport());
|
|
||||||
case VIVOMOVE_HR:
|
|
||||||
return new ServiceDeviceSupport(new VivomoveHrSupport());
|
|
||||||
}
|
}
|
||||||
return null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private DeviceSupport createBTDeviceSupport(GBDevice gbDevice) throws GBException {
|
private DeviceSupport createBTDeviceSupport(GBDevice gbDevice) throws GBException {
|
||||||
@ -425,7 +145,7 @@ public class DeviceSupportFactory {
|
|||||||
|
|
||||||
private DeviceSupport createTCPDeviceSupport(GBDevice gbDevice) throws GBException {
|
private DeviceSupport createTCPDeviceSupport(GBDevice gbDevice) throws GBException {
|
||||||
try {
|
try {
|
||||||
DeviceSupport deviceSupport = new ServiceDeviceSupport(new PebbleSupport(), ServiceDeviceSupport.Flags.BUSY_CHECKING);
|
DeviceSupport deviceSupport = new ServiceDeviceSupport(new PebbleSupport(), EnumSet.of(ServiceDeviceSupport.Flags.BUSY_CHECKING));
|
||||||
deviceSupport.setContext(gbDevice, mBtAdapter, mContext);
|
deviceSupport.setContext(gbDevice, mBtAdapter, mContext);
|
||||||
return deviceSupport;
|
return deviceSupport;
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
@ -50,8 +50,7 @@ import nodomain.freeyourgadget.gadgetbridge.model.WorldClock;
|
|||||||
* Wraps another device support instance and supports busy-checking and throttling of events.
|
* Wraps another device support instance and supports busy-checking and throttling of events.
|
||||||
*/
|
*/
|
||||||
public class ServiceDeviceSupport implements DeviceSupport {
|
public class ServiceDeviceSupport implements DeviceSupport {
|
||||||
|
public static enum Flags {
|
||||||
enum Flags {
|
|
||||||
THROTTLING,
|
THROTTLING,
|
||||||
BUSY_CHECKING,
|
BUSY_CHECKING,
|
||||||
}
|
}
|
||||||
@ -65,14 +64,9 @@ public class ServiceDeviceSupport implements DeviceSupport {
|
|||||||
private String lastNotificationKind;
|
private String lastNotificationKind;
|
||||||
private final EnumSet<Flags> flags;
|
private final EnumSet<Flags> flags;
|
||||||
|
|
||||||
public ServiceDeviceSupport(DeviceSupport delegate, Flags... flags) {
|
public ServiceDeviceSupport(DeviceSupport delegate, EnumSet<Flags> flags) {
|
||||||
this.delegate = delegate;
|
this.delegate = delegate;
|
||||||
this.flags = EnumSet.noneOf(Flags.class);
|
this.flags = flags;
|
||||||
this.flags.addAll(Arrays.asList(flags));
|
|
||||||
}
|
|
||||||
|
|
||||||
public ServiceDeviceSupport(DeviceSupport delegate){
|
|
||||||
this(delegate, Flags.BUSY_CHECKING);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -0,0 +1,19 @@
|
|||||||
|
package nodomain.freeyourgadget.gadgetbridge.service.devices.unknown;
|
||||||
|
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.service.AbstractDeviceSupport;
|
||||||
|
|
||||||
|
public class UnknownDeviceSupport extends AbstractDeviceSupport {
|
||||||
|
@Override
|
||||||
|
public boolean connect() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void dispose() {
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean useAutoConnect() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user