node-red-contrib-knx-ultimate 2.2.3 → 2.2.5

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/CHANGELOG.md CHANGED
@@ -6,6 +6,12 @@
6
6
 
7
7
  # CHANGELOG
8
8
 
9
+ <b>Version 2.2.5</b> - October 2023<br/>
10
+ - Fix: fixed some HUE nodes not able to register to the event notification service.<br/>
11
+ </p>
12
+ <b>Version 2.2.4</b> - October 2023<br/>
13
+ - HUE Light: fixed some status hiccups and better handling of async hue bridge functions.<br/>
14
+ </p>
9
15
  <b>Version 2.2.3</b> - October 2023<br/>
10
16
  - HUE Light: Again, rewrite of the DIM function to get rid of the dimming_delta.<br/>
11
17
  </p>
@@ -762,7 +768,7 @@
762
768
  </p>
763
769
  <p>
764
770
  <b>Version 1.2.33</b> - May 2021<br/>
765
- - Gateway configuration -> Advanced Options -> Node list in all flows: added more infos to each node in the list, to allow more control on the nodes overview. The options are: "No Initial Read, React to Write, React to Response, No React to Read, No Autorespond to Read Requests, Output type write, No RBE on Output to Bus, No RBE on Input from Bus"<br/>
771
+ - Gateway configuration -> Advanced Options -> Node list in all flows: added more infos to each node in the list, to allow more control on the nodes overview. The options are: "No Initial Read, React to Write, React to Response, No React to Read, No Autorespond to Read Requests, Telegram type write, No RBE on Output to Bus, No RBE on Input from Bus"<br/>
766
772
  </p>
767
773
  <p>
768
774
  <b>Version 1.2.32</b> - May 2021<br/>
@@ -1064,7 +1070,7 @@
1064
1070
  </p>
1065
1071
  <p>
1066
1072
  <b>Version 1.1.64</b> - April 2020<br/>
1067
- - NEW: Added output type "Read", to issue a read by simply pass a payload to the node. Thanks @waldbaer for the suggestion.<br/>
1073
+ - NEW: Added Telegram type "Read", to issue a read by simply pass a payload to the node. Thanks @waldbaer for the suggestion.<br/>
1068
1074
  </p>
1069
1075
  <p>
1070
1076
  <b>Version 1.1.63</b> - April 2020<br/>
@@ -1301,7 +1307,7 @@
1301
1307
  </p>
1302
1308
  <p>
1303
1309
  <b>Version 1.1.10</b><br/>
1304
- - Auto send node value as response to the KNX Bus. It works in conjunction with React to event GroupValue read. When checked, whenever the node receives a read request from bus, it sends a response to the KNX Bus with the stored payload value.<br/>
1310
+ - Auto send node value as response to the KNX Bus. It works in conjunction with React to read telegrams. When checked, whenever the node receives a read request from bus, it sends a response to the KNX Bus with the stored payload value.<br/>
1305
1311
  - Fixed an issue where if you have a node set to Universal mode (listen to all Group Addresses) (with ETS CSV File set) and you create a new node having a Group Addr. not in the ETS CSV file, an exception is raised but not caught and the nodes may not receive the values from KNX BUS.<br/>
1306
1312
  </p>
1307
1313
  <p>
@@ -1410,7 +1416,7 @@
1410
1416
  </p>
1411
1417
  <p>
1412
1418
  <b>Version 0.0.6 BETA</b><br/>
1413
- - Fixed Output Type unable to be set<br/>
1419
+ - Fixed Telegram type unable to be set<br/>
1414
1420
  - Added node status for response (blue) and read (grey)<br/>
1415
1421
  </p>
1416
1422
  <p>
@@ -1,3 +1,4 @@
1
+ /* eslint-disable no-lonely-if */
1
2
  /* eslint-disable no-param-reassign */
2
3
  /* eslint-disable no-inner-declarations */
3
4
  /* eslint-disable max-len */
@@ -54,6 +55,7 @@ module.exports = (RED) => {
54
55
  const node = this;
55
56
  node.host = config.host;
56
57
  node.nodeClients = []; // Stores the registered clients
58
+ node.nodeClientsAwaitingInit = []; // Stores the nodes client to be initialized
57
59
  node.loglevel = config.loglevel !== undefined ? config.loglevel : "error"; // 18/02/2020 Loglevel default error
58
60
  node.sysLogger = null;
59
61
  node.hueAllResources = null;
@@ -108,18 +110,26 @@ module.exports = (RED) => {
108
110
  node.hueAllResources = await node.hueManager.hueApiV2.get("/resource");
109
111
  node.hueAllRooms = node.hueAllResources.filter((a) => a.type === "room");
110
112
  // Update all KNX State of the nodes with the new hue device values
113
+ if (node.nodeClientsAwaitingInit !== undefined) {
114
+ // Because the whole process is async, if the function await node.hueManager.hueApiV2.get("/resource") has not jet been called or is late,
115
+ // the node/nodes belonging to this server, has been previously added to the nodeClientsAwaitingInit list.
116
+ node.nodeClientsAwaitingInit.forEach((nodeClient) => {
117
+ node.nodeClients.push(nodeClient);
118
+ });
119
+ node.nodeClientsAwaitingInit = [];
120
+ }
111
121
  node.nodeClients.forEach((nodeClient) => {
112
122
  if (nodeClient.hueDevice !== undefined) {
113
123
  const oHUEDevice = node.hueAllResources.filter((a) => a.id === nodeClient.hueDevice)[0];
114
124
  if (oHUEDevice !== undefined) {
125
+ // Add _Node to the clients array
126
+ nodeClient.setNodeStatusHue({
127
+ fill: "green",
128
+ shape: "ring",
129
+ text: "Ready :-)",
130
+ });
115
131
  nodeClient.currentHUEDevice = oHUEDevice;
116
132
  nodeClient.handleSendHUE(oHUEDevice);
117
- // for (const [key, value] of Object.entries(oHUEDevice)) {
118
- // // Update KNX State
119
- // const oProperty = { id: oHUEDevice.id };
120
- // oProperty[key] = value;
121
- // nodeClient.handleSendHUE(oProperty);
122
- // }
123
133
  }
124
134
  }
125
135
  });
@@ -262,20 +272,29 @@ module.exports = (RED) => {
262
272
  };
263
273
 
264
274
  node.addClient = (_Node) => {
265
- // Check if node already exists
266
- if (node.nodeClients.filter((x) => x.id === _Node.id).length === 0) {
267
- // Add _Node to the clients array
268
- _Node.setNodeStatusHue({
269
- fill: "grey",
270
- shape: "ring",
271
- text: "Hue initialized.",
272
- });
273
- node.nodeClients.push(_Node);
274
- // Update the node hue device, as soon as a node register itself to hue-config nodeClients
275
- if (node.hueAllResources !== null) { // At first start, due to the async method for retrieving hueAllResources, hueAllResources is still null. The first start is handled in node.hueManager.on("connected")
275
+ // Update the node hue device, as soon as a node register itself to hue-config nodeClients
276
+ if (node.hueAllResources !== null) {
277
+ if (node.nodeClients.filter((x) => x.id === _Node.id).length === 0) { // At first start, due to the async method for retrieving hueAllResources, hueAllResources is still null. The first start is handled in node.hueManager.on("connected")
276
278
  const oHUEDevice = node.hueAllResources.filter((a) => a.id === _Node.hueDevice)[0];
277
279
  _Node.currentHUEDevice = oHUEDevice;
278
280
  if (oHUEDevice !== undefined) _Node.handleSendHUE(oHUEDevice);
281
+ node.nodeClients.push(_Node);
282
+ // Add _Node to the clients array
283
+ _Node.setNodeStatusHue({
284
+ fill: "green",
285
+ shape: "ring",
286
+ text: "Ready",
287
+ });
288
+ }
289
+ } else {
290
+ if (node.nodeClientsAwaitingInit.filter((x) => x.id === _Node.id).length === 0) {
291
+ // Put the node in the waiting list
292
+ node.nodeClientsAwaitingInit.push(_Node);
293
+ _Node.setNodeStatusHue({
294
+ fill: "grey",
295
+ shape: "dot",
296
+ text: "Awaiting HUE Resources",
297
+ });
279
298
  }
280
299
  }
281
300
  };
@@ -74,8 +74,8 @@ module.exports = (RED) => {
74
74
  help: `// KNX-Ultimate set as UNIVERSAL NODE
75
75
  // Example of a function that sends a message to the KNX-Ultimate
76
76
  msg.destination = "0/0/1"; // Set the destination
77
- msg.payload = false; // issues a write or response (based on the options Output Type above) to the KNX bus
78
- msg.event = "GroupValue_Write"; // "GroupValue_Write" or "GroupValue_Response", overrides the option Output Type above.
77
+ msg.payload = false; // issues a write or response (based on the options Telegram type above) to the KNX bus
78
+ msg.event = "GroupValue_Write"; // "GroupValue_Write" or "GroupValue_Response", overrides the option Telegram type above.
79
79
  msg.dpt = "1.001"; // for example "1.001", overrides the Datapoint option. (Datapoints can be sent as 9 , "9" , "9.001" or "DPT9.001")
80
80
  return msg;`,
81
81
  helplink: "https://github.com/Supergiovane/node-red-contrib-knx-ultimate/wiki",
@@ -337,10 +337,7 @@
337
337
  <br />
338
338
 
339
339
  <label for="node-input-server">
340
- <span id="divknxsecure">
341
- <font color="green" size="4px"><i class="fa fa-shield" aria-hidden="true"></i></font>
342
- </span>&nbsp;<span><i class="fa fa-circle-o" aria-hidden="true"></i></font></span>
343
- <span data-i18n="knxUltimate.properties.node-input-server"></span>
340
+ <i class="fa fa-circle-o"></i> Gateway
344
341
  </label>
345
342
  <input type="text" id="node-input-server" />
346
343
  </div>
@@ -354,17 +351,16 @@
354
351
  src="data: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QgZW5kPSJyIj8+DGyPFQAAAE9JREFUKJG1UEEOACAIgub/v2yHalnJVoe4uIEKSgccJ9jroVmjA0+ujZtWku3DgZmgBiT4egN9CmmEAAfA/5HUW0OQu7dKmOCzmM3k9YYKZv8ZEZ/YgNsAAAAASUVORK5CYII="></img>
355
352
  <span data-i18n="knxUltimate.properties.node-input-topic"></span>
356
353
  </label>
357
- <input style="width:60%" type="text" id="node-input-topic" placeholder="Ex: 1/1/1" />
354
+ <input type="text" id="node-input-topic" placeholder="Sample: Dinning light" />
358
355
  </div>
359
356
  <div class="form-row">
360
357
  <label for="node-input-dpt">
361
358
  <img
362
359
  src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAKRGlDQ1BJQ0MgUHJvZmlsZQAAeAGdlndUFNcXx9/MbC+0XZYiZem9twWkLr1IlSYKy+4CS1nWZRewN0QFIoqICFYkKGLAaCgSK6JYCAgW7AEJIkoMRhEVlczGHPX3Oyf5/U7eH3c+8333nnfn3vvOGQAoASECYQ6sAEC2UCKO9PdmxsUnMPG9AAZEgAM2AHC4uaLQKL9ogK5AXzYzF3WS8V8LAuD1LYBaAK5bBIQzmX/p/+9DkSsSSwCAwtEAOx4/l4tyIcpZ+RKRTJ9EmZ6SKWMYI2MxmiDKqjJO+8Tmf/p8Yk8Z87KFPNRHlrOIl82TcRfKG/OkfJSREJSL8gT8fJRvoKyfJc0WoPwGZXo2n5MLAIYi0yV8bjrK1ihTxNGRbJTnAkCgpH3FKV+xhF+A5gkAO0e0RCxIS5cwjbkmTBtnZxYzgJ+fxZdILMI53EyOmMdk52SLOMIlAHz6ZlkUUJLVlokW2dHG2dHRwtYSLf/n9Y+bn73+GWS9/eTxMuLPnkGMni/al9gvWk4tAKwptDZbvmgpOwFoWw+A6t0vmv4+AOQLAWjt++p7GLJ5SZdIRC5WVvn5+ZYCPtdSVtDP6386fPb8e/jqPEvZeZ9rx/Thp3KkWRKmrKjcnKwcqZiZK+Jw+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77++sUiuSFw0uMF1w96NmI2Cjb2b7Dbt3PSxmFd8pcS6pLLkfSm39Mo3Nt9UfTO7OXVzb5lj2Z4tuC3CLbe2emw9VK5YvrR8ZFvottYKZkVxxavtSdsvV9pX7t1B2iHdMVQVUtW+U3/nlp3vq9Orb9Z41zTv0ti1adf0bt7ugT2ee5r2au4t2ftun2Df7f3++1trDWsrD+AO5B14XBdT1/0t69uGevX6kvoPB4UHhw5FHupqcGpoOKxxuKwRbpQ2jh9JPHLtO5/v2pssmvY3M5pLjoKj0qNPv0/+/tax4GOdx1nHm34w+GFXC62luBVqXdI62ZbeNtQe395/IuhEZ4drR8uPlj8ePKlzsuaU8qmy06TThadnzyw9M3VWdHbiXNq5kc6kznvn487f6Iro6r0QfOHSRb+L57u9us9ccrt08rLL5RNXWFfarjpebe1x6Gn5yeGnll7H3tY+p772a87XOvrn9p8e8Bg4d93n+sUbgTeu3px3s//W/Fu3BxMHh27zbj+5k3Xnxd28uzP3Vt/H3i9+oPCg8qHGw9qfTX5uHnIcOjXsM9zzKOrRvRHuyLNfcn95P1r4mPq4ckx7rOGJ7ZOT437j154ueDr6TPRsZqLoV8Vfdz03fv7Db56/9UzGTY6+EL+Y/b30pdrLg6/sX3VOhU89fJ39ema6+I3am0NvWW+738W+G5vJf49/X/XB5EPHx+CP92ezZ2f/AAOY8/xJsCmYAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAfklEQVQ4EaWTwQnAIAxFU3AYnclVHNQtFPTgrcWC8JNL2sSL+fjz1BiJnOM6+THG+8R/5oDmUgpKyjkzLUVKiRhgrSU9qmaAOaeaIA0MMMaQ66pmgN67miANAatvAiCxtYbyUxxqrW8v7JOYALiN+wpugPsZLY3k/kxYQ1P8AA+YKsRd6CkwAAAAAElFTkSuQmCC"></img>
363
- <span data-i18n="knxUltimate.properties.node-input-dpt"></span>
360
+ Datapoint
364
361
  </label>
365
- <select style="width:40%" id="node-input-dpt"></select>
362
+ <select id="node-input-dpt"></select>
366
363
  <span id="sampleCodeEditor" style="color:red;" />
367
-
368
364
  </div>
369
365
  </div>
370
366
  <div class="form-row">
@@ -395,45 +391,30 @@
395
391
 
396
392
  <div id="tabs">
397
393
  <ul>
398
- <li><a href="#tabs-1"><i class="fa fa-code"></i> Sample in Function</a></li>
399
- <li><a href="#tabs-2"><i class="fa fa-braille"></i> Advanced options</a></li>
400
- <li><a href="#tabs-3"><i class="fa fa-list-ol"></i> Format input</a></li>
394
+ <li><a href="#tabs-1"><i class="fa fa-braille"></i> Advanced options</a></li>
395
+ <li><a href="#tabs-2"><i class="fa fa-list-ol"></i> Format input</a></li>
396
+ <li><a href="#tabs-3"><i class="fa fa-code"></i> Payload Sample</a></li>
401
397
  </ul>
402
398
  <div id="tabs-1">
403
- <p>
404
- <div style="height:200px;min-height:150px;padding:0px;">
405
- <div style="height:100%;width:100%;padding:0px;" class="node-text-editor" id="example-editor"></div>
406
- </div>
407
- </p>
408
- </div>
409
-
410
- <div id="tabs-2">
411
- <p>
412
-
413
-
414
399
  <div class="form-row" style="padding:10px">
415
400
  <div class="form-row">
416
- <label style="width:230px" for="node-input-passthrough">
417
- <i class="fa fa-long-arrow-right"></i>
418
- <span data-i18n="knxUltimate.properties.node-input-passthrough"></span>
401
+ <label style="width:180px" for="node-input-passthrough">
402
+ <i class="fa fa-long-arrow-right"></i> Msg passthrough
419
403
  </label>
420
- <select style="width:92px" id="node-input-passthrough">
404
+ <select id="node-input-passthrough">
421
405
  <option value="no" data-i18n="knxUltimate.selectlists.passthrough_No"></option>
422
406
  <option value="yes" data-i18n="knxUltimate.selectlists.passthrough_Leave"></option>
423
407
  <option value="yesownprop" data-i18n="knxUltimate.selectlists.passthrough_OwnProp"></option>
424
408
  </select>
425
409
  </div>
426
- <br />
427
410
  <div class="form-row">
428
411
  <dt>
429
- <i class="fa fa-arrow-right"></i>|
430
- <span data-i18n="knxUltimate.advanced.OUTPUT"></span>
412
+ <i class="fa fa-arrow-right"></i> CONTROL (payload to KNX bus)
431
413
  </dt>
432
414
  </div>
433
415
  <div class="form-row">
434
- &nbsp;&nbsp;<label for="node-input-outputtype">
435
- <i class="fa fa-paper-plane-o"></i>
436
- <span data-i18n="knxUltimate.properties.node-input-outputtype"></span>
416
+ <label style="width:180px" for="node-input-outputtype">
417
+ <i class="fa fa-paper-plane-o"></i> Telegram type
437
418
  </label>
438
419
  <select id="node-input-outputtype">
439
420
  <option value="write" data-i18n="knxUltimate.selectlists.Output_write"></option>
@@ -443,25 +424,23 @@
443
424
  </select>
444
425
  </div>
445
426
  <div class="form-row" id="divOutputRBE">
446
- &nbsp;&nbsp;<input type="checkbox" id="node-input-outputRBE"
427
+ <input type="checkbox" id="node-input-outputRBE"
447
428
  style="display:inline-block; width:auto; vertical-align:top;" />
448
429
  <label style="width:85%" for="node-input-outputRBE">
449
- <i class="fa fa-filter"></i>
450
- <span data-i18n="knxUltimate.properties.node-input-outputRBE"></span>
430
+ <i class="fa fa-filter"></i> Send payload to KNX only if changed (RBE filter)
451
431
  </label>
452
432
  </div>
453
433
  <br />
454
434
  <div class="form-row">
455
435
  <dt>
456
- |<i class="fa fa-arrow-right"></i>
457
- <span data-i18n="knxUltimate.advanced.INPUT"></span>
436
+ |<i class="fa fa-arrow-right"></i> STATUS (payload from KNX BUS)
458
437
  </dt>
459
438
  </div>
460
439
  <div class="form-row" id="divNode-input-initialread">
461
- &nbsp;&nbsp;<label style="width:50%" for="node-input-initialread">
462
- <i class="fa fa-question-circle-o"></i> Read status upon connection
440
+ <label style="width:180px" for="node-input-initialread">
441
+ <i class="fa fa-question-circle-o"></i> Read status on start
463
442
  </label>
464
- <select style="width:100px" id="node-input-initialread">
443
+ <select id="node-input-initialread">
465
444
  <option value=0 data-i18n="knxUltimate.properties.node-input-initialread0"></option>
466
445
  <option value=1 data-i18n="knxUltimate.properties.node-input-initialread1"></option>
467
446
  <option value=2 data-i18n="knxUltimate.properties.node-input-initialread2"></option>
@@ -470,42 +449,38 @@
470
449
 
471
450
  </div>
472
451
  <div class="form-row" id="divInputRBE">
473
- &nbsp;&nbsp;<input type="checkbox" id="node-input-inputRBE"
452
+ <input type="checkbox" id="node-input-inputRBE"
474
453
  style="display:inline-block; width:auto; vertical-align:top;" />
475
454
  <label style="width:85%" for="node-input-inputRBE">
476
- <i class="fa fa-filter"></i>
477
- <span data-i18n="knxUltimate.properties.node-input-inputRBE"></span>
455
+ <i class="fa fa-filter"></i> React only by changed payload (RBE filter)
478
456
  </label>
479
457
  </div>
480
458
  <div class="form-row">
481
- &nbsp;&nbsp;<input type="checkbox" id="node-input-notifywrite"
459
+ <input type="checkbox" id="node-input-notifywrite"
482
460
  style="display:inline-block; width:auto; vertical-align:top;" />
483
461
  <label style="width:85%" for="node-input-notifywrite">
484
- <i class="fa fa-sign-in"></i>
485
- <span data-i18n="knxUltimate.properties.node-input-notifywrite"></span>
462
+ <i class="fa fa-sign-in"></i> React to write telegrams
486
463
  </label>
487
464
  </div>
488
465
  <div class="form-row">
489
- &nbsp;&nbsp;<input type="checkbox" id="node-input-notifyresponse"
466
+ <input type="checkbox" id="node-input-notifyresponse"
490
467
  style="display:inline-block; width:auto; vertical-align:top;" />
491
468
  <label style="width:85%" for="node-input-notifyresponse">
492
- <i class="fa fa-sign-in"></i>
493
- <span data-i18n="knxUltimate.properties.node-input-notifyresponse"></span>
469
+ <i class="fa fa-sign-in"></i> React to response telegrams
494
470
  </label>
495
471
  </div>
496
472
  <div class="form-row">
497
- &nbsp;&nbsp;<input type="checkbox" id="node-input-notifyreadrequest"
473
+ <input type="checkbox" id="node-input-notifyreadrequest"
498
474
  style="display:inline-block; width:auto; vertical-align:top;" />
499
475
  <label style="width:85%" for="node-input-notifyreadrequest">
500
- <i class="fa fa-sign-in"></i>
501
- <span data-i18n="knxUltimate.properties.node-input-notifyreadrequest"></span>
476
+ <i class="fa fa-sign-in"></i> React to read telegrams
502
477
  </label>
503
478
  </div>
504
479
 
505
480
  <div id="divnotifyreadrequestautoreact">
506
481
  <dd>
507
482
  <div class="form-row">
508
- &nbsp;&nbsp;<input type="checkbox" id="node-input-notifyreadrequestalsorespondtobus"
483
+ <input type="checkbox" id="node-input-notifyreadrequestalsorespondtobus"
509
484
  style="display:inline-block; width:auto; vertical-align:top;" />
510
485
  <label style="width:85%" for="node-input-notifyreadrequestalsorespondtobus">
511
486
  <span
@@ -513,7 +488,7 @@
513
488
  </label>
514
489
  </div>
515
490
  <div class="form-row">
516
- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<label style="width:auto">
491
+ &nbsp;<label style="width:auto">
517
492
  <span
518
493
  data-i18n="knxUltimate.properties.node-input-notifyreadrequestalsorespondtobusdefaultvalueifnotinitialized"></span>
519
494
  </label>
@@ -524,11 +499,9 @@
524
499
  </dd>
525
500
  </div>
526
501
  </div>
527
-
528
- </p>
529
502
  </div>
530
- <div id="tabs-3">
531
- <p>
503
+
504
+ <div id="tabs-2">
532
505
  <div class="form-row" style="padding:10px">
533
506
  <div class="form-row">
534
507
  <dt>
@@ -577,7 +550,12 @@
577
550
  </select>
578
551
  </div>
579
552
  </div>
580
- </p>
553
+
554
+ </div>
555
+ <div id="tabs-3">
556
+ <div style="height:200px;min-height:150px;padding:0px;">
557
+ <div style="height:100%;width:100%;padding:0px;" class="node-text-editor" id="example-editor"></div>
558
+ </div>
581
559
  </div>
582
560
  </div>
583
561
 
@@ -607,13 +585,13 @@
607
585
  | Universal mode (listen to all Group Addresses) | By setting this, the node will read and control ALL group addresses. |
608
586
  | Sample Function | This will give it a hint on what to write in a function, if you want to control the node via a Node-Red function node. |
609
587
  | Input msg passthrough | If set, you can pass the input mgs to the output msg. |
610
- | Output Type | *write* to send write telegram (usually, you want that), otherwise you can choose the telegram's type to react to. |
611
- | Send payload to BUS only if changed (RBE filter) | *Report by change* filter. If set, only the msg input (from the Flow) having different values each time, will be sent to the KNX bus. If you intend to send everytime the same value, turn it off. |
612
- | Read status upon connection | Read group address status, every time Node-Red starts and at every reconnection to the KNX Gateway. The node stores all group address values to a file, so you can choose wether to read from file or from the KNX bus. |
613
- | React only if payload from BUS is changed (RBE filter) | *Report by change* filter. If set, only the msg output (to KNX bus) having different values each time, will be sent to the msg output's flow. If you intend to send everytime the same value, leave it off. |
614
- | React to event GroupValue write | The node will react (will send a msg to the flow) each time it receives a *write* telegram from the KNX bus. Usually, you want that. |
615
- | React to event GroupValue response | The node will react (will send a msg to the flow) each time it receives a *response* telegram from the KNX bus. Usually, you want that for particular scenarios. |
616
- | React to event GroupValue read | The node will react (will send a msg to the flow) each time it receives a *read* telegram from the KNX bus. Usually, you want that if you're want to send a custom value to the KNX BUS. |
588
+ | Telegram type | *write* to send write telegram (usually, you want that), otherwise you can choose the telegram's type to react to. |
589
+ | Send payload to KNX only if changed (RBE filter) | *Report by change* filter. If set, only the msg input (from the Flow) having different values each time, will be sent to the KNX bus. If you intend to send everytime the same value, turn it off. |
590
+ | Read status on start | Read group address status, every time Node-Red starts and at every reconnection to the KNX Gateway. The node stores all group address values to a file, so you can choose wether to read from file or from the KNX bus. |
591
+ | React only by changed payload (RBE filter) | *Report by change* filter. If set, only the msg output (to KNX bus) having different values each time, will be sent to the msg output's flow. If you intend to send everytime the same value, leave it off. |
592
+ | React to write telegrams | The node will react (will send a msg to the flow) each time it receives a *write* telegram from the KNX bus. Usually, you want that. |
593
+ | React to response telegrams | The node will react (will send a msg to the flow) each time it receives a *response* telegram from the KNX bus. Usually, you want that for particular scenarios. |
594
+ | React to read telegrams | The node will react (will send a msg to the flow) each time it receives a *read* telegram from the KNX bus. Usually, you want that if you're want to send a custom value to the KNX BUS. |
617
595
  | Format input | Allow you to format numeric values received from the KNX Bus. |
618
596
 
619
597
  <br/>
@@ -146,7 +146,7 @@ module.exports = function (RED) {
146
146
  node.inputmessage = RED.util.cloneMessage(msg); // 28/03/2020 Store the message to be passed through.
147
147
  }
148
148
 
149
- // 25/07/2019 if payload is read or the output type is set to "read", do a read, otherwise, write to the bus
149
+ // 25/07/2019 if payload is read or the Telegram type is set to "read", do a read, otherwise, write to the bus
150
150
  if ((msg.hasOwnProperty('readstatus') && msg.readstatus === true) || node.outputtype === 'read') {
151
151
  // READ: Send a Read request to the bus
152
152
  let grpaddr = '';
@@ -156,7 +156,7 @@ module.exports = function (RED) {
156
156
  // 29/12/2020 Protection over circular references (for example, if you link two Ultimate Nodes toghether with the same group address), to prevent infinite loops
157
157
  if (msg.hasOwnProperty('knx')) {
158
158
  if (msg.knx.destination == grpaddr && ((msg.knx.event === 'GroupValue_Response' || msg.knx.event === 'GroupValue_Read'))) {
159
- if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection during READ. The node ${node.id} has been temporary disabled. Two nodes with same group address and reaction/output type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
159
+ if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection during READ. The node ${node.id} has been temporary disabled. Two nodes with same group address and reaction/Telegram type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
160
160
  const t = setTimeout(() => { // 21/03/2022 fixed possible memory leak. Previously was setTimeout without "let t = ".
161
161
  node.setNodeStatus({
162
162
  fill: 'red', shape: 'ring', text: `DISABLED due to a circulare reference while READ (${grpaddr}).`, payload: '', GA: '', dpt: '', devicename: '',
@@ -178,7 +178,7 @@ module.exports = function (RED) {
178
178
  // 29/12/2020 Protection over circular references (for example, if you link two Ultimate Nodes toghether with the same group address), to prevent infinite loops
179
179
  if (msg.hasOwnProperty('knx')) {
180
180
  if (msg.knx.destination == grpaddr && ((msg.knx.event === 'GroupValue_Response' || msg.knx.event === 'GroupValue_Read'))) {
181
- if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection during READ-2. The node ${node.id} has been temporary disabled. Two nodes with same group address and reaction/output type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
181
+ if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection during READ-2. The node ${node.id} has been temporary disabled. Two nodes with same group address and reaction/Telegram type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
182
182
  const t = setTimeout(() => { // 21/03/2022 fixed possible memory leak. Previously was setTimeout without "let t = ".
183
183
  node.setNodeStatus({
184
184
  fill: 'red', shape: 'ring', text: `DISABLED due to a circulare reference while READ-2 (${grpaddr}).`, payload: '', GA: '', dpt: '', devicename: '',
@@ -201,7 +201,7 @@ module.exports = function (RED) {
201
201
  // 29/12/2020 Protection over circular references (for example, if you link two Ultimate Nodes toghether with the same group address), to prevent infinite loops
202
202
  if (msg.hasOwnProperty('knx')) {
203
203
  if (msg.knx.destination == grpaddr && ((msg.knx.event === 'GroupValue_Response' || msg.knx.event === 'GroupValue_Read'))) {
204
- if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection during READ-3. Node ${node.id} The read request hasn't been sent. Two nodes with same group address and reaction/output type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
204
+ if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection during READ-3. Node ${node.id} The read request hasn't been sent. Two nodes with same group address and reaction/Telegram type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
205
205
  node.setNodeStatus({
206
206
  fill: 'red', shape: 'ring', text: `NOT SENT due to a circulare reference while READ-3 (${grpaddr}).`, payload: '', GA: '', dpt: '', devicename: '',
207
207
  });
@@ -322,7 +322,7 @@ module.exports = function (RED) {
322
322
  // Protection over circular references (for example, if you link two Ultimate Nodes toghether with the same group address), to prevent infinite loops
323
323
  if (msg.hasOwnProperty('knx')) {
324
324
  if (msg.knx.destination == grpaddr && ((msg.knx.event === 'GroupValue_Write' && outputtype === 'write') || (msg.knx.event === 'GroupValue_Response' && outputtype === 'response') || (msg.knx.event === 'GroupValue_Response' && outputtype === 'read') || (msg.knx.event === 'GroupValue_Read' && outputtype === 'read'))) {
325
- if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection. The node ${node.id} has been temporarely disabled. Two nodes with same group address and reaction/output type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
325
+ if (node.sysLogger !== undefined && node.sysLogger !== null) node.sysLogger.error(`knxUltimate: Circular reference protection. The node ${node.id} has been temporarely disabled. Two nodes with same group address and reaction/Telegram type are linked. See the FAQ in the Wiki. Msg:${JSON.stringify(msg)}`);
326
326
  const t = setTimeout(() => { // 21/03/2022 fixed possible memory leak. Previously was setTimeout without "let t = ".
327
327
  node.setNodeStatus({
328
328
  fill: 'red', shape: 'ring', text: `DISABLED due to a circulare reference (${grpaddr}).`, payload: '', GA: '', dpt: '', devicename: '',