I've read a number of posts on this topic. The rule machine docs make reference to it and I ran across a post with a rule using a Global Variable in RM. I also saw reference to the 'Modes Plus' user-created app which allows for the setting of Mode via Lux, among other things.
I know there will be reasons for looking at this question in different ways. But, for the sake of simplicity, if one wanted to remain within the confines of 'official' HE apps and built-in capabilities, are there better practices?
Im not sure if there's any global best practices in regards to lux, it boils down to what you wish to acomplish with this attribute...
LUX is unlikely to be accurate in our environments.
Lux is a measurement, but in most cases around the home, it's an approximation. Maybe you have a Sensor that has a Lux value and maybe the manufacturer tossed in some calibration at the design step. Individual devices are going to vary.
You go buy a bulb and it displays a Lux value, perhaps. For any specific bulb, it will be a reasonable approximation, but there on the side of the bulb is "dimmable" and now Lux is useless. No two bulb manufacturers dim the same.
Lux is NOT a measurement for Outdoor (sunlight) either. Extrapolations have been made, estimations exist, authoritative sounding numbers are on the Internet.
It's not that the approximations are bad, it's just you can't rely on them to be the same, room to room, house to house, etc. without using a calibrated meter.
Know that Lux as produced by wx-ApiXU-Driver and Luxurient-Driver are calculated values. Not even a hint of reality to them. An equation, that assumes a full sun, outdoor, cloudless noon day, is 10,000 lux. Dead of night = 5 lux. If you know the time of day and hoe much cloud cover there is, a value for lux can be interpolated.
Do you have a device which gives good lux values? My Aeon Multi-sensor 6 only shows between 0 and 10 lux so I've never really been able to setup a rule to use it well.
The Aeon MultiSensor 6 is not limited to 0-10. I have 12 of them and their current readings are consistent with their location. I have one outdoor, facing my front door and in the morning, like now, it's looking at a shadowed area. In the afternoon, it's looking at non-shadowed. Currently it's showing 432 lux.
Indoors, I get values that are consistent, but not accurate:
I also have 4 Dome mulitsensors and they are not better or worse:
I must have gotten a bad one then, it showed the same very low values on SmartThings as well. Thanks.
I have and use a an aeon multi 6, a fibaro and hue motions for lux, all three give accurate readings and are capable of rendering values in excess of 10K lux.
Two of them measure outdoor values, and one measures indoor values on the south side of our home.
The indoor reading is used to close the shades on that side of the house during the day.
The other two are used to modify interior dimmer levels.
In all cases these sensors are actually monitoring the luminosity generated by the sun, not lux generated by interior lighting.
Interior lux readings generated exclusively by interior lighting are too low to be of any practical value.