Skip to content

Commit e5ece5f

Browse files
committed
Add Z-Wave support for Red series switches
This is currently untested.
1 parent 020ed02 commit e5ece5f

File tree

8 files changed

+10459
-3443
lines changed

8 files changed

+10459
-3443
lines changed

README.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ What it can do:
2626
- **Even more**
2727
There are some more goodies in to docs below. Enjoy!
2828

29-
_Note: currently this is limited to Blue switches using ZHA or Zigbee2MQTT, but other Inovelli switches will be added in the future._
29+
_Note: currently this is limited to Blue switches using ZHA or Zigbee2MQTT and Red switches using Z-Wave JS, but other Inovelli switches will be added in the future._
3030

3131
**Configure notifications** for multiple switches easily:
3232

@@ -273,6 +273,19 @@ Restore state functionality is provided via a subset of entities:
273273

274274
If you disable these entities, it is possible that various other entities may not be restored after restarting Home Assistant.
275275

276+
##### Z-Wave
277+
278+
Only the Red series switches are supported by this integration as the Black series switches do not have a concept of notifications.
279+
280+
Some of the older Red series switches only have a single LED or have a subset of available effects. Lampie will do the following for these switches:
281+
282+
- If an unsupported effect is used, it will choose something similar
283+
- If [individual LEDs](#full-led-configuration) are used on a switch with just one LED, the first LED settings will be used
284+
285+
Unlike the Blue series switches under ZHA, there is no way to receive events for when a notification expires (it only supports, for instance, when the config button is dobule pressed `property_key_name="003"` and `value="KeyPressed2x"`). This may be supported in the firmware and not yet available for end user consumption.
286+
287+
This integration therefore handles notification expiration itself for switches configured with Z-Wave. This may change unexpectedly in the future—if and when it is possible, Lampie will change to sending durations to the firmware.
288+
276289
## More Screenshots
277290

278291
Once configured, the integration links the various entities to logical devices:

custom_components/lampie/const.py

Lines changed: 86 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,92 @@
3232
CONF_SWITCH_ENTITIES: Final = "switches"
3333

3434
INOVELLI_MODELS = {
35-
"VZM30-SN", # switch
36-
"VZM31-SN", # two in one switch/dimmer
37-
"VZM35-SN", # fan switch
38-
"VZM36", # canopy module
35+
"LZW30-SN", # red on/off switch
36+
"LZW31-SN", # red dimmer
37+
"LZW36", # red fan/light combo
38+
"VZM30-SN", # blue switch
39+
"VZM31-SN", # blue 2-in-1 switch/dimmer
40+
"VZM35-SN", # blue fan switch
41+
"VZM36", # blue canopy module
42+
"VZW31-SN", # red 2-in-1 dimmer
3943
}
4044

45+
46+
ZWAVE_EFFECT_PARAMETERS = {
47+
"LZW31-SN": 16, # red dimmer
48+
"LZW30-SN": 8, # red on/off switch
49+
"LZW36_light": 24, # red fan/light combo
50+
"LZW36_fan": 25, # red fan/light combo
51+
"VZW31-SN": 99, # red 2-in-1 dimmer
52+
"VZW31-SN_individual_1": 64,
53+
"VZW31-SN_individual_2": 69,
54+
"VZW31-SN_individual_3": 74,
55+
"VZW31-SN_individual_4": 79,
56+
"VZW31-SN_individual_5": 84,
57+
"VZW31-SN_individual_6": 89,
58+
"VZW31-SN_individual_7": 94,
59+
}
60+
61+
ZWAVE_EFFECT_MAPPING = {
62+
"LZW30-SN": { # red on/off switch
63+
"CLEAR": 0,
64+
"AURORA": 4,
65+
"MEDIUM_BLINK": 3,
66+
"CHASE": 2,
67+
"FAST_CHASE": 2,
68+
"SLOW_CHASE": 3,
69+
"FAST_FALLING": 2,
70+
"MEDIUM_FALLING": 3,
71+
"SLOW_FALLING": 3,
72+
"OPEN_CLOSE": 4,
73+
"FAST_RISING": 2,
74+
"MEDIUM_RISING": 3,
75+
"SLOW_RISING": 3,
76+
"FAST_SIREN": 4,
77+
"SLOW_SIREN": 4,
78+
"SMALL_TO_BIG": 4,
79+
},
80+
"LZW31-SN": { # red dimmer
81+
"AURORA": 4,
82+
"FAST_BLINK": 3,
83+
"MEDIUM_BLINK": 4,
84+
"SLOW_BLINK": 4,
85+
"CHASE": 2,
86+
"FAST_CHASE": 2,
87+
"SLOW_CHASE": 2,
88+
"FAST_FALLING": 2,
89+
"MEDIUM_FALLING": 2,
90+
"SLOW_FALLING": 2,
91+
"OPEN_CLOSE": 2,
92+
"PULSE": 5,
93+
"FAST_RISING": 2,
94+
"MEDIUM_RISING": 2,
95+
"SLOW_RISING": 2,
96+
"SLOW_SIREN": 2,
97+
"FAST_SIREN": 2,
98+
"SMALL_TO_BIG": 2,
99+
},
100+
"LZW36": { # red fan/light combo
101+
"AURORA": 4,
102+
"FAST_BLINK": 3,
103+
"MEDIUM_BLINK": 4,
104+
"SLOW_BLINK": 4,
105+
"CHASE": 2,
106+
"FAST_CHASE": 2,
107+
"SLOW_CHASE": 2,
108+
"FAST_FALLING": 2,
109+
"MEDIUM_FALLING": 2,
110+
"SLOW_FALLING": 2,
111+
"OPEN_CLOSE": 2,
112+
"PULSE": 5,
113+
"FAST_RISING": 2,
114+
"MEDIUM_RISING": 2,
115+
"SLOW_RISING": 2,
116+
"SLOW_SIREN": 2,
117+
"FAST_SIREN": 2,
118+
"SMALL_TO_BIG": 2,
119+
},
120+
}
121+
122+
41123
TRACE: Final = 5

0 commit comments

Comments
 (0)