node-red-trigger-atleast-every-x
v1.1.0
Published
Send On and Off and if long time no On then send On and then Off. Now proper closing.
Downloads
34
Maintainers
Readme
node-red-contrib-trigger-atleast-every-x
node-red-trigger-atleast-every-x is used to watch the payload coming in. Usually used with an ON or OFF payloads. When ON is received, the unit resets and sends an ON. If it's reset and OFF is received, an OFF is send and then the node makes sure that after x seconds an ON is send, unless reset. Incoming OFF payloads are ignored in the mean time. If the unit has send an ON because of the timer, after y seconds, an OFF is send and the unit is reset to send an On.
Install
Run the following command in the root directory of your Node-RED install. Usually this is ~/.node-red
npm install node-red-contrib-trigger-atleast-every-x
Using
This node sends an On payload when an On is received and an off when an Odd payload is received. So, it's a piece of wire. Well, no. When the last send payload is an Off payload, then a timer is started. If that timer runs down, an On payload is send and another timer is started after which an Off is send. When in "timer" mode, then off payloads are ignored. But an On when in timer mode resets all (and sends an On). So it filters messages witrh the same payload in sequence and has a timer mode to make sure On's are send, even in Off mode.
This is useful in an Under Floor Heating system. The pump of an UFH divider unit needs to be run every week or 10 days for somewhere around 5 minutes, to keep it in operation condition. On a related note, if you'd control the pump, for instance with an Tasmota-ted Sonoff Basic, then make sure it's turning on or off is delayed some 2 minutes, so the valves / thermal actuators on the UFH unit are either 1/3 open or 2/3 closed. If the pump runs and all UFH loops are closed, either you'lll heard it, or you'll run the risk of damaging the unit. Best way to avoid this is have a (!) loop per UFH unit some 1/4 or 1/3 open all the time. It heats up if something else heats up, so an bathroom or a hal, something in the middle of the house, but not often visited, os a good candidate.