Control LEDs and LED Effects on Inovelli Black, Red, and Blue Devices by Floor, Area, Group, Device ID, or Entity

@soonerfan237, in “developer tools” → template, if you replace my light entity in the template below with your light entity, what does it give you?

{{ device_attr('light.guest_room_lights_level','model') }}

It gives:

Inovelli 2-in-1 switch + dimmer (VZM31-SN)

That’s with version 1.36? It looks like Inovelli may have renamed the device so I was thinking it might end up with nothing to send because the script can’t find a device with the exact name it’s looking for.

Can you send me the Home Assistant trace from the script or blueprint (whichever you’re using)?

Sorry, that was the output from the downgraded version. Here is the output from version 1.36. Looks like the name did change.

2-in-1 switch + dimmer (VZM31-SN)

Inovelli changed the device name. I can update this pretty easily but I’m swamped at work right now so it might take me until the weekend. Can you hold off on the update until then?

Are you using the blueprint or the script? I can tell you how to modify it quickly using the script. I don’t use blueprints though, so I don’t know if a way to modify the backend code for them.


Note to @kschlichter - Don’t forget to check the Red 800 series to see if they changed too.

That’s totally fine - thank you for the help!

I wasn’t going to be able to let this go so I’ve made the changes. Would you mind testing it in script form with both Zigbee2MQTT 1.35 and 1.36? I want to make sure it picks up both the old and new device names so people don’t need to worry about forward / backward compatibility. I’ve typed out steps for you below, in case you need them. It would really help me out. I don’t have any Blue Series devices. If this works, I can publish a new blueprint tomorrow.

  • In Home Assistant:
    • Click on “Settings” in the left-hand navigation pane.
    • “Automations & Scenes”
    • “Scripts” near the top in a horizontal menu / tab.
    • Blue, “+ Add Script” button in the lower-right.
    • “Create new script”
    • In the upper-right click the vertical ellipsis (three dot) menu and then “edit in Yaml”.
    • Delete the pre-populated lines.
  • Open a new tab
  • In Github (beta script)
    • Since this hasn’t been merged into master yet, in the left-hand nav pane, under files, there’s a drop-down that says “master”. Change that to “Zigbee2MQTT-Inovelli-Device-Name-Change”.
    • On the right side, click the “copy raw file” in between the “raw” and “download” buttons.
  • In Home Assistant:
    • Paste the contents into the Yaml editor.
    • In the vertical ellipsis select “Edit in Visual Editor”
    • Blue, “Save Script” button in the lower right.

To test the script, you can use “developer tools” → “Services” and type “Inovelli LED Settings and Effects” to use the UI, and “Go to Yaml Mode” to see the code for automations. That code can be modified with templates.

I can confirm that this is working for me. Thank you for the quick response!

Thanks for this amazing blueprint/script! Would it be possible to enhance this to support using the Hubitat integration as well? I’m running HA in a VM and using that integration to expose my Hubitat-connected devices to HA via the Maker API.

I’d love to be able to make a group of Inovelli switches (as exposed via the Hubitat integration) within HA and have this script send the appropriate commands to each device in the group. My group would be mixing and matching various Inovelli switch models, of course.

I’ve published this release. Update the blueprint and let me know if you run into any issues. I don’t use blueprints so I’m not sure if there’s something I need to do for the “import” button to update.

I don’t have Hubitat so I’d need you to do all the testing. The first step would be to figure out what the service calls look like for Z-Wave and Zigbee devices. From there it’s probably just a lot of copy / paste. Once you have that, open an issue on GitHub and we’ll go from there.

# Zwave JS
- service: zwave_js.set_config_parameter
  data:
    entity_id: "{{ repeat.item.entities }}"
    parameter: >-
      {% set effect_param = repeat.item.device_type + '_ledbrightness_off' %} 
      {{ "off" if parameters[effect_param] == 0 else parameters[effect_param] }}
    value: "{{ LEDbrightness_off }} "
# Zigbee2mqtt
- service: mqtt.publish
  data:
    topic: >-
      zigbee2mqtt/{{ states[repeat.item].attributes.friendly_name }}/set
      payload: >-
        { "ledIntensityWhenOff": {{ (LEDbrightness_off * 256 / 10) }} }

If anyone has a Red 800 Series “2-in-1” device, I could use some help testing some new code to enable brightness in steps of 1 instead of 10. Previously the script and blueprint could only set brightness to 10%, 20%, … 100%. The new code will set it from 1% to 100% in steps of one for Red 800 Series and Blue Series devices. I don’t have any Red 800 Series devices to test.

Red 500 Series and Black 500 Series are limited by the device to only support steps of 10% so this feature doesn’t apply to these devices.

Beta code to test

How to import and test:

  • In Home Assistant:
    • Click on “Settings” in the left-hand navigation pane.
    • “Automations & Scenes”
    • “Scripts” near the top in a horizontal menu / tab.
    • Blue, “+ Add Script” button in the lower-right.
    • “Create new script”
    • In the upper-right click the vertical ellipsis (three dot) menu and then “edit in Yaml”.
    • Delete the pre-populated lines.
  • Open a new tab
  • In Github (“Beta code to test” link above)
    • Since this hasn’t been merged into master yet, in the left-hand nav pane, under files, there’s a drop-down that says “master”. Change that to “Zigbee2MQTT-Inovelli-Device-Name-Change”.
    • On the right side, click the “copy raw file” in between the “raw” and “download” buttons.
  • In Home Assistant:
    • Paste the contents into the Yaml editor.
    • In the vertical ellipsis select “Edit in Visual Editor”
    • Blue, “Save Script” button in the lower right.

To test the script, you can use “developer tools” → “Services” and type “Inovelli LED Settings and Effects” to use the UI, and “Go to Yaml Mode” to see the code for automations.

My apologies, I forgot to enable notifications on the thread. I would love to beta test for you!

I’ve been able to find this in the Hubitat HACS documentation:

  • Send a command to a Hubitat device
service: hubitat.send_command
data:
  entity_id: switch.some_switch
  command: on
service: hubitat.send_command
data:
  entity_id: light.some_light
  command: setHue
  args: 75
service: hubitat.send_command
data:
  entity_id: light.some_light
  command: setLevel
  args: [50, 3]

I believe this would use the Hubitat Maker API and you wouldn’t be sending the native Z-Wave commands as you do with Zwave JS. Is this sufficient or do you need additional details?

I used the script from 19-can-we-modify-the-brightness-slider-to-be-a-float/inovelli_led.yaml. I’m not 100% sure that each brightness step in .1 increments is working. But it didn’t cause any errors.

1 Like

I do have a credit for your code in my post, it’s in the thanks section. It’s been there since you offered to let me use it. I only copied your implementation of iterating over multiple areas, devices, and entities. I even edited it to use the target selector instead of using 3 separate fields. I’m sorry if you think I copied without credit.

1 Like

I apologize. I only looked at the code on github. I overlooked the comment in the post and I’m so sorry. I’ve edited my comment above, which was totally unnecessary in the first place.

2 Likes

Thanks, I appreciate it. You do bring up a good point, I don’t have any credits on my Github. I will be adding that later today.

GitHub updated with a thanks section. Once again thanks for your code!

Thanks for being so cool about this. I was out of line. I’m really sorry for how I conducted myself.

2 Likes