From 23d551e567d4ea247a6384608da50636399b9eb2 Mon Sep 17 00:00:00 2001 From: Moritz Heusinger Date: Sun, 3 Apr 2022 20:18:55 +0200 Subject: [PATCH] chore: release v3.0.40 * (foxriver76) if LGW is not reachable we now set duty cycle to `null` instead of `-1` --- README.md | 3 +++ io-package.json | 26 +++++++++++++------------- main.js | 8 +++++--- package-lock.json | 8 ++++---- package.json | 4 ++-- 5 files changed, 27 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index 49c6fb7..ceda4ad 100644 --- a/README.md +++ b/README.md @@ -84,6 +84,9 @@ with the ioBroker CLI. You can change the port via `iob set hm-rega. - Placeholder for the next version (at the beginning of the line): ### __WORK IN PROGRESS__ --> +### 3.0.40 (2022-04-03) +* (foxriver76) if LGW is not reachable we now set duty cycle to `null` instead of `-1` + ### 3.0.39 (2022-03-26) * (foxriver76) fixed another `ValueList` bug diff --git a/io-package.json b/io-package.json index 3f02755..010e4c5 100644 --- a/io-package.json +++ b/io-package.json @@ -1,8 +1,20 @@ { "common": { "name": "hm-rega", - "version": "3.0.39", + "version": "3.0.40", "news": { + "3.0.40": { + "en": "if LGW is not reachable we now set duty cycle to `null` instead of `-1`", + "de": "Wenn LGW nicht erreichbar ist, setzen wir jetzt den Arbeitszyklus auf \"Null\" anstelle von \"-1\".", + "ru": "если LGW недоступен, мы теперь устанавливаем рабочий цикл на «ноль» вместо «-1».", + "pt": "se LGW não for alcançável, agora definimos o ciclo de trabalho como `null` em vez de `-1`", + "nl": "als LGW niet bereikbaar is, stellen we de duty cycle nu in op `null` in plaats van `-1`", + "fr": "si LGW n'est pas accessible, nous définissons maintenant le rapport cyclique sur \"null\" au lieu de \"-1\"", + "it": "se LGW non è raggiungibile, ora impostiamo il duty cycle su `null` invece di `-1`", + "es": "si no se puede acceder a LGW, ahora establecemos el ciclo de trabajo en `nulo` en lugar de `-1`", + "pl": "jeśli LGW nie jest osiągalne, ustawiamy teraz cykl pracy na „null” zamiast „-1”", + "zh-cn": "如果无法访问 LGW,我们现在将占空比设置为“空”而不是“-1”" + }, "3.0.39": { "en": "fixed another `ValueList` bug", "de": "Ein weiterer `ValueList`-Bug wurde behoben", @@ -74,18 +86,6 @@ "es": "(martin-herzog/foxriver76) arregló una llamada no necesaria que generaba advertencias en el registro de registro", "pl": "(martin-herzog/foxriver76) naprawiono nieoczekiwane połączenie, które prowadziło do ostrzeżeń w dzienniku rega", "zh-cn": "(martin-herzog/foxriver76) 修复了导致 rega 日志中警告的 unnedded 调用" - }, - "3.0.33": { - "en": "if function or room names on CCU include dots, we replace them (fixes Sentry IOBROKER-HM-REGA-3H)", - "de": "Wenn Funktions- oder Raumnamen auf der CCU Punkte enthalten, ersetzen wir diese (behebt Sentry IOBROKER-HM-REGA-3H)", - "ru": "если в названиях функций или комнат на CCU есть точки, мы их заменяем (исправляет Sentry IOBROKER-HM-REGA-3H)", - "pt": "se os nomes da função ou da sala no CCU incluem pontos, nós os substituímos (corrige o Sentinela IOBROKER-HM-REGA-3H)", - "nl": "als functie- of kamernamen op CCU punten bevatten, vervangen we deze (repareert Sentry IOBROKER-HM-REGA-3H)", - "fr": "si les noms de fonction ou de pièce sur le CCU incluent des points, nous les remplaçons (corrige Sentry IOBROKER-HM-REGA-3H)", - "it": "se i nomi delle funzioni o delle stanze sulla CCU includono punti, li sostituiamo (corregge Sentry IOBROKER-HM-REGA-3H)", - "es": "si los nombres de función o sala en CCU incluyen puntos, los reemplazamos (corrige Sentry IOBROKER-HM-REGA-3H)", - "pl": "jeśli nazwy funkcji lub pomieszczeń na CCU zawierają kropki, zastępujemy je (poprawki Sentry IOBROKER-HM-REGA-3H)", - "zh-cn": "如果 CCU 上的功能或房间名称包含点,我们将替换它们(修复 Sentry IOBROKER-HM-REGA-3H)" } }, "title": "HomeMatic ReGaHSS", diff --git a/main.js b/main.js index 48bddec..3a647ff 100644 --- a/main.js +++ b/main.js @@ -1907,7 +1907,7 @@ async function getDutyCycle() { read: true, write: false, role: 'value', - min: -1, + min: 0, max: 100, unit: '%', desc: 'Dutycycle' @@ -1915,14 +1915,16 @@ async function getDutyCycle() { native: { ID: 'DUTYCYCLE', TYPE: 'INTEGER', - MIN: -1, + MIN: 0, MAX: 100, UNIT: '%', DEFAULT: 0, CONTROL: 'NONE' } }; - await addNewStateOrObject(stateDutycycle, parseInt(dp.DUTY_CYCLE)); + + const dutyCycle = parseInt(dp.DUTY_CYCLE); + await addNewStateOrObject(stateDutycycle, dutyCycle === -1 ? null : dutyCycle); } //CONNECTED State: diff --git a/package-lock.json b/package-lock.json index 4d24bf5..d46f437 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "iobroker.hm-rega", - "version": "3.0.39", + "version": "3.0.40", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -3765,9 +3765,9 @@ "dev": true }, "prettier": { - "version": "2.6.1", - "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.6.1.tgz", - "integrity": "sha512-8UVbTBYGwN37Bs9LERmxCPjdvPxlEowx2urIL6urHzdb3SDq4B/Z6xLFCblrSnE4iKWcS6ziJ3aOYrc1kz/E2A==", + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.6.2.tgz", + "integrity": "sha512-PkUpF+qoXTqhOeWL9fu7As8LXsIUZ1WYaJiY/a7McAQzxjk82OF0tibkFXVCDImZtWxbvojFjerkiLb0/q8mew==", "dev": true }, "prettier-linter-helpers": { diff --git a/package.json b/package.json index 5f15cfd..a3fb765 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "iobroker.hm-rega", - "version": "3.0.39", + "version": "3.0.40", "engines": { "node": ">=10.0.0" }, @@ -42,7 +42,7 @@ "eslint-plugin-prettier": "^4.0.0", "gulp": "^4.0.2", "mocha": "^9.2.0", - "prettier": "^2.6.1" + "prettier": "^2.6.2" }, "bugs": { "url": "https://github.com/ioBroker/ioBroker.hm-rega/issues"