mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2025-02-10 08:56:49 +01:00
Sony WH-ULT900N: Initial support
This commit is contained in:
parent
51fca72a43
commit
f277fbe9e5
@ -0,0 +1,50 @@
|
|||||||
|
/* Copyright (C) 2025 José Rebelo
|
||||||
|
|
||||||
|
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 <https://www.gnu.org/licenses/>. */
|
||||||
|
package nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import java.util.HashSet;
|
||||||
|
import java.util.Set;
|
||||||
|
import java.util.regex.Pattern;
|
||||||
|
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.SonyHeadphonesCapabilities;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.SonyHeadphonesCoordinator;
|
||||||
|
|
||||||
|
public class SonyWHULT900NCoordinator extends SonyHeadphonesCoordinator {
|
||||||
|
@Override
|
||||||
|
protected Pattern getSupportedDeviceName() {
|
||||||
|
return Pattern.compile("^Sony ULT|ULT WEAR$");
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getDeviceNameResource() {
|
||||||
|
return R.string.devicetype_sony_wh_ult900n;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Set<SonyHeadphonesCapabilities> getCapabilities() {
|
||||||
|
return new HashSet<>(Arrays.asList(
|
||||||
|
SonyHeadphonesCapabilities.BatterySingle,
|
||||||
|
SonyHeadphonesCapabilities.AmbientSoundControl,
|
||||||
|
SonyHeadphonesCapabilities.PowerOffFromPhone,
|
||||||
|
SonyHeadphonesCapabilities.PauseWhenTakenOff,
|
||||||
|
SonyHeadphonesCapabilities.QuickAccess,
|
||||||
|
SonyHeadphonesCapabilities.VoiceNotifications
|
||||||
|
));
|
||||||
|
}
|
||||||
|
}
|
@ -264,6 +264,7 @@ import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators
|
|||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWH1000XM3Coordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWH1000XM3Coordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWH1000XM4Coordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWH1000XM4Coordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWH1000XM5Coordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWH1000XM5Coordinator;
|
||||||
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWHULT900NCoordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWIC100Coordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWIC100Coordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWISP600NCoordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.headphones.coordinators.SonyWISP600NCoordinator;
|
||||||
import nodomain.freeyourgadget.gadgetbridge.devices.sony.wena3.SonyWena3Coordinator;
|
import nodomain.freeyourgadget.gadgetbridge.devices.sony.wena3.SonyWena3Coordinator;
|
||||||
@ -538,6 +539,7 @@ public enum DeviceType {
|
|||||||
SONY_LINKBUDS(SonyLinkBudsCoordinator.class),
|
SONY_LINKBUDS(SonyLinkBudsCoordinator.class),
|
||||||
SONY_LINKBUDS_S(SonyLinkBudsSCoordinator.class),
|
SONY_LINKBUDS_S(SonyLinkBudsSCoordinator.class),
|
||||||
SONY_WH_1000XM5(SonyWH1000XM5Coordinator.class),
|
SONY_WH_1000XM5(SonyWH1000XM5Coordinator.class),
|
||||||
|
SONY_WH_ULT900N(SonyWHULT900NCoordinator.class),
|
||||||
SONY_WF_1000XM5(SonyWF1000XM5Coordinator.class),
|
SONY_WF_1000XM5(SonyWF1000XM5Coordinator.class),
|
||||||
SONY_WF_C500(SonyWFC500Coordinator.class),
|
SONY_WF_C500(SonyWFC500Coordinator.class),
|
||||||
SONY_WF_C510(SonyWFC510Coordinator.class),
|
SONY_WF_C510(SonyWFC510Coordinator.class),
|
||||||
|
@ -1855,6 +1855,7 @@
|
|||||||
<string name="devicetype_sony_wh_1000xm3">Sony WH-1000XM3</string>
|
<string name="devicetype_sony_wh_1000xm3">Sony WH-1000XM3</string>
|
||||||
<string name="devicetype_sony_wh_1000xm4">Sony WH-1000XM4</string>
|
<string name="devicetype_sony_wh_1000xm4">Sony WH-1000XM4</string>
|
||||||
<string name="devicetype_sony_wh_1000xm5">Sony WH-1000XM5</string>
|
<string name="devicetype_sony_wh_1000xm5">Sony WH-1000XM5</string>
|
||||||
|
<string name="devicetype_sony_wh_ult900n">Sony WH-ULT900N</string>
|
||||||
<string name="devicetype_sony_wf_sp800n">Sony WF-SP800N</string>
|
<string name="devicetype_sony_wf_sp800n">Sony WF-SP800N</string>
|
||||||
<string name="devicetype_sony_wf_1000xm3">Sony WF-1000XM3</string>
|
<string name="devicetype_sony_wf_1000xm3">Sony WF-1000XM3</string>
|
||||||
<string name="devicetype_sony_wf_1000xm4">Sony WF-1000XM4</string>
|
<string name="devicetype_sony_wf_1000xm4">Sony WF-1000XM4</string>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user