iobroker.poolcontrol 1.2.19 → 1.2.20

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
@@ -189,8 +189,12 @@ New features are added regularly – please refer to the changelog.
189
189
 
190
190
  ## Changelog
191
191
 
192
- ## 1.2.19 (2026-04-10)
192
+ ### 1.2.20
193
+ Release: 11.04.2026
194
+ - (DasBo) Reduced unnecessary state writes in status and photovoltaic helpers. Summary and PV timestamps are now only updated when the functional result actually changes, making the adapter quieter without affecting existing logic.
193
195
 
196
+ ### 1.2.19
197
+ Release: 10.04.2026
194
198
  - Fixed an interaction issue between `photovoltaicHelper` and `controlHelper` where automatic follow-up pumping could be stopped unexpectedly
195
199
  - photovoltaicHelper now respects controlHelper priority and no longer stops the pump while automatic follow-up pumping is active
196
200
  - Fixed an issue where `controlHelper` could remain in "nachpumpen" state if the pump was stopped externally
package/io-package.json CHANGED
@@ -1,8 +1,21 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "poolcontrol",
4
- "version": "1.2.19",
4
+ "version": "1.2.20",
5
5
  "news": {
6
+ "1.2.20": {
7
+ "en": "Bugfix release. Reduced unnecessary state writes in the status and photovoltaic helpers. Summary timestamps and PV update timestamps are now only written when the related functional result actually changes. This makes the adapter noticeably quieter and avoids needless state updates without changing the existing control logic.",
8
+ "de": "Bugfix-Release. Reduziert unnötige State-Schreibvorgänge im Status- und Photovoltaik-Helper. Summary-Zeitstempel und PV-Aktualisierungszeitstempel werden jetzt nur noch dann geschrieben, wenn sich das zugehörige fachliche Ergebnis tatsächlich ändert. Dadurch arbeitet der Adapter spürbar ruhiger und vermeidet unnötige State-Updates, ohne die bestehende Steuerlogik zu verändern.",
9
+ "ru": "Выпуск с исправлением ошибок. Уменьшено количество ненужных записей в статусе и фотоэлектрических помощниках. Сводные временные метки и временные метки обновления PV теперь записываются только тогда, когда соответствующий функциональный результат действительно изменяется. Это делает адаптер заметно тише и позволяет избежать ненужных обновлений состояния без изменения существующей логики управления.",
10
+ "pt": "Lançamento de correção de bug. Gravações de estado desnecessárias reduzidas nos ajudantes de status e fotovoltaicos. Os carimbos de data e hora de resumo e os carimbos de data e hora de atualização do PV agora são gravados apenas quando o resultado funcional relacionado realmente muda. Isto torna o adaptador visivelmente mais silencioso e evita atualizações de estado desnecessárias sem alterar a lógica de controle existente.",
11
+ "nl": "Bugfix-release. Verminderde onnodige statusschrijven in de status en fotovoltaïsche helpers. Samenvattende tijdstempels en tijdstempels voor PV-updates worden nu alleen geschreven als het gerelateerde functionele resultaat daadwerkelijk verandert. Dit maakt de adapter merkbaar stiller en vermijdt onnodige statusupdates zonder de bestaande besturingslogica te veranderen.",
12
+ "fr": "Version de correction de bugs. Réduction des écritures d'état inutiles dans les aides d'état et photovoltaïques. Les horodatages récapitulatifs et les horodatages de mise à jour PV ne sont désormais écrits que lorsque le résultat fonctionnel associé change réellement. Cela rend l'adaptateur sensiblement plus silencieux et évite les mises à jour d'état inutiles sans modifier la logique de contrôle existante.",
13
+ "it": "Rilascio di correzione bug. Ridotte le scritture di stato non necessarie nello stato e gli aiutanti fotovoltaici. I timestamp di riepilogo e quelli di aggiornamento PV ora vengono scritti solo quando il relativo risultato funzionale cambia effettivamente. Ciò rende l'adattatore notevolmente più silenzioso ed evita aggiornamenti di stato inutili senza modificare la logica di controllo esistente.",
14
+ "es": "Lanzamiento de corrección de errores. Reducción de escrituras de estado innecesarias en el estado y ayudantes fotovoltaicos. Las marcas de tiempo de resumen y las marcas de tiempo de actualización de PV ahora solo se escriben cuando el resultado funcional relacionado realmente cambia. Esto hace que el adaptador sea notablemente más silencioso y evita actualizaciones de estado innecesarias sin cambiar la lógica de control existente.",
15
+ "pl": "Wydanie poprawek błędów. Redukcja zbędnych zapisów stanu w statusie i pomocnikach fotowoltaicznych. Sumaryczne znaczniki czasu i znaczniki czasu aktualizacji PV są teraz zapisywane tylko wtedy, gdy faktycznie zmienia się powiązany wynik funkcjonalny. Dzięki temu adapter jest zauważalnie cichszy i pozwala uniknąć niepotrzebnych aktualizacji stanu bez zmiany istniejącej logiki sterowania.",
16
+ "uk": "Реліз виправлення помилок. Зменшено непотрібні записи стану в статусі та фотоелектричні помічники. Підсумкові мітки часу та мітки часу оновлення PV тепер записуються лише тоді, коли відповідний функціональний результат фактично змінюється. Це робить адаптер помітно тихішим і дозволяє уникнути непотрібних оновлень стану без зміни існуючої логіки керування.",
17
+ "zh-cn": "错误修复版本。减少状态和光伏助手中不必要的状态写入。摘要时间戳和 PV 更新时间戳现在仅在相关功能结果实际更改时写入。这使得适配器明显更安静,并且在不改变现有控制逻辑的情况下避免了不必要的状态更新。"
18
+ },
6
19
  "1.2.19": {
7
20
  "en": "Bugfix release. Fixes an interaction issue between photovoltaicHelper and controlHelper where automatic follow-up pumping could be interrupted unexpectedly. The photovoltaic stop logic now respects controlHelper priority and no longer stops the pump while automatic follow-up pumping is active. In addition, the read-only state photovoltaic.threshold_w is now synchronized correctly with the instance configuration so that changes in the adapter settings are reflected reliably in the visible datapoint.",
8
21
  "de": "Bugfix-Release. Behebt ein Zusammenspielproblem zwischen photovoltaicHelper und controlHelper, durch das automatisches Nachpumpen unerwartet unterbrochen werden konnte. Die Abschaltlogik des PV-Helfers respektiert nun den Vorrang des controlHelper und stoppt die Pumpe nicht mehr, solange automatisches Nachpumpen aktiv ist. Zusätzlich wird der schreibgeschützte Datenpunkt photovoltaic.threshold_w jetzt korrekt mit der Instanzkonfiguration synchronisiert, sodass Änderungen in den Adaptereinstellungen zuverlässig im sichtbaren Datenpunkt übernommen werden.",
@@ -54,19 +67,6 @@
54
67
  "pl": "Napraw użycie i18n (zamień I18n.t na I18n.translate), aby rozwiązać awarię uruchamiania adaptera i pętlę restartu w niektórych systemach.",
55
68
  "uk": "Виправте використання i18n (замініть I18n.t на I18n.translate), щоб усунути збій запуску адаптера та цикл перезапуску в певних системах.",
56
69
  "zh-cn": "修复 i18n 使用情况(将 I18n.t 替换为 I18n.translate),以解决某些系统上的适配器启动崩溃和重新启动循环问题。"
57
- },
58
- "1.2.14": {
59
- "en": "Add i18n support for chemistry help (common.states and help texts), fix React issues caused by invalid translations, and improve multilingual user guidance.",
60
- "de": "i18n-Unterstützung für Chemie-Hilfe hinzugefügt (common.states und Hilfetexte), React-Fehler durch fehlerhafte Übersetzungen behoben und mehrsprachige Benutzerführung verbessert.",
61
- "ru": "Добавьте поддержку i18n для справки по химии (common.states и справочные тексты), исправьте проблемы React, вызванные неверными переводами, и улучшите многоязычное руководство пользователя.",
62
- "pt": "Adicione suporte i18n para ajuda química (common.states e textos de ajuda), corrija problemas do React causados ​​por traduções inválidas e melhore a orientação multilíngue do usuário.",
63
- "nl": "Voeg i18n-ondersteuning toe voor scheikundige hulp (common.states en helpteksten), repareer React-problemen veroorzaakt door ongeldige vertalingen en verbeter de meertalige gebruikersbegeleiding.",
64
- "fr": "Ajoutez la prise en charge d'i18n pour l'aide chimique (common.states et textes d'aide), corrigez les problèmes de React causés par des traductions non valides et améliorez le guidage utilisateur multilingue.",
65
- "it": "Aggiungi il supporto i18n per la guida in chimica (common.states e testi di aiuto), risolvi i problemi di React causati da traduzioni non valide e migliora la guida utente multilingue.",
66
- "es": "Agregue soporte i18n para ayuda sobre química (estados comunes y textos de ayuda), solucione problemas de React causados ​​por traducciones no válidas y mejore la guía del usuario multilingüe.",
67
- "pl": "Dodaj obsługę i18n dla pomocy chemicznej (stany wspólne i teksty pomocy), rozwiąż problemy z React spowodowane nieprawidłowymi tłumaczeniami i ulepsz wielojęzyczne wskazówki dla użytkownika.",
68
- "uk": "Додайте підтримку i18n для довідки з хімії (common.states і тексти довідки), виправте проблеми з React, викликані недійсними перекладами, і покращте багатомовні інструкції для користувачів.",
69
- "zh-cn": "添加对化学帮助(common.states 和帮助文本)的 i18n 支持,修复无效翻译导致的 React 问题,并改进多语言用户指南。"
70
70
  }
71
71
  },
72
72
  "titleLang": {
@@ -130,18 +130,39 @@ const photovoltaicHelper = {
130
130
 
131
131
  // Überschussberechnung
132
132
  const surplus = Math.max(0, gen - house);
133
- await this._updateNumberState('photovoltaic.power_surplus_w', surplus);
134
133
 
135
134
  // **NEU:** Einschaltlogik = Pumpenleistung + Sicherheitsaufschlag
136
135
  const requiredPower = pumpMax + threshold;
137
136
  const surplusActive = surplus >= requiredPower && seasonActive;
138
- await this._updateBoolState('photovoltaic.surplus_active', surplusActive);
139
137
 
140
138
  const txt = surplusActive
141
139
  ? `Überschuss aktiv (${surplus} W ≥ ${pumpMax}+${threshold} W)`
142
140
  : `Kein Überschuss (${surplus} W < ${pumpMax}+${threshold} W)`;
143
- await this._updateStringState('photovoltaic.status_text', txt);
144
- await this._updateStringState('photovoltaic.last_update', new Date().toISOString());
141
+
142
+ // FIX: Bestehende Ergebnisstates zuerst lesen, damit last_update nur bei echter Ergebnisänderung gesetzt wird
143
+ const currentSurplus = Number((await this.adapter.getStateAsync('photovoltaic.power_surplus_w'))?.val ?? 0);
144
+ const currentSurplusActive = !!(await this.adapter.getStateAsync('photovoltaic.surplus_active'))?.val;
145
+ const currentStatusText = (await this.adapter.getStateAsync('photovoltaic.status_text'))?.val ?? '';
146
+
147
+ const surplusChanged = currentSurplus !== surplus;
148
+ const surplusActiveChanged = currentSurplusActive !== surplusActive;
149
+ const statusTextChanged = currentStatusText !== txt;
150
+
151
+ if (surplusChanged) {
152
+ await this._updateNumberState('photovoltaic.power_surplus_w', surplus); // FIX
153
+ }
154
+
155
+ if (surplusActiveChanged) {
156
+ await this._updateBoolState('photovoltaic.surplus_active', surplusActive); // FIX
157
+ }
158
+
159
+ if (statusTextChanged) {
160
+ await this._updateStringState('photovoltaic.status_text', txt); // FIX
161
+ }
162
+
163
+ if (surplusChanged || surplusActiveChanged || statusTextChanged) {
164
+ await this._updateStringState('photovoltaic.last_update', new Date().toISOString()); // FIX
165
+ }
145
166
 
146
167
  // Saison/Modus prüfen
147
168
  if (!seasonActive) {
@@ -229,7 +229,7 @@ const statisticsHelperMonth = {
229
229
  await adapter.setStateAsync(`${basePath}.temp_max`, { val: newMax, ack: true });
230
230
  await adapter.setStateAsync(`${basePath}.temp_avg`, { val: Math.round(newAvg * 100) / 100, ack: true });
231
231
  await adapter.setStateAsync(`${basePath}.data_points_count`, { val: newCount, ack: true });
232
- await adapter.setStateAsync(`${basePath}.last_update`, { val: now, ack: true });
232
+ await adapter.setStateAsync(`${basePath}.last_update`, { val: now, ack: true }); // FIX: Doppelwrite entfernt
233
233
 
234
234
  const summary = {
235
235
  name: 'Monatsstatistik',
@@ -157,16 +157,8 @@ const statusHelper = {
157
157
  }
158
158
  text += `. Tageslaufzeit: ${runtimeFormatted} (${circulationPct}% der Soll-Umwälzung).`;
159
159
 
160
- // In States schreiben (nur bei Änderung)
161
- const current = (await this.adapter.getStateAsync('status.summary'))?.val;
162
- if (current !== text) {
163
- await this.adapter.setStateAsync('status.summary', { val: text, ack: true });
164
- }
165
-
166
- await this.adapter.setStateAsync('status.last_summary_update', {
167
- val: new Date().toISOString(),
168
- ack: true,
169
- });
160
+ // FIX: Bestehende Werte zuerst lesen, damit last_summary_update nur bei echter Änderung gesetzt wird
161
+ const currentSummary = (await this.adapter.getStateAsync('status.summary'))?.val ?? '';
170
162
 
171
163
  // JSON-Übersicht bauen
172
164
  const json = {
@@ -179,10 +171,29 @@ const statusHelper = {
179
171
  runtime_formatted: runtimeFormatted,
180
172
  circulation_pct: circulationPct,
181
173
  };
182
- await this.adapter.setStateAsync('status.overview_json', {
183
- val: JSON.stringify(json),
184
- ack: true,
185
- });
174
+ const overviewJson = JSON.stringify(json);
175
+ const currentOverview = (await this.adapter.getStateAsync('status.overview_json'))?.val ?? '';
176
+
177
+ const summaryChanged = currentSummary !== text;
178
+ const overviewChanged = currentOverview !== overviewJson;
179
+
180
+ if (summaryChanged) {
181
+ await this.adapter.setStateAsync('status.summary', { val: text, ack: true }); // FIX
182
+ }
183
+
184
+ if (overviewChanged) {
185
+ await this.adapter.setStateAsync('status.overview_json', {
186
+ val: overviewJson,
187
+ ack: true,
188
+ }); // FIX
189
+ }
190
+
191
+ if (summaryChanged || overviewChanged) {
192
+ await this.adapter.setStateAsync('status.last_summary_update', {
193
+ val: new Date().toISOString(),
194
+ ack: true,
195
+ }); // FIX: nur bei echter Summary-/Overview-Änderung
196
+ }
186
197
  } catch (err) {
187
198
  this.adapter.log.warn(`[statusHelper] Error while updating summary: ${err.message}`);
188
199
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.poolcontrol",
3
- "version": "1.2.19",
3
+ "version": "1.2.20",
4
4
  "description": "Steuerung & Automatisierung für den Pool (Pumpe, Heizung, Ventile, Sensoren).",
5
5
  "author": "DasBo1975 <dasbo1975@outlook.de>",
6
6
  "homepage": "https://github.com/DasBo1975/ioBroker.poolcontrol",