Hi All,
Apologies in advance for the monster post:
TLDR: I cannot control brightness via my MilightHub using Homeassistant Discovery over MQTT.
I have been using mi-lights with sidoh’s Milight-hub for a few years now.
I recently updated the hub to the latest firmware (1.13.0 on Nodemcuv2).
Since then, I cannot get back to my previous working state - I assumed that a simple backup & restore on the hub would give me like-for-like behaviour, unfortunately not.
However, as I much prefer the new UI, I do want to continue with the updated version of the hub.
So, I am trying to start again from scratch, re-pairing, my mi-light devices, and adding them to OH4 using MQTT homeassistant topics.
Some details
OH v4.3.4 on a RPI5 in docker (I do all config via OH UI)
MQTT binding (v4.3.4)
Eclipse-Mosquitto latest (2.0.21) in docker
Milight hub (link) running latest firmware 1.13
Milight LED controllers:
- LS2 - controlling Cold / Warm white led strips.
- FUT037W - controlling Cold / Warm white led strips.
What I have done so far:
Configured milight hub following these guidelines: link
Added new FUT091 remote in MilightHub UI, and paired it with one of my led controllers (FUT037W).
I can control all aspects of the leds perfectly, On/Off, Dim and Color temperature from MilightHub
- I see these updates in the “sniffer” of the milight hub
In the Milight hub sniffer, I see this:
Device ID:1234
Group ID: 1
Remote Type: fut091
Packet: 00 DC DD D1 63 CD EA 66 12
State:
{
"state": "ON",
"color_mode": "color_temp",
"level": 45,
"kelvin": 51
}
Command:
brightness: 115
- I see these updates in MQTT Explorer under the homeasssitant topic and also under the relevant milight topic.
milight
status = connected
states
0x4D2
fut091
1 = {"state":"ON","level":66,"color_temp":264,"bulb_mode":"white"}
commands
0x4D2
fut091
1 = {"state":"OFF"}
e.g.: If I change the brightness of the bulbs, I see the “level” change above in MQTT Explorer.
Now, over to openhab
Milight-hub is added to the inbox via Homeassistant discovery, containg 3 channels
Color Temperature
Lighting Effect
On/Off State
I then add link to each channel, using “create a new item”
- On/Off State
type Switch
profile Default
This works perfectly, I can control the on/off of my lights, and the openhab switch also reacts to changes via MilightHub. - Color Temperature
Type Number
Dimension Temperature (°C) - Not sure why Openhab thinks this is degrees C, so I change this to none
Unit °C - Ditto
profile Default
This works partially,
if I change the color temperature in MilightHub, I can see the number value in OH change (the range is 153 - 370)
If I change the color temperature via script (Send command 370 to item), I can see it in explorer
commands
0x4D2
fut091
1 = {"state":"ON","color_temp":350}
However, I cannot change this number via the item in the UI, if I try to change the type to “Dimmer”, I get “Communication error” in red at bottom of the screen, but nothing shows in the logs.
Is there a way to change the control to something human usable?
- Lighting effect
I am not interested in this one, this is presets for white light, disco mode etc. - Regarding brightness, I do not have a channel for this
I really want to control the brightness of the leds, why is this channel not created as part of the Homeassistant discovery?
Is there a workaround to add a new channel under the same milight-hub?