Wrong Luminance Value

A UoM value includes the unit, which for this is %. There are a few ways to strip this. I use uomItem.state.toBigDecimal() with jsr223-Jython.

Here is some more info for UoM in rules…

You can also do arithmetic with QuantityTypes…

uomItem1.state.add(uomItem2.state)
uomItem1.state.add(5 | °F)
uomItem1.state.subtract(uomItem2.state)
uomItem1.state.multiply(5)
uomItem1.state.mutiply(uomItem2.state)
uomItem1.state.divide(5)
uomItem1.state.divide(uomItem2.state)

There are some other useful methods for QuantityType.