mirror of
https://github.com/danieldemus/openhab-addons
synced 2026-07-29 12:34:21 +02:00
[shelly] Use thing type shellyplusht for Shelly Plus HT Gen3 (#18943)
* Thing type shellyplushtg3 removed, instead it will be mapped to shellyplusht Signed-off-by: Markus Michels <markus7017@gmail.com>
This commit is contained in:
@@ -1415,7 +1415,7 @@ Using the Thing configuration option `brightnessAutoOn` you could decide if the
|
||||
|
||||
Channels lastEvent and eventCount are only available if input type is set to momentary button
|
||||
|
||||
### Shelly Plus HT (thing-type: shellyplusht), Plus HT Gen 3 (thing-type: shellyhtg3)
|
||||
### Shelly Plus HT (thing-type: shellyplusht)
|
||||
|
||||
| Group | Channel | Type | read-only | Description |
|
||||
| ------- | ------------ | -------- | --------- | ------------------------------------------------------- |
|
||||
|
||||
+4
-4
@@ -47,10 +47,10 @@ public class ShellyBindingConstants {
|
||||
THING_TYPE_SHELLYPLUS1, THING_TYPE_SHELLYPLUS1PM, THING_TYPE_SHELLYPLUS2PM_RELAY,
|
||||
THING_TYPE_SHELLYPLUS2PM_ROLLER, THING_TYPE_SHELLYPLUSI4, THING_TYPE_SHELLYPLUSI4DC,
|
||||
THING_TYPE_SHELLYPLUSDIMMER10V, THING_TYPE_SHELLYPLUSUNI, THING_TYPE_SHELLYPLUSHT,
|
||||
THING_TYPE_SHELLYPLUSHTG3, THING_TYPE_SHELLYPLUSSMOKE, THING_TYPE_SHELLYPLUSPLUGS,
|
||||
THING_TYPE_SHELLYPLUSPLUGUS, THING_TYPE_SHELLYPLUSDIMMERUS, THING_TYPE_SHELLYPLUSRGBWPM,
|
||||
THING_TYPE_SHELLYPLUSSTRIP, THING_TYPE_SHELLYPLUS1L, THING_TYPE_SHELLYPLUS2L, THING_TYPE_SHELLYPLUSSHUTTER,
|
||||
THING_TYPE_SHELLYPLUSEM, THING_TYPE_SHELLYPLUS3EM63,
|
||||
THING_TYPE_SHELLYPLUSSMOKE, THING_TYPE_SHELLYPLUSPLUGS, THING_TYPE_SHELLYPLUSPLUGUS,
|
||||
THING_TYPE_SHELLYPLUSDIMMERUS, THING_TYPE_SHELLYPLUSRGBWPM, THING_TYPE_SHELLYPLUSSTRIP,
|
||||
THING_TYPE_SHELLYPLUS1L, THING_TYPE_SHELLYPLUS2L, THING_TYPE_SHELLYPLUSSHUTTER, THING_TYPE_SHELLYPLUSEM,
|
||||
THING_TYPE_SHELLYPLUS3EM63,
|
||||
|
||||
// Shelly Wall Display
|
||||
THING_TYPE_SHELLYPLUSWALLDISPLAY,
|
||||
|
||||
+2
-3
@@ -217,7 +217,7 @@ public class ShellyDeviceProfile {
|
||||
boolean isGas = THING_TYPE_SHELLYGAS.equals(thingTypeUID);
|
||||
boolean isUNI = THING_TYPE_SHELLYUNI.equals(thingTypeUID) || THING_TYPE_SHELLYPLUSUNI.equals(thingTypeUID);
|
||||
isHT = THING_TYPE_SHELLYHT.equals(thingTypeUID) || THING_TYPE_SHELLYPLUSHT.equals(thingTypeUID)
|
||||
|| THING_TYPE_SHELLYPLUSHTG3.equals(thingTypeUID) || THING_TYPE_SHELLYBLUHT.equals(thingTypeUID);
|
||||
|| THING_TYPE_SHELLYBLUHT.equals(thingTypeUID);
|
||||
isDW = THING_TYPE_SHELLYDOORWIN.equals(thingTypeUID) || THING_TYPE_SHELLYDOORWIN2.equals(thingTypeUID)
|
||||
|| THING_TYPE_SHELLYBLUDW.equals(thingTypeUID);
|
||||
isMotion = THING_TYPE_SHELLYMOTION.equals(thingTypeUID) || THING_TYPE_SHELLYBLUMOTION.equals(thingTypeUID);
|
||||
@@ -413,8 +413,7 @@ public class ShellyDeviceProfile {
|
||||
return thingTypeID.startsWith(THING_TYPE_SHELLYPLUS_PREFIX)
|
||||
|| thingTypeID.startsWith(THING_TYPE_SHELLYPRO_PREFIX) || thingTypeID.contains("mini")
|
||||
|| THING_TYPE_SHELLYPLUSWALLDISPLAY.equals(thingTypeUID)
|
||||
|| THING_TYPE_SHELLYPLUSHTG3.equals(thingTypeUID) || isBluSeries(thingTypeUID)
|
||||
|| THING_TYPE_SHELLYBLUGW.equals(thingTypeUID);
|
||||
|| isBluSeries(thingTypeUID) | isBluSeries(thingTypeUID) || THING_TYPE_SHELLYBLUGW.equals(thingTypeUID);
|
||||
}
|
||||
|
||||
public static boolean isBluSeries(ThingTypeUID thingTypeUID) {
|
||||
|
||||
-1
@@ -220,7 +220,6 @@ public class ShellyThingCreator {
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSI4DC = new ThingTypeUID(BINDING_ID, "shellyplusi4dc");
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSHT = new ThingTypeUID(BINDING_ID, "shellyplusht");
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSUNI = new ThingTypeUID(BINDING_ID, "shellyplusuni");
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSHTG3 = new ThingTypeUID(BINDING_ID, "shellyhtg3");
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSSMOKE = new ThingTypeUID(BINDING_ID, "shellyplussmoke");
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSPLUGS = new ThingTypeUID(BINDING_ID, "shellyplusplug");
|
||||
public static final ThingTypeUID THING_TYPE_SHELLYPLUSPLUGUS = new ThingTypeUID(BINDING_ID, "shellyplusplugus");
|
||||
|
||||
@@ -104,7 +104,6 @@ thing-type.shelly.shellyplusi4.description = Shelly Plus i4 - 4xInput Device
|
||||
thing-type.shelly.shellyplusi4dc.description = Shelly Plus i4DC - 4xDC Input Device
|
||||
thing-type.shelly.shellyplusuni.description = Shelly Plus UNI - Universal Module
|
||||
thing-type.shelly.shellyplusht.description = Shelly Plus HT - Humidity and Temperature sensor with display
|
||||
thing-type.shelly.shellyplushtg3.description = Shelly Plus HT Gen 3 - Humidity and Temperature sensor with display
|
||||
thing-type.shelly.shellyplussmoke.description = Shelly Plus Smoke - Smoke Detector with Alarm
|
||||
thing-type.shelly.shellypluswdus.description = Shelly Wall Dimmer US Device
|
||||
thing-type.shelly.shellyplus10v.description = Shelly Plus Dimmer 10V
|
||||
|
||||
@@ -104,7 +104,6 @@ thing-type.shelly.shellyplusi4.description = Shelly Plus i4 mit 4 Analog-Eingän
|
||||
thing-type.shelly.shellyplusi4dc.description = Shelly Plus i4DC mit 4 Gleichstrom-Eingängen
|
||||
thing-type.shelly.shellyplusuni.description = Shelly Plus UNI (Universelles Sensormodul)
|
||||
thing-type.shelly.shellyplusht.description = Shelly Plus HT - Feuchtigkeits- und Temperatursensor mit Anzeigefeld
|
||||
thing-type.shelly.shellyplushtg3.description = Shelly Plus HT Gen 3 - Feuchtigkeits- und Temperatursensor mit Display
|
||||
thing-type.shelly.shellyplussmoke.description = Shelly Plus Smoke - Rauchmelder mit Alarm
|
||||
thing-type.shelly.shellypluswdus.description = Shelly Wall Dimmer US
|
||||
thing-type.shelly.shellyplus10v.description = Shelly Plus Dimmer 10V
|
||||
|
||||
-15
@@ -19,21 +19,6 @@
|
||||
<config-description-ref uri="thing-type:shelly:battery-gen2"/>
|
||||
</thing-type>
|
||||
|
||||
<thing-type id="shellyhtg3">
|
||||
<label>ShellyPlus H&T Gen 3</label>
|
||||
<description>@text/thing-type.shelly.shellypludhtg3.description</description>
|
||||
<category>Sensor</category>
|
||||
<semantic-equipment-tag>Sensor</semantic-equipment-tag>
|
||||
<channel-groups>
|
||||
<channel-group id="sensors" typeId="sensorData"/>
|
||||
<channel-group id="battery" typeId="batteryStatus"/>
|
||||
<channel-group id="device" typeId="deviceStatus"/>
|
||||
</channel-groups>
|
||||
|
||||
<representation-property>serviceName</representation-property>
|
||||
<config-description-ref uri="thing-type:shelly:battery-gen2"/>
|
||||
</thing-type>
|
||||
|
||||
<thing-type id="shellyplussmoke">
|
||||
<label>Shelly Plus Smoke</label>
|
||||
<description>@text/thing-type.shelly.shellyplussmoke.description</description>
|
||||
|
||||
+1
-1
@@ -130,7 +130,7 @@ public class ShellyDeviceProfileTest {
|
||||
Arguments.of(THING_TYPE_SHELLYPRO4PM, true, false), //
|
||||
Arguments.of(THING_TYPE_SHELLYPLUSDIMMERUS, true, false), //
|
||||
Arguments.of(THING_TYPE_SHELLYPLUSDIMMER10V, true, false), //
|
||||
Arguments.of(THING_TYPE_SHELLYPLUSHTG3, true, false), //
|
||||
Arguments.of(THING_TYPE_SHELLYPLUSHT, true, false), //
|
||||
Arguments.of(THING_TYPE_SHELLYPLUSSMOKE, true, false), //
|
||||
Arguments.of(THING_TYPE_SHELLYPLUSWALLDISPLAY, true, false), //
|
||||
|
||||
|
||||
+3
-3
@@ -225,9 +225,9 @@ public class ShellyThingCreatorTest {
|
||||
@Test
|
||||
void getThingUIDReturnsThingTypeMatchingServiceName() {
|
||||
Set<ThingTypeUID> excludedThingTypeUids = Set.of(THING_TYPE_SHELLY2_RELAY, THING_TYPE_SHELLY2_ROLLER,
|
||||
THING_TYPE_SHELLY25_ROLLER, THING_TYPE_SHELLY25_RELAY, THING_TYPE_SHELLYPLUSHTG3,
|
||||
THING_TYPE_SHELLYPLUS2PM_RELAY, THING_TYPE_SHELLYPLUS2PM_ROLLER, THING_TYPE_SHELLYPRO2,
|
||||
THING_TYPE_SHELLYPRO2PM_ROLLER, THING_TYPE_SHELLYPRO2PM_RELAY, THING_TYPE_SHELLYRGBW2_COLOR);
|
||||
THING_TYPE_SHELLY25_ROLLER, THING_TYPE_SHELLY25_RELAY, THING_TYPE_SHELLYPLUS2PM_RELAY,
|
||||
THING_TYPE_SHELLYPLUS2PM_ROLLER, THING_TYPE_SHELLYPRO2, THING_TYPE_SHELLYPRO2PM_ROLLER,
|
||||
THING_TYPE_SHELLYPRO2PM_RELAY, THING_TYPE_SHELLYRGBW2_COLOR);
|
||||
|
||||
for (ThingTypeUID supportedThingTypeUid : SUPPORTED_THING_TYPES.stream()
|
||||
.filter(uid -> !excludedThingTypeUids.contains(uid)).toList()) {
|
||||
|
||||
Reference in New Issue
Block a user