Skip to content

Commit

Permalink
Merge pull request #22 from claudegel/new-version
Browse files Browse the repository at this point in the history
Better support for Calypso
  • Loading branch information
claudegel authored Dec 10, 2023
2 parents 335ded4 + 6bc2e11 commit 76c196c
Show file tree
Hide file tree
Showing 5 changed files with 133 additions and 211 deletions.
80 changes: 51 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,30 +45,30 @@ I'll list here all the custom cluster attribute with explanation about how to us
|0xff01|0x0002|2|t.enum8|keypadLockout|0 = unlocked, 1 = locked, 2 = prevent disconnect|read/write/report|
|0xff01|0x0003|3|t.uint16_t|firmware_number| |read/report|
|0xff01|0x0004|4|t.CharacterString|firmware_version| |read/report|
|0xff01|0x0010|16|t.int16s|outdoor_temp|celcius * 100|read/write/report|
|0xff01|0x0010|16|t.int16s|outdoor_temp|celsius * 100|read/write/report|
|0xff01|0x0011|17|t.uint16_t|outdoor_temp_timeout| Delay in seconds before reverting to setpoint display if no more outdoor temp is received|read/write/report|
|0xff01|0x0012|18|t.enum8|config2ndDisplay| 0 = auto, 1 = setpoint, 2 = outside temperature.|read/write/report|
|0xff01|0x0020|32|t.uint32_t|secs_since_2k| second since year 2000|read/write/report|
|0xff01|0x0070|112|t.bitmap8|currentLoad| watt/hr|read/report|
|0xff01|0x0071|113|t.int8s|ecoMode| default:-128, -100-0-100%|read/write/report|
|0xff01|0x0072|114|t.uint8_t|ecoMode1| default:255, 0-99 Set maximum operating percentage 0% to 99% (225 = 100%)|read/write/report|
|0xff01|0x0073|115|t.uint8_t|ecoMode2| default 255, 0-100|read/write/report|
|0xff01|0x0071|113|t.int8s|eco_setpoint_delta| off:-128, celsius*+-10, amount of setpoint reduction/increase for peak and pre-heating|read/write/report|
|0xff01|0x0072|114|t.uint8_t|eco_pi_heating_demand_limit| off:255, range: 0-99 Set pi_heating_demand percentage limit 0% to 99% (225 = 100%)|read/write/report|
|0xff01|0x0073|115|t.uint8_t|ecoMode2| off:255, range: 0-100|read/write/report|
|0xff01|0x0075|117|t.bitmap32|unknown testing|0|read/write/report|
|0xff01|0x0080|128|t.uint32_t|unknown|17563654|read/report|
|0xff01|0x0100|256|t.uint8_t|unknown testing|0|read/report
|0xff01|0x0101|257|Array|unknown|Array(type=AnonymousLVList, value=[6, 0, 1, 5])|read/report|
|0xff01|0x0102|258|t.uint8_t|unknown|0|read|
|0xff01|0x0103|259|Array|unknown|Array(type=AnonymousLVList, value=[1, 0, 0, 0])|read|
|0xff01|0x0104|260|t.int16s|setpoint|celcius * 100|read/write|
|0xff01|0x0104|260|t.int16s|setpoint|celsius * 100|read/write|
|0xff01|0x0105|261|t.enum8|airFloorMode|Air: 1, floor: 2|read/write|
|0xff01|0x0106|262|t.enum8|auxOutputMode|0=off, 1=expantion module|read/write|
|0xff01|0x0107|263|t.int16s|FloorTemperature|celcius*100|read|
|0xff01|0x0108|264|t.int16s|airMaxLimit|temp: celcius*100, valid only if floor mode is selected|read/write|
|0xff01|0x0109|265|t.int16s|floorMinSetpoint| off: -32768, temp: celcius*100|read/write|
|0xff01|0x010A|266|t.int16s|floorMaxSetpoint| off: -32768, temp: celcius*100|read/write|
|0xff01|0x0107|263|t.int16s|FloorTemperature|celsius*100|read|
|0xff01|0x0108|264|t.int16s|airMaxLimit|temp: celsius*100, valid only if floor mode is selected|read/write|
|0xff01|0x0109|265|t.int16s|floorMinSetpoint| off: -32768, temp: celsius*100|read/write|
|0xff01|0x010A|266|t.int16s|floorMaxSetpoint| off: -32768, temp: celsius*100|read/write|
|0xff01|0x010B|267|t.enum8|tempSensorType| 0=10k, 1=12k|read/write|
|0xff01|0x010C|268|t.uint8_t|floorLimitStatus|0=ok, 1=floorLimitLowReached, 2=floorLimitMaxReached, 3=floorAirLimitMaxReached|report/read|
|0xff01|0x010D|269|t.int16s|RoomTemperature|celcius*100|read|
|0xff01|0x010D|269|t.int16s|RoomTemperature|celsius*100|read|
|0xff01|0x0114|276|t.enum8|timeFormat|0=24h, 1=12h|read/write/report|
|0xff01|0x0115|277|t.enum8|gfciStatus|0=ok, 1=error|report/read|
|0xff01|0x0116|278|t.enum8|auxMode|0=off, 1=auto, 3=cool, 4=heat|read|
Expand All @@ -77,20 +77,20 @@ I'll list here all the custom cluster attribute with explanation about how to us
|0xff01|0x0119|281|t.uint16_t|connectedLoad|watt/hr|read/write|
|0xff01|0x0128|296|t.uint8_t|pumpProtectionStatus| Off: 0x00, On: 0x01|read/write|
|0xff01|0x012A|298|t.enum8|pumpProtectionDuration|default:60, 5,10,15,20,30,60|read/write/report|
|0xff01|0x012B|299|t.int16s|currentSetpoint|Celcius*100|read/write/report|
|0xff01|0x012B|299|t.int16s|currentSetpoint|Celsius*100|read/write/report|
|0xff01|0x012C|300|Array|unknown|Array(type=AnonymousLVList, value=[16, 0, 0, 0, 0, 0, 176, 240, 230, 44]) |read|
|0xff01|0x012D|301|t.int16s|reportLocalTemperature|Celcius*100|read/report|
|0xff01|0x012D|301|t.int16s|reportLocalTemperature|Celsius*100|read/report|
|0xff01|0x0200|512|t.bitmap32|status| 0x00000000|report/read|
|0xff01|0x0202|514|t.enum8|unknown|2|read|
|0xff01|0xFFFD|65533|t.uint16_t|cluster_revision|0 |read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0201|0x0000|0|t.int16s|LocalTemperature|celcius*100|report/read|
|0x0201|0x0000|0|t.int16s|LocalTemperature|celsius*100|report/read|
|0x0201|0x0002|2|t.bitmap8|occupancy|1=occupied, 0=unoccupied|read|
|0x0201|0x0008|8|t.uint8_t|PIHeatingDemand|0 -- 100%|report/read|
|0x0201|0x0012|21|t.int16s|occupied_heating_setpoint|celcius*100|report/read/write|
|0x0201|0x0014|21|t.int16s|unoccupied_heating_setpoint|celcius*100|read/write|
|0x0201|0x0015|21|t.int16s|MinHeating Setpoint|celcius*100|read/write|
|0x0201|0x0016|22|t.int16s|MaxHeating Setpoint|celcius*100|read/write|
|0x0201|0x0012|21|t.int16s|occupied_heating_setpoint|celsius*100|report/read/write|
|0x0201|0x0014|21|t.int16s|unoccupied_heating_setpoint|celsius*100|read/write|
|0x0201|0x0015|21|t.int16s|MinHeating Setpoint|celsius*100|read/write|
|0x0201|0x0016|22|t.int16s|MaxHeating Setpoint|celsius*100|read/write|
|0x0201|0x001C|28|t.enum8|SystemMode|0=off, 4=heat|read/write|
|0x0201|0x0400|1024|t.enum8|SetOccupancy| Home: 0, away:1|read/write|
|0x0201|0x0401|1025|t.uint16_t|MainCycleOutput| Number of second|read/write|
Expand All @@ -101,7 +101,7 @@ I'll list here all the custom cluster attribute with explanation about how to us
|0x0b04|0x050d|1293|t.uint16_t|active_power_max|watt/hr|read|
|0x0b04|0x050f|1295|t.uint16_t|Apparent_Power|watt/hr|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0204|0x0000|0|t.enum8|TemperatureDisplayMode|0=celcius, 1=farenheight|read/write|
|0x0204|0x0000|0|t.enum8|TemperatureDisplayMode|0=celsius, 1=farenheight|read/write|
|0x0204|0x0001|1|t.enum8|keypadLockout|0=no lock, 1=lock|read/write|
| --- | --- | --- | --- | --- | --- | ---|
|0x0702|0x0000|0|t.uint48_t|CurrentSummationDelivered|watt/hr |report/read|
Expand Down Expand Up @@ -191,15 +191,37 @@ I'll list here all the custom cluster attribute with explanation about how to us
|0xff01|0x0002|2|t.enum8|keypadLockout|0 = unlocked, 1 = locked|read/write|
|0xff01|0x0004|4|t.CharacterString|firmware_version|1|read|
|0xff01|0x0010|16|t.int16s|unknown|400| |
|0xff01|0x0013|19|t.enum8|tankSize|1,2,3,4|read/write|
|0xff01|0x0013|19|t.enum8|unknown|1,2,3,4,16,21|read/write|
|0xff01|0x0035|53|t.uint16_t|unknown|0|read/report|
|0xff01|0x0037|55|t.uint16_t|unknown|744|read/write/report|
|0xff01|0x0038|56|t.enum8|unknown|0|read/report|
|0xff01|0x0060|96|t.uint16_t|ConnectedLoad|watt/hr|read|
|0xff01|0x0070|112|t.bitmap8|CurrentLoad|watt/hr|read|
|0xff01|0x0076|118|t.uint8_t|drConfigWaterTempMin|45 or 0| |
|0xff01|0x0077|119|t.uint8_t|drConfigWaterTempTime|2| |
|0xff01|0x0078|120|t.uint16_t|drWTTimeOn|240| |
|0xff01|0x0074|116|t.enum8|unknown|255|read/write/report|
|0xff01|0x0076|118|t.uint8_t|drConfigWaterTempMin|0=off, 45 to 55 celsius|read/write/report|
|0xff01|0x0077|119|t.uint8_t|drConfigWaterTempTime|2|read/write/report|
|0xff01|0x0078|120|t.uint16_t|drWTTimeOn|240|read/write/report|
|0xff01|0x0079|121|t.bitmap8|unknown| 0|report/read|
|0xff01|0x007A|122|t.uint16_t|unknown|0|read/write/report|
|0xff01|0x007B|123|t.uint16_t|unknown|288|read/write/report|
|0xff01|0x007C|124|t.int16s|min_measured_temp|water temp celsius*100|read/report|
|0xff01|0x007D|125|t.int16s|max_measured_temp|water temp celsius*100|read/report|
|0xff01|0c0080|122|t.uint32_t|unknown|0|read/report|
|0xff01|0x0090|144|t.uint32_t|CurrentSummationDelivered|kwh|read/report|
|0xff01|0x00A0|160|t.uint32_t|Timer| Time, 1 to 86400 seconds|read/write/report|
|0xff01|0x00A1|161|t.uint32_t|Timer_countDown| Seconds remaining on timer|read/report|
|0xff01|0x00B0|176|t.Bool|unknown|1|read/report|
|0xff01|0x0101|257|Array| |read/report|
|0xff01|0x012A|298|t.enum8|unknown|60|read/write/report|
|0xff01|0x012C|300|Array|unknown| |read/report|
|0xff01|0x0200|512|t.bitmap32|status| 0x00000000| report/read|
|0xff01|0x0202|514|t.enum8|unknown|1|read/report|
|0xff01|0x0203|515|t.enum8|unknown|12|read/report|
|0xff01|0x0280|640|t.int16s|max_measured_value|5300|read/write/report|
|0xff01|0x0281|641|t.uint16_t|unknown|0|read/write/report|
|0xff01|0x0282|642|t.uint16_t|unknown|0|read/write/report|
|0xff01|0x0283|643|t.uint8_t|ColdLoadPickupStatus| 1, 2|read|
|0xff01|0x0284|644|t.uint16_t|coldLoadPickupRemainingTime|65535=off countdown| |
|0xff01|0xFFFD|65533|t.uint16_t|cluster_revision| |read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0500|0x0002|2|t.uint16_t|ZoneStatus|0=no leak, 1=leak|read|
Expand Down Expand Up @@ -231,8 +253,8 @@ I'll list here all the custom cluster attribute with explanation about how to us
|1|0x0006|0x0000|0|t.Bool|OnOff|1=on, 0=off|report/read|
|2|0x0006|0x0000|0|t.Bool|OnOff2|1=on, 0=off|report/read|
| --- | --- | --- | --- | --- | --- | --- | ---|
|1|0x0402|0x0000|0|t.int16s|Measured value, indoor temperature|celcius*100|report/read|
|2|0x0402|0x0000|0|t.int16s|Measured value, outside temperature|celcius*100|report/read|
|1|0x0402|0x0000|0|t.int16s|Measured value, indoor temperature|celsius*100|report/read|
|2|0x0402|0x0000|0|t.int16s|Measured value, outside temperature|celsius*100|report/read|
| --- | --- | --- | --- | --- | --- | --- | ---|
|1|0x0405|0x0000|0|t.uint16_t|measured value, relative humidity|%|report/read|

Expand All @@ -248,7 +270,7 @@ I'll list here all the custom cluster attribute with explanation about how to us
| --- | --- | --- | --- | --- | --- | ---|
|0x0006|0x0000|0|t.Bool|OnOff|1=on, 0=off|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0402|0x0000|0|t.uint16_t|MeasuredValue, Temperature|celcius*100|report/read|
|0x0402|0x0000|0|t.uint16_t|MeasuredValue, Temperature|celsius*100|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0702|0x0000|0|t.uint48_t|CurrentSummationDelivered| L/h (see below)|report/read|
|0x0702|0x0200|512|t.bitmap8|status|0=off, 1=off/armed, 2=on|read|
Expand Down Expand Up @@ -285,7 +307,7 @@ I'll list here all the custom cluster attribute with explanation about how to us
| --- | --- | --- | --- | --- | --- | ---|
|0x0006|0x0000|0|t.Bool|OnOff|1=on, 0=off|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0402|0x0000|0|t.uint16_t|MeasuredValue, Temperature|celcius|report/read|
|0x0402|0x0000|0|t.uint16_t|MeasuredValue, Temperature|celsius|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0404|0x0000|0|t.uint16_t|MeasuredValue, flowrate|L/hr|report/read|
|0x0404|0x0001|1|t.uint16_t|min_measured_value|0|read|
Expand All @@ -309,7 +331,7 @@ I'll list here all the custom cluster attribute with explanation about how to us
| --- | --- | --- | --- | --- | --- | ---|
|0x0001|0x0020|32|t.uint8_t|Battery_voltage|voltage * 10|report/read
| --- | --- | --- | --- | --- | --- | ---|
|0x0402|0x0000|0|t.uint16_t|MeasuredValue, Temperature|celcius * 100|report/read|
|0x0402|0x0000|0|t.uint16_t|MeasuredValue, Temperature|celsius * 100|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x0500|0x0030|48|t.uint16_t|leak_alarm| 0=no leak, 1=leak|read|

Expand All @@ -321,7 +343,7 @@ I'll list here all the custom cluster attribute with explanation about how to us
|0x0001|0x0021|33|t.uint8_t|remaining battey percentage|%|report/read|
|0x0001|0x003e|62|t.bitmap32|battery_alarm_state|0=ok, 1=weak battery|report/read
| --- | --- | --- | --- | --- | --- | ---|
|0x0402|0x0000|0|t.int16s|MeasuredValue, device Temperature|celcius * 100|report/read|
|0x0402|0x0000|0|t.int16s|MeasuredValue, device Temperature|celsius * 100|report/read|
| --- | --- | --- | --- | --- | --- | ---|
|0x000c|0x0055|85|t.uint16_t|Present value, angle| angle of the gauge needle in degree|report/read|
| --- | --- | --- | --- | --- | --- | ---|
Expand Down Expand Up @@ -696,7 +718,7 @@ template:

# Automation examples:
- Sending outside temperature to thermostats:
- Celcius:
- Celsius:
```
- alias: Send-OutdoorTemp
trigger:
Expand Down
140 changes: 10 additions & 130 deletions light.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,12 @@
TURN_ON,
VALUE,
)
from zhaquirks.sinope import SINOPE

ATTRIBUTE_ACTION = "actionReport"
SINOPE_MANUFACTURER_CLUSTER_ID = 0xFF01
from zhaquirks.sinope import (
LIGHT_DEVICE_TRIGGERS,
SINOPE,
SINOPE_MANUFACTURER_CLUSTER_ID,
CustomDeviceTemperatureCluster,
)


class SinopeTechnologiesManufacturerCluster(CustomCluster):
Expand Down Expand Up @@ -105,7 +107,7 @@ class Action(t.enum8):
0x0056: ("phase_control", PhaseControl, True),
0x0058: ("double_up_full", DoubleFull, True),
0x0080: ("unknown_attr_5", t.uint32_t, True),
0x0090: ("unknown_attr_6", t.uint32_t, True),
0x0090: ("current_summation_delivered", t.uint32_t, True),
0x00A0: ("timer", t.uint32_t, True),
0x00A1: ("timer_countdown", t.uint32_t, True),
0x0119: ("connected_load", t.uint16_t, True),
Expand All @@ -118,14 +120,6 @@ class LightManufacturerCluster(EventableCluster, SinopeTechnologiesManufacturerC
"""LightManufacturerCluster: fire events corresponding to press type."""


class CustomDeviceTemperatureCluster(CustomCluster, DeviceTemperature):
"""Custom DeviceTemperature Cluster."""

def _update_attribute(self, attrid, value):
if attrid == 0x0000:
super()._update_attribute(attrid, value * 100)


class SinopeTechnologieslight(CustomDevice):
"""SinopeTechnologiesLight custom device."""

Expand Down Expand Up @@ -186,45 +180,7 @@ class SinopeTechnologieslight(CustomDevice):
}
}


device_automation_triggers = {
(SHORT_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_SINGLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 2},
},
(SHORT_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_SINGLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 18},
},
(DOUBLE_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_DOUBLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 4},
},
(DOUBLE_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_DOUBLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 20},
},
(LONG_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_HOLD,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 3},
},
(LONG_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_HOLD,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 19},
},
}
device_automation_triggers = LIGHT_DEVICE_TRIGGERS


class SinopeDM2500ZB(SinopeTechnologieslight):
Expand Down Expand Up @@ -289,45 +245,7 @@ class SinopeDM2500ZB(SinopeTechnologieslight):
}
}


device_automation_triggers = {
(SHORT_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_SINGLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 2},
},
(SHORT_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_SINGLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 18},
},
(DOUBLE_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_DOUBLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 4},
},
(DOUBLE_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_DOUBLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 20},
},
(LONG_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_HOLD,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 3},
},
(LONG_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_HOLD,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 19},
},
}
device_automation_triggers = LIGHT_DEVICE_TRIGGERS


class SinopeDM2550ZB(SinopeTechnologieslight):
Expand Down Expand Up @@ -396,42 +314,4 @@ class SinopeDM2550ZB(SinopeTechnologieslight):
}
}


device_automation_triggers = {
(SHORT_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_SINGLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 2},
},
(SHORT_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_SINGLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 18},
},
(DOUBLE_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_DOUBLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 4},
},
(DOUBLE_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_DOUBLE,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 20},
},
(LONG_PRESS, TURN_ON): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_HOLD,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 3},
},
(LONG_PRESS, TURN_OFF): {
ENDPOINT_ID: 1,
CLUSTER_ID: 65281,
COMMAND: COMMAND_BUTTON_HOLD,
ARGS: {ATTRIBUTE_ID: 84, ATTRIBUTE_NAME: ATTRIBUTE_ACTION, VALUE: 19},
},
}
device_automation_triggers = LIGHT_DEVICE_TRIGGERS
10 changes: 4 additions & 6 deletions sensor.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""Module to handle quirks of the Sinopé Technologies water leak sensor and level monitor.
"""Module to handle quirks of the Sinopé Technologies water leak sensor and level monitor.
It add manufacturer attributes for IasZone cluster for the water leak alarm.
Supported devices are WL4200, WL4200S and LM4110-ZB
Expand Down Expand Up @@ -27,9 +27,7 @@
OUTPUT_CLUSTERS,
PROFILE_ID,
)
from zhaquirks.sinope import SINOPE

SINOPE_MANUFACTURER_CLUSTER_ID = 0xFF01
from zhaquirks.sinope import SINOPE, SINOPE_MANUFACTURER_CLUSTER_ID


class SinopeManufacturerCluster(CustomCluster):
Expand All @@ -43,8 +41,8 @@ class SinopeManufacturerCluster(CustomCluster):
0x0004: ("firmware_version", t.CharacterString, True),
0x0030: ("unknown_attr_2", t.uint8_t, True),
0x0031: ("unknown_attr_3", t.uint16_t, True),
0x0032: ("unknown_attr_4", t.int16s, True),
0x0033: ("unknown_attr_5", t.int16s, True),
0x0032: ("min_device_temperature", t.int16s, True),
0x0033: ("max_device_temperature", t.int16s, True),
0x0034: ("unknown_attr_6", t.bitmap8, True),
0x0035: ("unknown_attr_7", t.uint16_t, True),
0x0036: ("unknown_attr_8", t.uint16_t, True),
Expand Down
Loading

0 comments on commit 76c196c

Please sign in to comment.