Skip to content
5 changes: 5 additions & 0 deletions drivers/SmartThings/zigbee-switch/fingerprints.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2359,6 +2359,11 @@ zigbeeManufacturer:
model: NEXENTRO Dimming Actuator
deviceProfileName: on-off-level
# Inovelli
- id: "Inovelli/VZM30-SN"
deviceLabel: "Inovelli On/Off Blue Series"
manufacturer: Inovelli
model: VZM30-SN
deviceProfileName: inovelli-vzm30-sn
- id: "Inovelli/VZM31-SN"
deviceLabel: "Inovelli 2-in-1 Blue Series"
manufacturer: Inovelli
Expand Down
231 changes: 231 additions & 0 deletions drivers/SmartThings/zigbee-switch/profiles/inovelli-vzm30-sn.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,231 @@
name: inovelli-vzm30-sn
components:
- id: main
capabilities:
- id: switch
version: 1
- id: switchLevel
version: 1
- id: temperatureMeasurement
version: 1
- id: relativeHumidityMeasurement
version: 1
- id: powerMeter
version: 1
- id: energyMeter
version: 1
- id: refresh
version: 1
- id: firmwareUpdate
version: 1
categories:
- name: Switch
- id: button1
label: Down Button
capabilities:
- id: button
version: 1
categories:
- name: RemoteController
- id: button2
label: Up Button
capabilities:
- id: button
version: 1
categories:
- name: RemoteController
- id: button3
label: Config Button
capabilities:
- id: button
version: 1
categories:
- name: RemoteController
preferences:
- name: "notificationChild"
title: "Add Child Device - Notification"
description: "Create Separate Child Device for Notification Control"
required: false
preferenceType: boolean
definition:
default: false
- name: "notificationType"
title: "Notification Effect"
description: "This is the notification effect used by the notification child device"
required: false
preferenceType: enumeration
definition:
options:
"255": "Clear"
"1": "Solid"
"2": "Fast Blink"
"3": "Slow Blink"
"4": "Pulse"
"5": "Chase"
"6": "Open/Close"
"7": "Small-to-Big"
"8": "Aurora"
"9": "Slow Falling"
"10": "Medium Falling"
"11": "Fast Falling"
"12": "Slow Rising"
"13": "Medium Rising"
"14": "Fast Rising"
"15": "Medium Blink"
"16": "Slow Chase"
"17": "Fast Chase"
"18": "Fast Siren"
"19": "Slow Siren"
default: 1
- name: "parameter258"
title: "258. Switch Mode"
description: "Use as a Dimmer or an On/Off switch"
required: false
preferenceType: enumeration
definition:
options:
"0": "Dimmer"
"1": "On/Off (default)"
default: 1
- name: "parameter22"
title: "22. Aux Switch Type"
description: "Set the Aux switch type. Smart Bulb Mode does not work in Dumb 3-Way Switch mode."
required: false
preferenceType: enumeration
definition:
options:
"0": "None"
"1": "3-Way Aux Switch (default)"
default: 1
- name: "parameter52"
title: "52. Smart Bulb Mode"
description: "For use with Smart Bulbs that need constant power and are controlled via commands rather than power. Smart Bulb Mode does not work in Dumb 3-Way Switch mode."
required: false
preferenceType: enumeration
definition:
options:
"0": "Disabled (default)"
"1": "Smart Bulb Mode"
default: 0
- name: "parameter1"
title: "1. Dimming Speed (Remote)"
description: "This changes the speed that the light dims up when controlled from the hub. A setting of '0' turns the light immediately on. Increasing the value slows down the transition speed. Value is multiplied by 100ms.
Default=25 (2500ms or 2.5s)"
required: false
preferenceType: number
definition:
minimum: 0
maximum: 126
default: 25
- name: "parameter2"
title: "2. Dimming Speed (Local)"
description: "This changes the speed that the light dims up when controlled at the switch. A setting of '0' turns the light immediately on. Increasing the value slows down the transition speed. Value is multiplied by 100ms.
(i.e 25 = 2500ms or 2.5s) Default=127 (Sync with parameter 1)"
required: false
preferenceType: number
definition:
minimum: 0
maximum: 127
default: 127
- name: "parameter3"
title: "3. Ramp Rate (Remote)"
description: "This changes the speed that the light turns on when controlled from the hub. A setting of '0' turns the light immediately on. Increasing the value slows down the transition speed. Value is multiplied by 100ms.
(i.e 25 = 2500ms or 2.5s) Default=0"
required: false
preferenceType: number
definition:
minimum: 0
maximum: 127
default: 0
- name: "parameter4"
title: "4. Ramp Rate (Local)"
description: "This changes the speed that the light turns on when controlled at the switch. A setting of '0' turns the light immediately on. Increasing the value slows down the transition speed. Value is multiplied by 100ms.
(i.e 25 = 2500ms or 2.5s) Default=127 (Sync with parameter 3)"
required: false
preferenceType: number
definition:
minimum: 0
maximum: 127
default: 127
- name: "parameter11"
title: "11. Invert Switch"
description: "Inverts the orientation of the switch. Useful when the switch is installed upside down. Essentially up becomes down and down becomes up."
required: false
preferenceType: enumeration
definition:
options:
"0": "No (default)"
"1": "Yes"
default: 0
- name: "parameter15"
title: "15. Level After Power Restored"
description: "The level the switch will return to when power is restored after power failure.
0=Off
1-100=Set Level
101=Use previous level."
required: false
preferenceType: number
definition:
minimum: 0
maximum: 101
default: 101
- name: "parameter95"
title: "95. LED Indicator Color (w/On)"
description: "Set the color of the Full LED Indicator when the load is on."
required: false
preferenceType: enumeration
definition:
options:
"0": "Red"
"7": "Orange"
"28": "Lemon"
"64": "Lime"
"85": "Green"
"106": "Teal"
"127": "Cyan"
"148": "Aqua"
"170": "Blue (default)"
"190": "Violet"
"212": "Magenta"
"234": "Pink"
"255": "White"
default: 170
- name: "parameter96"
title: "96. LED Indicator Color (w/Off)"
description: "Set the color of the Full LED Indicator when the load is off."
required: false
preferenceType: enumeration
definition:
options:
"0": "Red"
"7": "Orange"
"28": "Lemon"
"64": "Lime"
"85": "Green"
"106": "Teal"
"127": "Cyan"
"148": "Aqua"
"170": "Blue (default)"
"190": "Violet"
"212": "Magenta"
"234": "Pink"
"255": "White"
default: 170
- name: "parameter97"
title: "97. LED Indicator Intensity (w/On)"
description: "Set the intensity of the Full LED Indicator when the load is on."
required: false
preferenceType: number
definition:
minimum: 0
maximum: 100
default: 50
- name: "parameter98"
title: "98. LED Indicator Intensity (w/Off)"
description: "Set the intensity of the Full LED Indicator when the load is off."
required: false
preferenceType: number
definition:
minimum: 0
maximum: 100
default: 5
2 changes: 2 additions & 0 deletions drivers/SmartThings/zigbee-switch/src/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@ local zigbee_switch_driver_template = {
capabilities.energyMeter,
capabilities.motionSensor,
capabilities.illuminanceMeasurement,
capabilities.relativeHumidityMeasurement,
capabilities.temperatureMeasurement,
},
sub_drivers = {
lazy_load_if_possible("non_zigbee_devices"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

return function(opts, driver, device)
local INOVELLI_FINGERPRINTS = {
{ mfr = "Inovelli", model = "VZM30-SN" },
{ mfr = "Inovelli", model = "VZM31-SN" },
{ mfr = "Inovelli", model = "VZM32-SN" }
}
Expand Down
41 changes: 40 additions & 1 deletion drivers/SmartThings/zigbee-switch/src/inovelli/common.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,27 @@
local clusters = require "st.zigbee.zcl.clusters"
local device_management = require "st.zigbee.device_management"
local OTAUpgrade = require("st.zigbee.zcl.clusters").OTAUpgrade
local zigbee_constants = require "st.zigbee.constants"
local capabilities = require "st.capabilities"

local M = {}

M.supported_button_values = {
["button1"] = {"pushed","held","down_hold","pushed_2x","pushed_3x","pushed_4x","pushed_5x"},
["button2"] = {"pushed","held","down_hold","pushed_2x","pushed_3x","pushed_4x","pushed_5x"},
["button3"] = {"pushed","held","down_hold","pushed_2x","pushed_3x","pushed_4x","pushed_5x"}
}

-- Utility function to check if device is VZM32-SN
function M.is_vzm32(device)
return device:get_model() == "VZM32-SN"
end

-- Utility function to check if device is VZM32-SN
function M.is_vzm30(device)
return device:get_model() == "VZM30-SN"
end

-- Sends a generic configure for Inovelli devices (all models):
-- - device:configure
-- - send OTA ImageNotify
Expand All @@ -25,10 +43,31 @@ function M.base_device_configure(driver, device, private_cluster_id, mfg_code)
device:send(device_management.build_bind_request(device, private_cluster_id, driver.environment_info.hub_zigbee_eui, 2))

-- Read divisors/multipliers for power/energy reporting
device:send(clusters.SimpleMetering.attributes.Divisor:read(device))
-- Set default divisor to 1000 for VZM32-SN and VZM30-SN. In initial firmware the divisor is incorrectly set to 100.
if M.is_vzm32(device) or M.is_vzm30(device) then
device:set_field(zigbee_constants.SIMPLE_METERING_DIVISOR_KEY, 1000, {persist = true})
else
device:send(clusters.SimpleMetering.attributes.Divisor:read(device))
end
device:send(clusters.SimpleMetering.attributes.Multiplier:read(device))
device:send(clusters.ElectricalMeasurement.attributes.ACPowerDivisor:read(device))
device:send(clusters.ElectricalMeasurement.attributes.ACPowerMultiplier:read(device))

for _, component in pairs(device.profile.components) do
if component.id ~= "main" then
device:emit_component_event(
component,
capabilities.button.supportedButtonValues(
M.supported_button_values[component.id],
{ visibility = { displayed = false } }
)
)
device:emit_component_event(
component,
capabilities.button.numberOfButtons({value = 1}, { visibility = { displayed = false } })
)
end
end
end

return M
Loading
Loading