Shelly Plus Wall Dimmer integration

I don’t mean to add “feature request noise” as I’m sure the ShellyForHASS team is aware of the new Plus Wall Dimmer. But just in case here’s a request.

Have you gotten this to work yet?

I just received the new Wall Dimmer. Followed the integration to add the Outbound Websocket url. Home Assistant found it just fine. However, it’s only showing configuration and diagnostic entities. It’s not showing any control entities. I can’t turn it on or off from HA. The Wall Dimmer shows that the websocket is connected. Not sure what else to try at this point.

what do you mean by: Followed the integration to add the Outbound Websocket url? Can you please elaborate, or send a link to these instructions? Thank you!

Yes! I was looking at the Shelly Integration docs for Home Assistant. The section about Gen 2 configuration shows how to set the outbound websocket url. So that connects the device to HA, but doesn’t bring over any controls. I’m wondering if something needs to be done for HA to know about the new Wall Switches.

I tried that, but the status in the shelly device still shows disconnected. It never actually connects. Is there something in HA that I need to activate for this outbound websocket to be seen?

I have the same issue. If you look at the device info HA detected it as a Unifi Device. So no Dimmer entities available

Yeah, I have a Unifi setup as well so maybe that’s doing something to connect.

I was looking through the HA code, and I think there needs to be an entry for the new wall switch in the const file for it to work. I didn’t dig any further however, so it might not be that easy. I wonder if perhaps @thecode knows as a maintainer? I’ll keep digging to see if I can put up a pull request.

I think you’re onto something. I hope this can be added soon…

I’ve been able to control my Shelly plus wall dimmers in HA using MQTT, if you’re willing to go down that path. It’s a basic implementation, but the dimmer and on/off functions are reliable and with very little latency.

Here’s some sample script for your configuration.yaml, if you want to try it:

mqtt:
  light:
    - schema: template
      name: "Dining Room Light"
      unique_id: light.diningroomlight
      command_on_template: '{"id":0, "src": "homeassistant", "method": "Light.Set", "params":{"id":0,"on":true{%- if brightness is defined -%}, "brightness": {{brightness | float | multiply(0.39215686) | round(0)}}{%- endif -%}}}'
      command_off_template: '{"id":0, "src": "homeassistant", "method": "Light.Set", "params":{"id":0,"on":false}}'
      qos: 1
      state_topic: "shellypluswdus-############/events/rpc"
      state_template: '{% if value_json.params["light:0"].output == true %}on{% else %}off{% endif %}'
      command_topic: "shellypluswdus-############/rpc"
      brightness_template: '{{ value_json.params["light:0"].brightness | float | multiply(2.55) | round(0) }}'
      availability_topic: "shellypluswdus-############/online"
      payload_available: "true"
      payload_not_available: "false"
      retain: false
      optimistic: false

You will need a relatively up-to-date HA and of course the mqtt broker setup. On the Shelly side, you need to enable mqtt in the “Networks” section and then enter your HA mqtt broker’s address and user/password.

I have 4 of these working now and I really like the dimmers so far! I have not implemented all of the sensors, such as firmware update, etc. I haven’t seen any reference to power monitoring on these devices yet, but there may be a chance that could be added in a future firmware update? I’m sure support for these devices will be added soon to the official Shelly integration as well as shellyforhass, but for the time being for you early adopters, or if you are one that prefers to use only mqtt with shellys, this might be a good starting place.

The model name is only used for displaying it nicely, it is not mandatory to support new devices.
If the device doesn’t work it means it is not yet supported by the existing code.
Unfortunately all of the developers are living in 230V countries so we don’t have this device.

I presented this request to Shelly, and they said that the HomeAssistant team creates the integration. My Plus Wall Dimmer is recognized by HA, so I guess someone just has to add the configuration (Currently only Reset button is available) and entities.

So I guess we are waiting on the HA team now…

I’ve got a few of these dimmers. I’m not at all familiar with the Shelly integration’s codebase, but I’m happy to pull information from the devices and/or hook one up on a test bench and test out code changes so we can get it integrated :slightly_smiling_face:

2 Likes

I worked with @thecode yesterday and tested out a PR to add support: Add Shelly support for Plus WallDimmer US by thecode · Pull Request #83385 · home-assistant/core · GitHub

PR won’t make it into 2022.12, but I expect it will be merged in time for 2023.1 :slight_smile:

4 Likes

Fantastic, that’s great news! Especially since I just bought a few more from Shelly. I really do like the form factor and functionality. I had a few of the Dimmer 2, but noticed they would flicker when power surges happened. The Plus Dimmer has been great so far.

1 Like

Fantastic news! Any idea if this will allow for this device to be used as a BLE gateway, like other Shelly gen 2 devices?

Trying to see if this is actually deployed and out now? Mine are still acting the same way and I’m not sure if I’m supposed to update something or what. New to all of this :smiley:

Looks like the changes are in 2023.1.0 but I’m not sure how that gets transferred to everyone’s instances. I’ll look around though.

Went to HA today and it said there was an update. Updated and sure enough the switches now have on/off and brightness. Thanks for the work on this. Are there tutorials or walk throughs on how you knew how to do this? I’m a developer myself and wouldn’t mind knowing how to add support for future devices. I looked through the code and that’s one way to learn a bit but I’m getting an understanding just by taking a look at it.

It’s been a bit of time since the last reply, but I just received one of these switches. I have gotten it installed, and added it via the Shelly Integration on HA.

After adding I do get the ability to use as a BLE gateway and I didn’t even know about that functionality soi it’s a bonus!

I also have a switch to turn it on and off, but do not have a brightness control. Was there any additional configuration needed to get the dimmer functionality in HA? @rballonline you had said you do have brightness, did you need to configure the Shelly to achieve this?

I haven’t changed any of the default settings as far as I can tell except for network config.

same issue on my side with a shelly dimmer 2. Did you manage to get the brightness control using the shelly integration?