MQTT Dimmer Switch doesn't display brightness slider

Hi!

I have a few devices communicating with my HA via MQTT. One of these devices are Smart Bulbs that show up on a card with a dimming slider to allow me to adjust their brightness level, another is a dimmer switch that only allows me to turn_on / turn_off the lights.

I searched the forum, but the only other thread I could find that initially sounded similar was: MQTT light brightness min/max range but it’s pretty old, and it also appears to be working for them, they just didn’t realize they had to look at the detail card.

Any thoughts would be appreciated!

-Chad


This is my non-working switch config, I’ve tried with /set at the end of brightness_command_topic and without it:
configuration.yaml:

switch: !include_dir_merge_list mqtt/switches

mqtt/switches/bedroom.yaml

- platform: mqtt
  name: "Master Bedroom Lights"
  state_topic: "smartthings/Master Bedroom Light Dimmer/switch"
  command_topic: "smartthings/Master Bedroom Light Dimmer/switch"
  brightness_state_topic: "smartthings/Master Bedroom Light Dimmer/level"
  brightness_command_topic: "smartthings/Master Bedroom Light Dimmer/level/set"
  payload_on: "on"
  payload_off: "off"
  retain: true

Here’s my working dimming light bulbs config:
configuration.yaml:
light: !include mqtt/lights.yaml

mqtt/lights.yaml

- platform: mqtt
  name: TVNE
  state_topic: "smartthings/NECorner/switch"
  command_topic: "smartthings/NECorner/switch"
  brightness_state_topic: "smartthings/NECorner/level"
  brightness_command_topic: "smartthings/NECorner/level"
  brightness_scale: 101
  payload_on: "on"
  payload_off: "off"
  optimistic: true
  retain: true

Future readers - The problem was that I had this setup as a switch. Since it’s a “Light Switch” I changed it to being setup as a light device and, lo and behold!, a slider appeared.

For completeness, here are the relevant part of my configs (just one device for an example):
configuration.yaml:

light: !include mqtt/lights.yaml

mqtt/lights.yaml:

# Light Switches
- platform: mqtt
  name: "Kitchen Sink Light"
  state_topic: "smartthings/Kitchen Sink Light/switch"
  command_topic: "smartthings/Kitchen Sink Light/switch"
  brightness_state_topic: "smartthings/Kitchen Sink Light/level"
  brightness_command_topic: "smartthings/Kitchen Sink Light/level"
  brightness_scale: 101
  payload_on: "on"
  payload_off: "off"
  optimistic: true
  retain: true

Hopefully that helps someone!
-Chad

2 Likes

Been searching for this for ages. Thanks for sharing!

@ChadCurvin can I ask what kind of device you had that tied to? I’ve been trying to get the GE Z-wave in wall switches working, and I’m seeing some odd behavior. (Lights switching on and off throughout the day)

Sorry, I just saw this reply.

It is a GE Z-Wave Dimmer Paddle. Other than being really slow to respond to a button press (sometimes taking up to 2 full seconds to respond), it works great.

1 Like