Hi,
I am testing a simple rule which triggers based on time-of-day where the trigger setting is derived from a slider in the sitemap. the JS numbertoclock transformation is just to display the setpoint value correctly.
Items
Number TimerOn
Sitemap
Setpoint item=TimerOn label=“TimerOn [JS(numberToClock.js):%s]” minValue=0 maxValue=1440 step=15
Rules
rule “Alarm”
when
//run every minute
Time cron “0 * * ? * *”
then
var int Var_TimerOn = TimerOn.state
if (now.getMinuteOfDay > Var_TimerOn ) {
//Alarm triggered so do something
postUpdate(Alarm, ON )
}
end
Error message:
2019-09-06 09:50:00.254 [ERROR] [ntime.internal.engine.ExecuteRuleJob] - Error during the execution of rule ‘Alarm’: An error occurred during the script execution: Could not invoke method: org.eclipse.xtext.xbase.lib.IntegerExtensions.operator_greaterThan(int,int) on instance: null