node-red-contrib-knx-ultimate 5.2.5 → 6.0.0
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 +9 -0
- package/nodes/commonFunctions.js +40 -3
- package/nodes/knxUltimate-config.js +379 -335
- package/nodes/knxUltimate.html +8 -9
- package/nodes/knxUltimate.js +5 -5
- package/nodes/knxUltimateAI.js +1 -1
- package/nodes/knxUltimateHueLight.html +3 -3
- package/nodes/knxUltimateHueLight.js +1 -1
- package/nodes/knxUltimateMatterBridge.html +321 -247
- package/nodes/knxUltimateMatterBridge.js +48 -1
- package/nodes/knxUltimateMatterControllerDevice.html +2119 -0
- package/nodes/knxUltimateMatterControllerDevice.js +1701 -0
- package/nodes/locales/de/knxUltimateMatterBridge.html +6 -2
- package/nodes/locales/de/knxUltimateMatterBridge.json +14 -1
- package/nodes/locales/de/knxUltimateMatterControllerDevice.html +27 -0
- package/nodes/locales/de/knxUltimateMatterControllerDevice.json +97 -0
- package/nodes/locales/de/matter-config.json +5 -1
- package/nodes/locales/de/matterbridge-config.json +1 -0
- package/nodes/locales/en/knxUltimateMatterBridge.html +6 -2
- package/nodes/locales/en/knxUltimateMatterBridge.json +14 -1
- package/nodes/locales/en/knxUltimateMatterControllerDevice.html +27 -0
- package/nodes/locales/en/knxUltimateMatterControllerDevice.json +97 -0
- package/nodes/locales/en/matter-config.json +6 -1
- package/nodes/locales/en/matterbridge-config.json +1 -0
- package/nodes/locales/es/knxUltimateMatterBridge.html +6 -2
- package/nodes/locales/es/knxUltimateMatterBridge.json +14 -1
- package/nodes/locales/es/knxUltimateMatterControllerDevice.html +27 -0
- package/nodes/locales/es/knxUltimateMatterControllerDevice.json +97 -0
- package/nodes/locales/es/matter-config.json +5 -1
- package/nodes/locales/es/matterbridge-config.json +1 -0
- package/nodes/locales/fr/knxUltimateMatterBridge.html +6 -2
- package/nodes/locales/fr/knxUltimateMatterBridge.json +14 -1
- package/nodes/locales/fr/knxUltimateMatterControllerDevice.html +27 -0
- package/nodes/locales/fr/knxUltimateMatterControllerDevice.json +89 -0
- package/nodes/locales/fr/matter-config.json +5 -1
- package/nodes/locales/fr/matterbridge-config.json +1 -0
- package/nodes/locales/it/knxUltimateMatterBridge.html +6 -2
- package/nodes/locales/it/knxUltimateMatterBridge.json +14 -1
- package/nodes/locales/it/knxUltimateMatterControllerDevice.html +27 -0
- package/nodes/locales/it/knxUltimateMatterControllerDevice.json +97 -0
- package/nodes/locales/it/matter-config.json +6 -1
- package/nodes/locales/it/matterbridge-config.json +1 -0
- package/nodes/locales/zh-CN/knxUltimateMatterBridge.html +6 -2
- package/nodes/locales/zh-CN/knxUltimateMatterBridge.json +14 -1
- package/nodes/locales/zh-CN/knxUltimateMatterControllerDevice.html +27 -0
- package/nodes/locales/zh-CN/knxUltimateMatterControllerDevice.json +89 -0
- package/nodes/locales/zh-CN/matter-config.json +5 -1
- package/nodes/locales/zh-CN/matterbridge-config.json +1 -0
- package/nodes/matter-config.html +58 -6
- package/nodes/matter-config.js +7 -2
- package/nodes/matterbridge-config.html +1 -0
- package/nodes/utils/lightEngines/canonicalLight.js +75 -0
- package/nodes/utils/lightEngines/hueLightEngine.js +51 -0
- package/nodes/utils/lightEngines/index.js +25 -0
- package/nodes/utils/lightEngines/knxLightCommand.js +79 -0
- package/nodes/utils/lightEngines/lightEngine.js +46 -0
- package/nodes/utils/lightEngines/matterHueShim.js +59 -0
- package/nodes/utils/lightEngines/matterLightEngine.js +117 -0
- package/nodes/utils/matterEngine.mjs +185 -14
- package/nodes/utils/matterKnxConverter.js +1 -1
- package/package.json +11 -3
- package/resources/KNXSendSnippets.js +53 -53
- package/resources/htmlUtils.js +6 -4
- package/nodes/knxUltimateMatterDevice.html +0 -632
- package/nodes/knxUltimateMatterDevice.js +0 -308
- package/nodes/locales/de/knxUltimateMatterDevice.html +0 -56
- package/nodes/locales/de/knxUltimateMatterDevice.json +0 -109
- package/nodes/locales/en/knxUltimateMatterDevice.html +0 -56
- package/nodes/locales/en/knxUltimateMatterDevice.json +0 -109
- package/nodes/locales/es/knxUltimateMatterDevice.html +0 -56
- package/nodes/locales/es/knxUltimateMatterDevice.json +0 -109
- package/nodes/locales/fr/knxUltimateMatterDevice.html +0 -56
- package/nodes/locales/fr/knxUltimateMatterDevice.json +0 -109
- package/nodes/locales/it/knxUltimateMatterDevice.html +0 -56
- package/nodes/locales/it/knxUltimateMatterDevice.json +0 -109
- package/nodes/locales/zh-CN/knxUltimateMatterDevice.html +0 -56
- package/nodes/locales/zh-CN/knxUltimateMatterDevice.json +0 -109
package/nodes/knxUltimate.html
CHANGED
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
},
|
|
88
88
|
onclick: function () {
|
|
89
89
|
const node = this;
|
|
90
|
-
const mode = node.buttonMode || '
|
|
90
|
+
const mode = node.buttonMode || 'toggle';
|
|
91
91
|
const request = { id: node.id, mode };
|
|
92
92
|
if (mode === 'value') {
|
|
93
93
|
request.value = node.buttonStaticValue;
|
|
@@ -167,7 +167,7 @@
|
|
|
167
167
|
const coerceBoolean = (value) => (value === true || value === 'true');
|
|
168
168
|
|
|
169
169
|
$buttonEnabled.prop('checked', coerceBoolean(node.buttonEnabled));
|
|
170
|
-
$buttonMode.val(node.buttonMode || '
|
|
170
|
+
$buttonMode.val(node.buttonMode || 'toggle');
|
|
171
171
|
$buttonToggleInitial.val(coerceBoolean(node.buttonToggleInitial) ? 'true' : 'false');
|
|
172
172
|
$buttonStaticValue.val(node.buttonStaticValue || '');
|
|
173
173
|
|
|
@@ -176,19 +176,19 @@
|
|
|
176
176
|
const refreshButtonOptions = () => {
|
|
177
177
|
const enabled = $buttonEnabled.prop('checked');
|
|
178
178
|
const rawMode = isRawDptSelected();
|
|
179
|
-
let mode = $buttonMode.val() || '
|
|
180
|
-
if (rawMode && mode
|
|
181
|
-
mode = '
|
|
182
|
-
$buttonMode.val('
|
|
179
|
+
let mode = $buttonMode.val() || 'toggle';
|
|
180
|
+
if (rawMode && mode === 'toggle') {
|
|
181
|
+
mode = 'value';
|
|
182
|
+
$buttonMode.val('value');
|
|
183
183
|
}
|
|
184
|
-
$buttonMode.find("option[value='toggle']
|
|
184
|
+
$buttonMode.find("option[value='toggle']").prop('disabled', rawMode);
|
|
185
185
|
if (enabled) {
|
|
186
186
|
$buttonOptions.show();
|
|
187
187
|
} else {
|
|
188
188
|
$buttonOptions.hide();
|
|
189
189
|
}
|
|
190
190
|
$buttonToggleRow.toggle(enabled && !rawMode && mode === 'toggle');
|
|
191
|
-
$buttonValueRow.toggle(enabled &&
|
|
191
|
+
$buttonValueRow.toggle(enabled && mode === 'value');
|
|
192
192
|
|
|
193
193
|
node.buttonEnabled = enabled;
|
|
194
194
|
node.buttonMode = mode;
|
|
@@ -1295,7 +1295,6 @@ return msg;`
|
|
|
1295
1295
|
<i class="fa fa-bolt"></i> <span data-i18n="knxUltimate.button.mode"></span>
|
|
1296
1296
|
</label>
|
|
1297
1297
|
<select id="node-input-buttonMode" style="width:220px;">
|
|
1298
|
-
<option value="read" data-i18n="knxUltimate.button.mode_read"></option>
|
|
1299
1298
|
<option value="toggle" data-i18n="knxUltimate.button.mode_toggle"></option>
|
|
1300
1299
|
<option value="value" data-i18n="knxUltimate.button.mode_value"></option>
|
|
1301
1300
|
</select>
|
package/nodes/knxUltimate.js
CHANGED
|
@@ -304,7 +304,7 @@ module.exports = function (RED) {
|
|
|
304
304
|
const payloadRounder = require('./utils/payloadManipulation')
|
|
305
305
|
const dptlib = require('knxultimate').dptlib
|
|
306
306
|
|
|
307
|
-
function knxUltimate(config) {
|
|
307
|
+
function knxUltimate (config) {
|
|
308
308
|
RED.nodes.createNode(this, config)
|
|
309
309
|
const node = this
|
|
310
310
|
node.serverKNX = RED.nodes.getNode(config.server) || undefined
|
|
@@ -513,7 +513,7 @@ module.exports = function (RED) {
|
|
|
513
513
|
}
|
|
514
514
|
|
|
515
515
|
// Used in the KNX Function TAB
|
|
516
|
-
const getGAValue = async function getGAValue(_ga = undefined, _dpt = undefined, _requestReadIfMissing = undefined) {
|
|
516
|
+
const getGAValue = async function getGAValue (_ga = undefined, _dpt = undefined, _requestReadIfMissing = undefined) {
|
|
517
517
|
if (_ga === undefined) return null
|
|
518
518
|
// Strip devicename if present (e.g. "1/1/1 Light name" → "1/1/1")
|
|
519
519
|
const blankSpacePosition = _ga.indexOf(' ')
|
|
@@ -593,7 +593,7 @@ module.exports = function (RED) {
|
|
|
593
593
|
return null
|
|
594
594
|
}
|
|
595
595
|
// Used in the KNX Function TAB
|
|
596
|
-
const setGAValue = function setGAValue(_ga = undefined, _value = undefined, _dpt = undefined) {
|
|
596
|
+
const setGAValue = function setGAValue (_ga = undefined, _value = undefined, _dpt = undefined) {
|
|
597
597
|
try {
|
|
598
598
|
if (_ga === undefined) return
|
|
599
599
|
// The GA can have the devicename as well, separated by a blank space (1/1/0 light table ovest),
|
|
@@ -620,7 +620,7 @@ module.exports = function (RED) {
|
|
|
620
620
|
}
|
|
621
621
|
}
|
|
622
622
|
// Used in the KNX Function TAB
|
|
623
|
-
const self = function self(_value) {
|
|
623
|
+
const self = function self (_value) {
|
|
624
624
|
try {
|
|
625
625
|
node.serverKNX.sendKNXTelegramToKNXEngine({
|
|
626
626
|
grpaddr: node.topic, payload: _value, dpt: node.dpt, outputtype: 'write', nodecallerid: node.id
|
|
@@ -632,7 +632,7 @@ module.exports = function (RED) {
|
|
|
632
632
|
}
|
|
633
633
|
}
|
|
634
634
|
// Used in the KNX Function TAB
|
|
635
|
-
const toggle = function toggle() {
|
|
635
|
+
const toggle = function toggle () {
|
|
636
636
|
if (node.currentPayload === true || node.currentPayload === false) {
|
|
637
637
|
try {
|
|
638
638
|
node.serverKNX.sendKNXTelegramToKNXEngine({
|
package/nodes/knxUltimateAI.js
CHANGED
|
@@ -4171,7 +4171,7 @@ module.exports = function (RED) {
|
|
|
4171
4171
|
if (provider === 'anthropic') {
|
|
4172
4172
|
const modelsUrl = deriveAnthropicModelsUrl(baseUrl)
|
|
4173
4173
|
const json = await getJson({ url: modelsUrl, headers: buildAnthropicHeaders(apiKey) })
|
|
4174
|
-
|
|
4174
|
+
const ids = (json && Array.isArray(json.data)) ? json.data.map(m => m && m.id).filter(Boolean) : []
|
|
4175
4175
|
ids.sort()
|
|
4176
4176
|
res.json({ provider, baseUrl: modelsUrl, models: ids, filtered: false })
|
|
4177
4177
|
return
|
|
@@ -2388,7 +2388,7 @@
|
|
|
2388
2388
|
|
|
2389
2389
|
**Locate device**
|
|
2390
2390
|
|
|
2391
|
-
Use the `Locate` button (play icon) to start a Hue identify session for the selected resource. While the session is active the button switches to a stop icon and the bridge makes the light
|
|
2391
|
+
Use the `Locate` button (play icon) to start a Hue identify session for the selected resource. While the session is active the button switches to a stop icon and the bridge makes the light - or every light in the grouped resource - blink once per second. Press the button again to stop immediately; otherwise the session ends automatically after 10 minutes.
|
|
2392
2392
|
|
|
2393
2393
|
<br/>
|
|
2394
2394
|
|
|
@@ -2445,7 +2445,7 @@ Start typing in the GA field (name or Group Address); suggestions appear while y
|
|
|
2445
2445
|
| Status S %| The light color saturation status group address.|
|
|
2446
2446
|
| Dim Speed (ms) | The dimming speed, in Milliseconds, from bottom to top scale. |
|
|
2447
2447
|
|
|
2448
|
-
For controlling the HSV "V
|
|
2448
|
+
For controlling the HSV "V" (brightness), use the standard controls under the **Dim** tab.
|
|
2449
2449
|
|
|
2450
2450
|
<br/>
|
|
2451
2451
|
|
|
@@ -2487,4 +2487,4 @@ Use the **Hue native effects** table to map your KNX values to the effects suppo
|
|
|
2487
2487
|
The Dimming function works in **KNX mode `start` and`stop` ** . To start dimming, send only one "start" KNX telegram. To stop dimming, send a "stop" KNX telegram. Please**remember that** , when you set your wall swiches properties.
|
|
2488
2488
|
|
|
2489
2489
|
<br/>
|
|
2490
|
-
</script>
|
|
2490
|
+
</script>
|
|
@@ -248,7 +248,7 @@ module.exports = function (RED) {
|
|
|
248
248
|
|
|
249
249
|
// This function is called by the hue-config.js
|
|
250
250
|
node.handleSend = (msg) => {
|
|
251
|
-
if (node.currentHUEDevice === undefined && node.serverHue
|
|
251
|
+
if (node.currentHUEDevice === undefined && node.serverHue?.linkStatus === 'connected') {
|
|
252
252
|
node.setNodeStatusHue({
|
|
253
253
|
fill: 'yellow',
|
|
254
254
|
shape: 'ring',
|