node-red-contrib-ui-time-scheduler
node-red-contrib-ui-time-scheduler copied to clipboard
Not getting the example for persistant schedules.
Sorry, but I'm thick.
If I have more than 1 schedule (say 2 to keep it simple) and the machine is rebooted/reset/what ever.
The file saved has both schedules and I select which one is active.
Does this recent update (1.16.2) allow you to select which of the 2 schedules is activated?
I saw the news and that it has the ability to reload the schedule after a restart, thinking it meant it also selected the desired schedule also.
Hi @Just-another-pleb,
the recent update only fixed a bug with sun-events. Currently the timer will always start with "Overview" selected (if more than one device was created). What are you trying to accomplish?
Ok, here is a bigger picture of the problem as I see it:
[{"id":"e7b39ace.a09d2","type":"link in","z":"6dd5ca4d.d1958c","name":"Boot signal","links":["6448f189.7ce318"],"x":610,"y":4680,"wires":[["d54212c1.226718"]],"l":true},{"id":"d54212c1.226718","type":"delay","z":"6dd5ca4d.d1958c","name":"","pauseType":"delay","timeout":"1","timeoutUnits":"minutes","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"outputs":1,"x":725,"y":4680,"wires":[["b5a97d4f.84ed58"]],"l":false},{"id":"b5a97d4f.84ed58","type":"function","z":"6dd5ca4d.d1958c","name":"build message","func":"var path = global.get(\"event_paths\");\nmsg.filename = path + \"plants.txt\";\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":880,"y":4680,"wires":[["82e4dfc5.1ba768"]]},{"id":"82e4dfc5.1ba768","type":"file in","z":"6dd5ca4d.d1958c","name":"Plants","filename":"","format":"utf8","chunk":false,"sendError":false,"encoding":"none","x":850,"y":4730,"wires":[["46e58700.dc6b38"]]},{"id":"46e58700.dc6b38","type":"ui_time_scheduler","z":"6dd5ca4d.d1958c","group":"c0eea23d.14fd5","name":"Plants","refresh":"60","devices":["Daily","Away"],"customPayload":false,"eventMode":false,"outputs":3,"order":11,"width":"6","height":"1","x":1040,"y":4730,"wires":[["39958344.67685c"],["4e17f8ac.78c5c8","8a49b79e.e2e9d"],["4e17f8ac.78c5c8","c133b660.f9987"]]},{"id":"c0eea23d.14fd5","type":"ui_group","name":"Automatic plant watering","tab":"e92ac76d.c24e7","order":12,"disp":true,"width":"6","collapse":false},{"id":"e92ac76d.c24e7","type":"ui_tab","name":"Real_World_Control","icon":"dashboard","order":14,"disabled":false,"hidden":false}]
and this is the file:
{"timers":[{"starttime":1606528500000,"days":[1,1,1,1,1,1,1],"output":"0","endtime":1606529100000},{"starttime":1616723700000,"days":[0,0,1,0,1,0,1],"output":"1","endtime":1616724300000}]}
I want 'Daily' selected on reboot.
Otherwise nothing is active.