I’ve been using Codersaur’s Fibaro Dimmer 2 DTH for some time but it appears to not function correctly with new Fibaro DImmer’s that have been added since the classic app was retired (Codersaur’s DTH was written for Classic). So I’ve been trying to adapt the current stock DTH provided by ST to add in the couple of features missing that I want; force brightness level and night mode.
I’ve got force brightness working fine but I’m having no end of issues getting a version of night mode to work. From what I can see, Codersaur’s version simply created some new attributes to store start and end date in along with target brightness and then basically just changed parameter 19 as the switch was clicked to set the desired brightness. It used states to store information such as previous brightness level and whether nightmare was active or not. The whole lot was run locally on the device using schedules which I really liked.
No matter what I do I cannot seem to get a schedule to work using schedule(). Nothing I add to the schedule using schedule() or even runIn() seems to execute. Do these functions even still work in ST? The documentation I’ve found on them is clearly for the Classic app but I’ve been struggling to find anything more up-to-date on it.
Alternatively, can anyone think of some other way that doesn’t turn the light on to set the brightness, or doesn’t incur any kind of lag while cloud scripts are run when the switch is clicked? I’d happily use a Webcore Piston to set parameter 19 between certain hours if the light didn’t turn on by doing so! would scenes be a possibility?
Thanks in advance