[RELEASE] Xiaomi Mijia Smart Light Sensor (DTH Updated Aug 07, 2020, see post 77)

Hi guys I’m just now catching up on posts.

Thanks for the feedback @alexpana00 , and thanks for the follow up @jlv .

I did lux values based upon the code I saw from other DTH’s that ST were doing. I didn’t want to recreate the wheel, and I wanted to stay consistent with them on capabilities.

1 Like

Just to note: the output of bulbs is measured in lumens. lux is how much light falls on a surface. The relationship is 1 lux = 1 lumen/m².

Yep… that sums it up! clear now!

Just bought two of these Mijia light sensors, and they are working great with your DTH. Awesome work and a big THANK-YOU.

They only issue I have (and it’s an esthetic one) is that the lux numerical value and the unit abbreviation “lx” has no space between it on the dashboard view. Could you update the presentation to have a space for the value of “{{illuminance.value}} {{illuminance.unit}}” ?

Thanks for the feedback @rtorch . I didn’t do anything with the presentation other than what was out of the box capabilities for luminance and to force the dashboard state, but I can work on that over the next few days. I should probably remove the dashboard action as well since that does nothing.


Did anybody already try to port DTH to the new platform? Frankly speaking, I don’t fully understand how that is possible and if that is possible at this moment. I see there is an API method to generate a configuration from DTH ( API | SmartThings Developers). Apparently after that an “active” part producing events need to be added somehow.

Sooner or later Groovy DTH platform will be discontinued and I’d like to know if that is even going to be possible to make the device work on the new platform.

Have you tried the generic edge driver for ZigBee illuminance? I haven’t, only because it seems SmartThings WiFi doesn’t support edge yet.

Not yet, but I’m curious and may have to experiment.

Bought this light sensor and it works perfectly with no issues so huge thanks for Johnconstantelo for the device handler

1 Like