Try cron plus
I will try it thank you very much my friend.
node-red-contrib-timeprop can do that for you.
Assuming you want it to keep repeating that.
Dear @Colin I loaded timepromp node. And setting up like in photo but always send 0 , where did I mistake ?
Dear friend my nodered version is old and didnt install cron plus node.I will try to upgrade nodered
What version of node & node-red are you running?
Also, what os?
Im using raspian, downloaded from official site in 2019
Yes, very old. You didnt state what nodejs version but it is likely V6 or V8 (out of support by several years)
I recommend you update your OS first THEN run the official Raspberry Pi node-red install script (Running on Raspberry Pi : Node-RED ) to get the latest version (v2.2.2). Also, you will need to append --node14
or --node16
to the script command to upgrade nodejs at the same time.
What payload have you passed into it?
Just this one
[{"id":"5bc4fcf5.332164","type":"subflow","name":"Subflow 1","info":"","category":"","in":[{"x":60,"y":80,"wires":[{"id":"2c29ca9d.1f3726"}]}],"out":[{"x":920,"y":100,"wires":[{"id":"26fe58d.da0d2a8","port":0}]},{"x":540,"y":120,"wires":[{"id":"c3cccc67.eba87","port":0}]}]},{"id":"2c29ca9d.1f3726","type":"function","z":"5bc4fcf5.332164","name":"","func":"\nreturn msg;","outputs":1,"noerr":0,"x":200,"y":80,"wires":[["c3cccc67.eba87","dc32c467.fb1168"]]},{"id":"dc32c467.fb1168","type":"switch","z":"5bc4fcf5.332164","name":"allow only 1 ","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"num"},{"t":"else"}],"checkall":"true","repair":false,"outputs":2,"x":390,"y":80,"wires":[["90e7351e.a17e68"],["54e68c10.45d2f4"]]},{"id":"c3cccc67.eba87","type":"trigger","z":"5bc4fcf5.332164","op1":"","op2":"Kapı 30 saniyedir açık!!","op1type":"nul","op2type":"str","duration":"30","extend":false,"units":"s","reset":"1","bytopic":"all","name":"","x":390,"y":120,"wires":[[]]},{"id":"90e7351e.a17e68","type":"change","z":"5bc4fcf5.332164","name":"High","rules":[{"t":"set","p":"bc","pt":"msg","to":"orange","tot":"str"},{"t":"set","p":"status","pt":"msg","to":"Kapalı","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":590,"y":80,"wires":[["26fe58d.da0d2a8"]]},{"id":"54e68c10.45d2f4","type":"change","z":"5bc4fcf5.332164","name":"Low","rules":[{"t":"set","p":"bc","pt":"msg","to":"purple","tot":"str"},{"t":"set","p":"status","pt":"msg","to":"Açık","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":590,"y":120,"wires":[["26fe58d.da0d2a8"]]},{"id":"26fe58d.da0d2a8","type":"function","z":"5bc4fcf5.332164","name":"","func":"\nreturn msg;","outputs":1,"noerr":0,"x":780,"y":100,"wires":[[]]},{"id":"6baf2c69.df7614","type":"ui_button","z":"2662f642.77ca6a","name":"","group":"f3de209f.b746","order":2,"width":"3","height":"1","passthru":false,"label":"B5 Kapı - 2 {{msg.status}}","color":"","bgcolor":"{{bc}}","icon":"","payload":"1","payloadType":"num","topic":"topic","x":890,"y":200,"wires":[[]]},{"id":"9e0a0911.330898","type":"dsm","z":"2662f642.77ca6a","name":"sensör_durumu","sm_config":"{\n \"triggerInput\": \"payload\",\n \"currentState\": \"running\",\n \"states\": {\n \"stopped\": {\n \"0\": \"running\"\n },\n \"running\": {\n \"1\": \"stopped\"\n }\n },\n \"methods\": {\n \"onBeforeTransition\": \"msg.pyload = msg.payload.toString();\",\n \"1\": \"sta.fill='green';msg.background='red';msg.label='S';\",\n \"0\": \"sta.fill='red';msg.background='green';msg.label='S';\"\n }\n}","x":690,"y":260,"wires":[["ce90a676.9d6348"]]},{"id":"ce90a676.9d6348","type":"template","z":"2662f642.77ca6a","name":"","field":"topic","fieldType":"msg","format":"handlebars","syntax":"mustache","template":"INSERT INTO 'sensor_durumu' ('durum','epoc') VALUES ({{payload}},{{pyload}});","output":"str","x":880,"y":280,"wires":[[]]},{"id":"e450a569.aff438","type":"subflow:5bc4fcf5.332164","z":"2662f642.77ca6a","name":"Pin Status Monitoring","x":680,"y":220,"wires":[["6baf2c69.df7614"],["46b448d9.a208e8"]]},{"id":"46b448d9.a208e8","type":"ui_toast","z":"2662f642.77ca6a","position":"dialog","displayTime":"","highlight":"","outputs":1,"ok":"OK","cancel":"","topic":"Uyarı","name":"","x":890,"y":240,"wires":[[]]},{"id":"9ea12769.439998","type":"timeprop","z":"2662f642.77ca6a","name":"","cycleTime":600,"deadTime":"0","triggerPeriod":"10","invert":false,"x":360,"y":240,"wires":[["e450a569.aff438","9e0a0911.330898","1da1f3b6.4c415c"]]},{"id":"1da1f3b6.4c415c","type":"debug","z":"2662f642.77ca6a","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","x":610,"y":120,"wires":[]},{"id":"f3de209f.b746","type":"ui_group","z":"","name":"Finish","tab":"6f5ce300.48f7bc","disp":true,"width":"3","collapse":false},{"id":"6f5ce300.48f7bc","type":"ui_tab","z":"","name":"Mercedes-Benz Türk AŞ Kamyon Fabrikası Hol Kapıları","icon":"dashboard","order":1}]
Actually I installled new version of raspian and also nodered but, after I install to sqlite and phplite admin then phpliteadmin always gives an error. many options I tried but didnt success it.
I have preoblem phpliteadmin with new installation.
This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.