Hi,
I’m trying to assign 3 x RGB Values (GA KNX Binding Type 5.001) to HSB in order to control a LED Strip. For testing only I’ve created a test-button to start the rule.
It works fine with absolute values for rValue,gValue,bValue e.g. 255,120,50
KNX Items
Number rValue { channel=“knx:device:bridge:generic:ga_rValue” }
Number gValue { channel=“knx:device:bridge:generic:ga_gValue” }
Number bValue { channel=“knx:device:bridge:generic:ga_bValue” }
rule “Test”
when
Item Test changed
then
var Number red=rValue
var Number green=gValue
var Number blue=bValue
var HSBType hsb = HSBType::fromRGB(red, green, blue)
sendCommand(highboard_color, hsb)
end
Any help?
Thanks!
[ERROR] [ntime.internal.engine.RuleEngineImpl] - Rule ‘Test’: An error occurred during the script execution: Could not invoke method: org.eclipse.smarthome.core.library.types.HSBType.fromRGB(int,int,int) on instance: null