| <a href="http://eepurl.com/gJm095" target="_blank">Subscribe to my channel.</a> Only news about my nodes, no spam, no ads. I'm a github developer, not a merchant. | <a href="http://eepurl.com/gJm095" target="_blank">Subscribe to my channel.</a> Only news about my nodes, no spam, no ads. I'm a github developer, not a merchant. | ||||
| <p> | <p> | ||||
| <b>Version 1.0.13</b><br/> | |||||
| <b>Version 1.0.14</b><br/> | |||||
| - NEW: added blinker node. Thanks to @Marco for the suggestion.</br> | - NEW: added blinker node. Thanks to @Marco for the suggestion.</br> | ||||
| </p> | </p> | ||||
| <p> | <p> |
| The pourpose of this node is to blink a led or something.<br /> | The pourpose of this node is to blink a led or something.<br /> | ||||
| Pass <code>msg.payload = true</code> to start blinking</br> | Pass <code>msg.payload = true</code> to start blinking</br> | ||||
| Pass <code>msg.payload = false</code> to stop blinking</br> | Pass <code>msg.payload = false</code> to stop blinking</br> | ||||
| Pass <code>msg.interval = 2000</code> to change the blinking interval</br> | |||||
| <img src='https://raw.githubusercontent.com/Supergiovane/node-red-contrib-boolean-logic-ultimate/master/img/blinker.png' width='60%'> | <img src='https://raw.githubusercontent.com/Supergiovane/node-red-contrib-boolean-logic-ultimate/master/img/blinker.png' width='60%'> | ||||
| <p>The meaning of this node is to blink a light or something else.<br/> | <p>The meaning of this node is to blink a light or something else.<br/> | ||||
| <p>Pass msg.payload = true to start blinking</br> | <p>Pass msg.payload = true to start blinking</br> | ||||
| Pass msg.payload = false to stop blinking</br> | Pass msg.payload = false to stop blinking</br> | ||||
| Pass msg.interval = 2000 to change the blinking interval</br> | |||||
| </p> | </p> | ||||
| <a href="https://www.paypal.me/techtoday" target="_blank"><img src='https://img.shields.io/badge/Donate-PayPal-blue.svg?style=flat-square' width='30%'></a> | <a href="https://www.paypal.me/techtoday" target="_blank"><img src='https://img.shields.io/badge/Donate-PayPal-blue.svg?style=flat-square' width='30%'></a> | ||||
| if (node.tBlinker !== null) clearInterval(node.tBlinker); | if (node.tBlinker !== null) clearInterval(node.tBlinker); | ||||
| setNodeStatus({ fill: "red", shape: "dot", text: "|| Off" }); | setNodeStatus({ fill: "red", shape: "dot", text: "|| Off" }); | ||||
| node.send({ payload: false }); | node.send({ payload: false }); | ||||
| node.curPayload = false; | |||||
| } | } | ||||
| } | } | ||||
| if (msg.hasOwnProperty("interval")) { | |||||
| try { | |||||
| node.blinkfrequency = msg.interval; | |||||
| } catch (error) { | |||||
| node.blinkfrequency = 500; | |||||
| setNodeStatus({ fill: "red", shape: "dot", text: "Invalid interval received" }); | |||||
| } | |||||
| } | |||||
| }); | }); | ||||
| { | { | ||||
| "name": "node-red-contrib-boolean-logic-ultimate", | "name": "node-red-contrib-boolean-logic-ultimate", | ||||
| "version": "1.0.13", | |||||
| "version": "1.0.14", | |||||
| "description": "A set of Node-RED enhanced boolean logic, with persisten values after reboot and more", | "description": "A set of Node-RED enhanced boolean logic, with persisten values after reboot and more", | ||||
| "author": "Supergiovane (https://github.com/Supergiovane)", | "author": "Supergiovane (https://github.com/Supergiovane)", | ||||
| "dependencies": { | "dependencies": { |