Hey guys,
I’m struggling with simple calculations (Math.floor, modulo or Math.round) inside the rules.
I want to switch on my light at certain times. To change the times I use a VariableInputDevice and two variables (one to store the time [e.g. ‘6’] and one “time-string” [e.g. ‘6:00’] which works fine. Every time the value of the InputDevice changes a rule gets executed: $time_string_variable := "{inputDevice_variable}:00"
.
Now I wanted to adjust the time in smaller steps (15 minutes) but I’m having serious problems to split 6.25 into 6 and .25. Maybe I fail to see the obvious solution.
I hope you have some ideas for me to try out
edit: marked code as code