Hello all,
Bit of a strange one as I think the removing and moving of a attribute has made things objectively worse, but it could just be a config error on my side - let me preamble:
I made MQTT lights withj RGB strips, one such light has a white component - rgbw in this case.
In the MQTT discovery code I sent through this:
root["on_command_type"] = "first";
root["brightness"] = "true";
root["brightness_scale"] = 255;
root["rgb"] = "true";
root["white_value"] = true;
root["optimistic"] = "false";
root["color_temp"] = "true";
This would enable this in the front-end:
Meaning, the brightness would be exposed to the front end, and in the MQTT message you have this:
MQTT and light brightness
And I of course had a seperate white value control, perfect for what I want.
This was now changed, and you should use the following:
root["color_mode"] = "true";
JsonArray supported_color_mode = root.createNestedArray("supported_color_modes");
supported_color_mode.add("color_temp");
supported_color_mode.add("rgbw");
supported_color_mode.add("white");
Meaning you specify which modes the light has, including white value:
BUT, the brightness is completely messed, it doesn’t get reported back to HA, and doesn’t “stay”:
“Brightness not reported”
Also, in MQTT explorer, we see what is being sent when adjusting the sliders - here I adjusted the color brightness slider:
“Color slider and mqtt”
And now the white value slider:
“White value slider”
The overall brightness slider does not correlate with the white-brightness and color-brightness sliders at all, plus as soon as you click out, the settings are lost:
“Click in”
Click out:
“Click out”
You cannot add the “supported_color_modes” : brightness - as this has to be the only one in the supported color modes - taken from the dev notes:
“Light Documentation”
This only happens when I use the new “supported_color_modes” to achieve the separate white control, but then the brightness is completely messed up. If I use the “older” config, then I cannot have rgbw control using that new menthod.
Does anyone have experience in how to handle this or maybe it is a bug?
Thank you for reading my essay, sorry for all the links, “new users are restricted to one embedded image and 2 links” so I had to split it up.
Cheers,
Nils