node-red-contrib-knx-ultimate 3.2.4 → 3.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 +3 -0
- package/nodes/knxUltimateViewer.js +16 -31
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -140,21 +140,24 @@ module.exports = function (RED) {
|
|
|
140
140
|
// outputtype: "read",
|
|
141
141
|
// nodecallerid: _oClient.id,
|
|
142
142
|
// });
|
|
143
|
-
|
|
143
|
+
let sHead = '';
|
|
144
|
+
let sFooter = '';
|
|
144
145
|
let sPayload = '';
|
|
146
|
+
try {
|
|
147
|
+
const aItems = _.clone(node.serverKNX.knxConnection.commandQueue);
|
|
148
|
+
if (aItems === undefined) return;
|
|
145
149
|
|
|
146
|
-
|
|
150
|
+
sHead = `<div class="main"><table><caption>Queue of outgoing telegrams to the KNX BUS. The more the count,</br>the more congested is the KNX BUS.</caption>
|
|
147
151
|
<thead>
|
|
148
152
|
<tr>
|
|
149
|
-
<th>
|
|
150
|
-
<th>
|
|
151
|
-
<th>
|
|
152
|
-
<th>
|
|
153
|
-
<th> Caller Node (id) </th>
|
|
153
|
+
<th> Channel ID </th>
|
|
154
|
+
<th> Sequence counter </th>
|
|
155
|
+
<th> Type of packet</th>
|
|
156
|
+
<th> Status </th>
|
|
154
157
|
</tr>
|
|
155
158
|
</thead>
|
|
156
159
|
<tbody>`;
|
|
157
|
-
|
|
160
|
+
sFooter = `</tbody><tfoot>
|
|
158
161
|
<tr>
|
|
159
162
|
<th scope="row">Count</th>
|
|
160
163
|
<td>` + aItems.length + `</td>
|
|
@@ -162,31 +165,13 @@ module.exports = function (RED) {
|
|
|
162
165
|
</tfoot>
|
|
163
166
|
</table></div>`;
|
|
164
167
|
|
|
165
|
-
|
|
168
|
+
|
|
166
169
|
for (let index = 0; index < aItems.length; index++) {
|
|
167
170
|
const element = aItems[index];
|
|
168
|
-
sPayload += '<tr><td>' + element.
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
sPayload += '<td><font color=red>False</font></td>';
|
|
173
|
-
} else if (typeof element.payload === 'object' && !isNaN(Date.parse(element.payload))) {
|
|
174
|
-
// The payload is a datetime
|
|
175
|
-
sPayload += '<td>' + element.payload.toLocaleString() + '</td>';
|
|
176
|
-
} else if (typeof element.payload === 'object') {
|
|
177
|
-
// Is maybe a JSON?
|
|
178
|
-
try {
|
|
179
|
-
// sPayload += '<td>' + JSON.stringify(element.payload) + '</td>'
|
|
180
|
-
sPayload += '<td><i>' + element.rawPayload + '</i></td>';
|
|
181
|
-
} catch (error) {
|
|
182
|
-
sPayload += '<td>' + element.payload + '</td>';
|
|
183
|
-
}
|
|
184
|
-
} else {
|
|
185
|
-
sPayload += '<td>' + element.payload + element.payloadmeasureunit + '</td>';
|
|
186
|
-
}
|
|
187
|
-
sPayload += '<td>' + element.dpt + '</td>';
|
|
188
|
-
sPayload += '<td>' + element.outputtype + '</td>';
|
|
189
|
-
sPayload += '<td><font style="font-size: smaller;">' + element.nodecallerid + '</font></td></tr>';
|
|
171
|
+
sPayload += '<tr><td>' + element.knxPacket.channelID + '</td>';
|
|
172
|
+
sPayload += '<td><b><font color=green>' + element.knxPacket.seqCounter + '</font></b></td>';
|
|
173
|
+
sPayload += '<td>' + element.knxPacket.type + '</td>';
|
|
174
|
+
sPayload += '<td>' + element.knxPacket.status + '</td></tr>';
|
|
190
175
|
}
|
|
191
176
|
} catch (error) {
|
|
192
177
|
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"engines": {
|
|
4
4
|
"node": ">=16.0.0"
|
|
5
5
|
},
|
|
6
|
-
"version": "3.2.
|
|
6
|
+
"version": "3.2.5",
|
|
7
7
|
"description": "Control your KNX intallation via Node-Red! A bunch of KNX nodes, with integrated Philips HUE control and ETS group address importer. Easy to use and highly configurable.",
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"binary-parser": "2.2.1",
|