Skip to content

Commit b15c372

Browse files
authored
Merge branch 'dev' into sinope-sw2500zb-press-release-events
2 parents ec0d580 + de3643c commit b15c372

File tree

3 files changed

+32
-3
lines changed

3 files changed

+32
-3
lines changed

tests/test_tuya_builder.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,25 +67,35 @@ class TestEnum(t.enum8):
6767
.tuya_switch(
6868
dp_id=6,
6969
attribute_name="test_onoff",
70+
translation_key="test_onoff",
71+
fallback_name="Test on/off",
7072
)
7173
.tuya_number(
7274
dp_id=7,
7375
attribute_name="test_number",
7476
type=t.uint16_t,
77+
translation_key="test_number",
78+
fallback_name="Test number",
7579
)
7680
.tuya_binary_sensor(
7781
dp_id=8,
7882
attribute_name="test_binary",
83+
translation_key="test_binary",
84+
fallback_name="Test binary",
7985
)
8086
.tuya_sensor(
8187
dp_id=9,
8288
attribute_name="test_sensor",
8389
type=t.uint8_t,
90+
translation_key="test_sensor",
91+
fallback_name="Test sensor",
8492
)
8593
.tuya_enum(
8694
dp_id=10,
8795
attribute_name="test_enum",
8896
enum_class=TestEnum,
97+
translation_key="test_enum",
98+
fallback_name="Test enum",
8999
)
90100
.tuya_humidity(dp_id=11)
91101
.add_to_registry()

zhaquirks/lixee/zlinky.py

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
Identify,
1212
Ota,
1313
PowerConfiguration,
14+
Time,
1415
)
1516
from zigpy.zcl.clusters.homeautomation import ElectricalMeasurement, MeterIdentification
1617
from zigpy.zcl.clusters.smartenergy import Metering
@@ -24,6 +25,7 @@
2425
PROFILE_ID,
2526
)
2627
from zhaquirks.lixee import LIXEE, ZLINKY_MANUFACTURER_CLUSTER_ID
28+
from zhaquirks.tuya import TuyaManufCluster
2729

2830

2931
class ZLinkyTICManufacturerCluster(CustomCluster):
@@ -200,9 +202,25 @@ class ZLinkyTIC(CustomDevice):
200202

201203

202204
class ZLinkyTICFWV12(ZLinkyTIC):
203-
"""ZLinky_TIC from LiXee with firmware v12.0+."""
205+
"""ZLinky_TIC from LiXee with firmware v12.0 & v13.0."""
204206

205207
signature = deepcopy(ZLinkyTIC.signature)
206208

207-
# Insert PowerConfiguration cluster in signature for devices with firmware v12.0+
209+
# Insert PowerConfiguration cluster in signature for devices with firmware v12.0 & v13.0
208210
signature[ENDPOINTS][1][INPUT_CLUSTERS].insert(1, PowerConfiguration.cluster_id)
211+
212+
213+
class ZLinkyTICFWV14(ZLinkyTICFWV12):
214+
"""ZLinky_TIC from LiXee with firmware v14.0+."""
215+
216+
signature = deepcopy(ZLinkyTICFWV12.signature)
217+
replacement = deepcopy(ZLinkyTICFWV12.replacement)
218+
219+
# Insert Time configuration cluster in signature for devices with firmware v14.0+
220+
signature[ENDPOINTS][1][INPUT_CLUSTERS].insert(1, Time.cluster_id)
221+
222+
# Insert Tuya cluster in signature for devices with firmware v14.0+
223+
signature[ENDPOINTS][1][INPUT_CLUSTERS].insert(7, TuyaManufCluster.cluster_id)
224+
signature[ENDPOINTS][1][OUTPUT_CLUSTERS].insert(1, TuyaManufCluster.cluster_id)
225+
226+
replacement[ENDPOINTS][1][INPUT_CLUSTERS].insert(1, Time.cluster_id)

zhaquirks/tuya/ts0601_trv.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1527,7 +1527,8 @@ def __init__(self, *args, **kwargs):
15271527
("_TZE200_cwnjrr72", "TS0601"),
15281528
("_TZE200_2atgpdho", "TS0601"),
15291529
("_TZE200_pvvbommb", "TS0601"),
1530-
("_TZE200_4eeyebrt", "TS0601"),
1530+
("_TZE200_4eeyebrt", "TS0601"), # Immax NEO Smart (v1)
1531+
("_TZE200_rufdtfyv", "TS0601"), # Immax NEO Smart (v2)
15311532
("_TZE200_cpmgn2cf", "TS0601"),
15321533
("_TZE200_9sfg7gm0", "TS0601"),
15331534
("_TZE200_8whxpsiw", "TS0601"),

0 commit comments

Comments
 (0)