node-red-contrib-looptimer-advanced 0.0.5 → 0.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -49,9 +49,11 @@ You can define maximum number of loops with `msg.loop.maxloops`
49
49
 
50
50
 
51
51
  Setting the Max Loops and Max Timeout settings to high values can, for all intents, ensure that the loop can only be stopped by an incoming `stop` payload, however, the stability of the loop has not been tested over an extended number of hours.
52
-
53
52
 
54
53
 
54
+
55
+ **0.0.7** - Update Loop Dependency version as older version is not compatible with higher version Node.JS
56
+ **0.0.6** - Added Example Flow and updated dependencies
55
57
  **0.0.5** - Re-added line removed accidentally
56
58
  **0.0.4** - Issue #4 -> Added message when timeout reached
57
59
  **0.0.1** - Initial Release
@@ -62,6 +64,6 @@ Setting the Max Loops and Max Timeout settings to high values can, for all inten
62
64
 
63
65
 
64
66
  **To Do:**
65
-
67
+
66
68
  - [ ] Mustache Template Support
67
- - [ ] Example Flows
69
+ - [x] Example Flows
@@ -0,0 +1,323 @@
1
+ [
2
+ {
3
+ "id": "8eb4d9d.d1c3528",
4
+ "type": "tab",
5
+ "label": "Looptimer Example Flows",
6
+ "disabled": false,
7
+ "info": ""
8
+ },
9
+ {
10
+ "id": "3acf3795.a4aff8",
11
+ "type": "looptimer-advanced",
12
+ "z": "8eb4d9d.d1c3528",
13
+ "duration": "1",
14
+ "units": "Second",
15
+ "maxloops": "10",
16
+ "maxtimeout": "10",
17
+ "maxtimeoutunits": "Hour",
18
+ "name": "Loop every second, 10 times max, 10 hours timeout",
19
+ "x": 750,
20
+ "y": 320,
21
+ "wires": [["ab782534.38ffd8"], ["ab782534.38ffd8"]]
22
+ },
23
+ {
24
+ "id": "ab782534.38ffd8",
25
+ "type": "debug",
26
+ "z": "8eb4d9d.d1c3528",
27
+ "name": "",
28
+ "active": true,
29
+ "tosidebar": true,
30
+ "console": false,
31
+ "tostatus": false,
32
+ "complete": "true",
33
+ "targetType": "full",
34
+ "statusVal": "",
35
+ "statusType": "auto",
36
+ "x": 1350,
37
+ "y": 400,
38
+ "wires": []
39
+ },
40
+ {
41
+ "id": "d6e5e6d3.320558",
42
+ "type": "inject",
43
+ "z": "8eb4d9d.d1c3528",
44
+ "name": "",
45
+ "props": [
46
+ {
47
+ "p": "payload"
48
+ },
49
+ {
50
+ "p": "topic",
51
+ "vt": "str"
52
+ }
53
+ ],
54
+ "repeat": "",
55
+ "crontab": "",
56
+ "once": false,
57
+ "onceDelay": 0.1,
58
+ "topic": "",
59
+ "payload": "stop",
60
+ "payloadType": "str",
61
+ "x": 210,
62
+ "y": 340,
63
+ "wires": [["3acf3795.a4aff8"]]
64
+ },
65
+ {
66
+ "id": "31b03ef0.71ba92",
67
+ "type": "inject",
68
+ "z": "8eb4d9d.d1c3528",
69
+ "name": "",
70
+ "props": [
71
+ {
72
+ "p": "payload"
73
+ },
74
+ {
75
+ "p": "topic",
76
+ "vt": "str"
77
+ }
78
+ ],
79
+ "repeat": "",
80
+ "crontab": "",
81
+ "once": false,
82
+ "onceDelay": 0.1,
83
+ "topic": "",
84
+ "payload": "STOP",
85
+ "payloadType": "str",
86
+ "x": 210,
87
+ "y": 300,
88
+ "wires": [["3acf3795.a4aff8"]]
89
+ },
90
+ {
91
+ "id": "96cc2144.e0013",
92
+ "type": "inject",
93
+ "z": "8eb4d9d.d1c3528",
94
+ "name": "Start",
95
+ "props": [
96
+ {
97
+ "p": "payload"
98
+ },
99
+ {
100
+ "p": "topic",
101
+ "vt": "str"
102
+ }
103
+ ],
104
+ "repeat": "",
105
+ "crontab": "",
106
+ "once": false,
107
+ "onceDelay": 0.1,
108
+ "topic": "",
109
+ "payload": "Test",
110
+ "payloadType": "str",
111
+ "x": 210,
112
+ "y": 260,
113
+ "wires": [["3acf3795.a4aff8"]]
114
+ },
115
+ {
116
+ "id": "2c547dc704ab931a",
117
+ "type": "looptimer-advanced",
118
+ "z": "8eb4d9d.d1c3528",
119
+ "duration": "1",
120
+ "units": "Second",
121
+ "maxloops": "5",
122
+ "maxtimeout": "10",
123
+ "maxtimeoutunits": "Second",
124
+ "name": "Loop every second, 9999999 times max 10 sec timeout",
125
+ "x": 760,
126
+ "y": 480,
127
+ "wires": [["ab782534.38ffd8"], ["ab782534.38ffd8"]]
128
+ },
129
+ {
130
+ "id": "f3cdcd5180fee968",
131
+ "type": "looptimer-advanced",
132
+ "z": "8eb4d9d.d1c3528",
133
+ "duration": "1",
134
+ "units": "Second",
135
+ "maxloops": "100",
136
+ "maxtimeout": "10",
137
+ "maxtimeoutunits": "Hour",
138
+ "name": "Loop properties overwritten [100 max loop 10 hours timeout by default]",
139
+ "x": 810,
140
+ "y": 620,
141
+ "wires": [["ab782534.38ffd8"], ["ab782534.38ffd8"]]
142
+ },
143
+ {
144
+ "id": "f7ca9015f3d57831",
145
+ "type": "inject",
146
+ "z": "8eb4d9d.d1c3528",
147
+ "name": "",
148
+ "props": [
149
+ {
150
+ "p": "payload"
151
+ },
152
+ {
153
+ "p": "topic",
154
+ "vt": "str"
155
+ }
156
+ ],
157
+ "repeat": "",
158
+ "crontab": "",
159
+ "once": false,
160
+ "onceDelay": 0.1,
161
+ "topic": "",
162
+ "payload": "stop",
163
+ "payloadType": "str",
164
+ "x": 210,
165
+ "y": 520,
166
+ "wires": [["2c547dc704ab931a"]]
167
+ },
168
+ {
169
+ "id": "6c2a777d38da5c41",
170
+ "type": "inject",
171
+ "z": "8eb4d9d.d1c3528",
172
+ "name": "",
173
+ "props": [
174
+ {
175
+ "p": "payload"
176
+ },
177
+ {
178
+ "p": "topic",
179
+ "vt": "str"
180
+ }
181
+ ],
182
+ "repeat": "",
183
+ "crontab": "",
184
+ "once": false,
185
+ "onceDelay": 0.1,
186
+ "topic": "",
187
+ "payload": "STOP",
188
+ "payloadType": "str",
189
+ "x": 210,
190
+ "y": 480,
191
+ "wires": [["2c547dc704ab931a"]]
192
+ },
193
+ {
194
+ "id": "bffb05b96d6cc706",
195
+ "type": "inject",
196
+ "z": "8eb4d9d.d1c3528",
197
+ "name": "Start",
198
+ "props": [
199
+ {
200
+ "p": "payload"
201
+ },
202
+ {
203
+ "p": "topic",
204
+ "vt": "str"
205
+ }
206
+ ],
207
+ "repeat": "",
208
+ "crontab": "",
209
+ "once": false,
210
+ "onceDelay": 0.1,
211
+ "topic": "",
212
+ "payload": "Test",
213
+ "payloadType": "str",
214
+ "x": 210,
215
+ "y": 440,
216
+ "wires": [["2c547dc704ab931a"]]
217
+ },
218
+ {
219
+ "id": "aa0c1129383c9b9a",
220
+ "type": "inject",
221
+ "z": "8eb4d9d.d1c3528",
222
+ "name": "",
223
+ "props": [
224
+ {
225
+ "p": "payload"
226
+ },
227
+ {
228
+ "p": "topic",
229
+ "vt": "str"
230
+ }
231
+ ],
232
+ "repeat": "",
233
+ "crontab": "",
234
+ "once": false,
235
+ "onceDelay": 0.1,
236
+ "topic": "",
237
+ "payload": "stop",
238
+ "payloadType": "str",
239
+ "x": 390,
240
+ "y": 740,
241
+ "wires": [["f3cdcd5180fee968"]]
242
+ },
243
+ {
244
+ "id": "54c5d386c3ce186b",
245
+ "type": "inject",
246
+ "z": "8eb4d9d.d1c3528",
247
+ "name": "",
248
+ "props": [
249
+ {
250
+ "p": "payload"
251
+ },
252
+ {
253
+ "p": "topic",
254
+ "vt": "str"
255
+ }
256
+ ],
257
+ "repeat": "",
258
+ "crontab": "",
259
+ "once": false,
260
+ "onceDelay": 0.1,
261
+ "topic": "",
262
+ "payload": "STOP",
263
+ "payloadType": "str",
264
+ "x": 390,
265
+ "y": 700,
266
+ "wires": [["f3cdcd5180fee968"]]
267
+ },
268
+ {
269
+ "id": "a713da09b92a38ac",
270
+ "type": "inject",
271
+ "z": "8eb4d9d.d1c3528",
272
+ "name": "Start",
273
+ "props": [
274
+ {
275
+ "p": "payload"
276
+ },
277
+ {
278
+ "p": "topic",
279
+ "vt": "str"
280
+ }
281
+ ],
282
+ "repeat": "",
283
+ "crontab": "",
284
+ "once": false,
285
+ "onceDelay": 0.1,
286
+ "topic": "",
287
+ "payload": "Test",
288
+ "payloadType": "str",
289
+ "x": 210,
290
+ "y": 600,
291
+ "wires": [["93e07e9c2af62b2b"]]
292
+ },
293
+ {
294
+ "id": "93e07e9c2af62b2b",
295
+ "type": "change",
296
+ "z": "8eb4d9d.d1c3528",
297
+ "name": "Change Properties",
298
+ "rules": [
299
+ {
300
+ "t": "set",
301
+ "p": "loop.duration",
302
+ "pt": "msg",
303
+ "to": "10",
304
+ "tot": "num"
305
+ },
306
+ {
307
+ "t": "set",
308
+ "p": "msg.loop.units",
309
+ "pt": "msg",
310
+ "to": "Millisecond",
311
+ "tot": "str"
312
+ }
313
+ ],
314
+ "action": "",
315
+ "property": "",
316
+ "from": "",
317
+ "to": "",
318
+ "reg": false,
319
+ "x": 410,
320
+ "y": 600,
321
+ "wires": [["f3cdcd5180fee968"]]
322
+ }
323
+ ]
package/package.json CHANGED
@@ -1,26 +1,31 @@
1
1
  {
2
2
  "name": "node-red-contrib-looptimer-advanced",
3
- "version": "0.0.5",
3
+ "version": "0.0.7",
4
4
  "description": "Sends the msg through the first output, then continues to do so in a loop, once per the duration specified, until a payload of 'stop' or 'STOP' is received. Supports override with messages!",
5
5
  "main": "looptimer_advanced.js",
6
6
  "scripts": {},
7
7
  "dependencies": {
8
- "loop": "2.1.2"
8
+ "loop": "^3.3.6"
9
9
  },
10
10
  "directories": {},
11
11
  "keywords": [
12
12
  "node-red",
13
13
  "loop",
14
14
  "timer",
15
- "advanced"
15
+ "advanced",
16
+ "looptimer"
16
17
  ],
17
18
  "author": "Haxiboy",
18
19
  "license": "Apache-2.0",
19
20
  "node-red": {
21
+ "version": ">=1.0.0",
20
22
  "nodes": {
21
23
  "looptimer-advanced": "looptimer_advanced.js"
22
24
  }
23
25
  },
26
+ "engines": {
27
+ "node": ">=6.0.0"
28
+ },
24
29
  "repository": {
25
30
  "type": "git",
26
31
  "url": "git+https://github.com/Haxiboy/node-red-contrib-looptimer-advanced.git"