20.03.2019, 08:04
Calculate the reverse color temp like this:
Keep in mind that there might be a difference between set and status values due to precision loss during when converting between Mireks and Kelvins.
Code:
colortemp = math.floor(1000000 / item.state.ct)
Keep in mind that there might be a difference between set and status values due to precision loss during when converting between Mireks and Kelvins.