Hi.
I tried to set override for delay. When I have msg.payload = true ( without delay ), for msg.payload = false ( defined delay ). Off delay works without problem, but for on delay I have at beginning flip-flop signal true/false, after few seconds expected true signal.
[{"id":"4a84373a.f8db8","type":"debug","z":"9fcddc0a.9d9f9","name":"","active":false,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","x":790,"y":100,"wires":[]},{"id":"b07eec1d.33693","type":"function","z":"9fcddc0a.9d9f9","name":"Delay","func":"state = String(msg.payload);\nvar delay\n\nif ( state == \"true\" )\n {\n delay = 100;\n msg.delay = delay;\n }\n\nelse if ( state == \"false\" )\n {\n delay = 20000;\n msg.delay = delay;\n }\n\nreturn msg;","outputs":1,"noerr":0,"x":430,"y":100,"wires":[["6f3c03c4.b69114"]],"outputLabels":["cmd"]},{"id":"6f3c03c4.b69114","type":"delay","z":"9fcddc0a.9d9f9","name":"","pauseType":"delayv","timeout":"1","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":true,"x":620,"y":100,"wires":[["4a84373a.f8db8"]]},{"id":"3dc3447d.20792c","type":"ui_switch","z":"9fcddc0a.9d9f9","name":"","label":"switch","group":"8c41b690.380cb8","order":0,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","x":270,"y":100,"wires":[["b07eec1d.33693"]]},{"id":"e58c5d67.44dd3","type":"inject","z":"9fcddc0a.9d9f9","name":"","topic":"","payload":"","payloadType":"date","repeat":"2","crontab":"","once":true,"onceDelay":0.1,"x":110,"y":100,"wires":[["3dc3447d.20792c"]]},{"id":"8c41b690.380cb8","type":"ui_group","z":"","name":"Timer","tab":"aefaddb2.7073a8","order":1,"disp":true,"width":"6","collapse":false},{"id":"aefaddb2.7073a8","type":"ui_tab","z":"","name":"Test","icon":"dashboard","order":2}]