diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/devices/colmi/ColmiR10Coordinator.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/devices/colmi/ColmiR10Coordinator.java new file mode 100644 index 000000000..4f6972d20 --- /dev/null +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/devices/colmi/ColmiR10Coordinator.java @@ -0,0 +1,38 @@ +/* Copyright (C) 2024 Arjan Schrijver + + This file is part of Gadgetbridge. + + Gadgetbridge is free software: you can redistribute it and/or modify + it under the terms of the GNU Affero General Public License as published + by the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + Gadgetbridge is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU Affero General Public License for more details. + + You should have received a copy of the GNU Affero General Public License + along with this program. If not, see . */ +package nodomain.freeyourgadget.gadgetbridge.devices.colmi; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import java.util.regex.Pattern; + +import nodomain.freeyourgadget.gadgetbridge.R; + +public class ColmiR10Coordinator extends AbstractColmiR0xCoordinator { + private static final Logger LOG = LoggerFactory.getLogger(ColmiR10Coordinator.class); + + @Override + protected Pattern getSupportedDeviceName() { + return Pattern.compile("^COLMI R10_.*"); + } + + @Override + public int getDeviceNameResource() { + return R.string.devicetype_colmi_r10; + } +} diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/model/DeviceType.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/model/DeviceType.java index 2e1cc28b6..b6be12da2 100644 --- a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/model/DeviceType.java +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/model/DeviceType.java @@ -41,6 +41,7 @@ import nodomain.freeyourgadget.gadgetbridge.devices.cmfwatchpro.CmfWatchProCoord import nodomain.freeyourgadget.gadgetbridge.devices.colmi.ColmiR02Coordinator; import nodomain.freeyourgadget.gadgetbridge.devices.colmi.ColmiR03Coordinator; import nodomain.freeyourgadget.gadgetbridge.devices.colmi.ColmiR06Coordinator; +import nodomain.freeyourgadget.gadgetbridge.devices.colmi.ColmiR10Coordinator; import nodomain.freeyourgadget.gadgetbridge.devices.cycling_sensor.coordinator.CyclingSensorCoordinator; import nodomain.freeyourgadget.gadgetbridge.devices.divoom.PixooCoordinator; import nodomain.freeyourgadget.gadgetbridge.devices.domyos.DomyosT540Coordinator; @@ -533,6 +534,7 @@ public enum DeviceType { COLMI_R02(ColmiR02Coordinator.class), COLMI_R03(ColmiR03Coordinator.class), COLMI_R06(ColmiR06Coordinator.class), + COLMI_R10(ColmiR10Coordinator.class), SCANNABLE(ScannableDeviceCoordinator.class), CYCLING_SENSOR(CyclingSensorCoordinator.class), BLE_GATT_CLIENT(BleGattClientCoordinator.class), diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index c88d2f92d..7f59539e8 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -1869,6 +1869,7 @@ Colmi R02 Colmi R03 Colmi R06 + Colmi R10 Choose export location General High-priority