Alarm example
-
-
Save infosmick/2b037c5c0839456c96c7813761bfe9db to your computer and use it in GitHub Desktop.
Smick_05_alarm
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"id": "9a91c110.77f7c", | |
"type": "tab", | |
"label": "alarm" | |
}, | |
{ | |
"id": "482e9040.a9f8d", | |
"type": "comment", | |
"z": "9a91c110.77f7c", | |
"name": "actions on social: connect here --> ", | |
"info": "", | |
"x": 260, | |
"y": 280, | |
"wires": [] | |
}, | |
{ | |
"id": "7cad7d96.3a8054", | |
"type": "function", | |
"z": "9a91c110.77f7c", | |
"name": "alarm msg", | |
"func": "function timeDate(tz) {\n var d = new Date(Date.now()+tz*3600000);\n\n return d.getUTCHours() + \":\" +\n format00(d.getUTCMinutes()) + \":\" +\n format00(d.getUTCSeconds()) + \" \" +\n d.getUTCDate()\t+\"/\" +\n (d.getUTCMonth()+1) + \"/\" +\n d.getUTCFullYear();\n}\n\nfunction format00(n) {return n<10?\"0\"+n:n;}\n\nmsg.payload+=\" alarm at \" + timeDate(1);\nmsg.topic=\"\";\nreturn msg;", | |
"outputs": 1, | |
"noerr": 0, | |
"x": 324, | |
"y": 200, | |
"wires": [ | |
[ | |
"14723a39.e0ae46", | |
"f0f35773.02c258" | |
] | |
] | |
}, | |
{ | |
"id": "14723a39.e0ae46", | |
"type": "debug", | |
"z": "9a91c110.77f7c", | |
"name": "alarm", | |
"active": true, | |
"console": "false", | |
"complete": "payload", | |
"x": 544, | |
"y": 140, | |
"wires": [] | |
}, | |
{ | |
"id": "61ffee35.3803f", | |
"type": "e-mail", | |
"z": "9a91c110.77f7c", | |
"server": "smtp.gmail.com", | |
"port": "465", | |
"name": "infosmick@gmail.com", | |
"dname": "mail", | |
"x": 544, | |
"y": 260, | |
"wires": [] | |
}, | |
{ | |
"id": "b0ffd0cb.8b316", | |
"type": "twitter out", | |
"z": "9a91c110.77f7c", | |
"twitter": "", | |
"name": "tweet", | |
"x": 544, | |
"y": 320, | |
"wires": [] | |
}, | |
{ | |
"id": "f9dd7f46.64f3", | |
"type": "comment", | |
"z": "9a91c110.77f7c", | |
"name": "Description", | |
"info": "Smick_05_alarm\n_______________________________________________________________________________\nPackage : Smick v.1\nModule : alarm\nAuthor : Curci\nLicence : (CC) BY-NC-SA\n\nThis work is licensed under a Creative Commons \nAttribution-NonCommercial-ShareAlike \n4.0 International License.\n\nHistory\n\nDate Author Description\n2016.12.26 Curci genesis\n_______________________________________________________________________________\n\nDescription\n\ntodo\n\n_______________________________________________________________________________\n\nBill Of Material\n\nHardware:\n\n 1 Human internet terminal (PC, tablet or smartphone) connected to the internet\n 1 Smick Wi-Fi connected to the internet\n\nHW Connections:\n\n None.\n\nFlow Connections:\n\n console\n\nAccount:\n\n Wi-Fi router\n MQTT broker\n FRED\n", | |
"x": 160, | |
"y": 60, | |
"wires": [] | |
}, | |
{ | |
"id": "5487d125.734a9", | |
"type": "link in", | |
"z": "9a91c110.77f7c", | |
"name": "alarm", | |
"links": [ | |
"1166fb27.3795a5", | |
"b9fd2ce1.0ec86" | |
], | |
"x": 149, | |
"y": 200, | |
"wires": [ | |
[ | |
"7cad7d96.3a8054" | |
] | |
] | |
}, | |
{ | |
"id": "f0f35773.02c258", | |
"type": "ui_toast", | |
"z": "9a91c110.77f7c", | |
"position": "top right", | |
"displayTime": "3", | |
"name": "", | |
"x": 584, | |
"y": 200, | |
"wires": [] | |
} | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment