iobroker.sprinklecontrol 0.2.17 → 0.2.19
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 +6 -11
- package/admin/i18n/de/translations.json +2 -1
- package/admin/i18n/en/translations.json +1 -0
- package/admin/i18n/es/translations.json +2 -1
- package/admin/i18n/fr/translations.json +2 -1
- package/admin/i18n/it/translations.json +2 -1
- package/admin/i18n/nl/translations.json +2 -1
- package/admin/i18n/pl/translations.json +2 -1
- package/admin/i18n/pt/translations.json +2 -1
- package/admin/i18n/ru/translations.json +2 -1
- package/admin/i18n/uk/translations.json +2 -1
- package/admin/i18n/zh-cn/translations.json +2 -1
- package/admin/index_m.html +5 -0
- package/admin/words.js +1 -0
- package/io-package.json +28 -27
- package/lib/valveControl.js +43 -32
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -33,6 +33,12 @@ Wetterabhängige automatische Steuerung der Gartenbewässerung
|
|
|
33
33
|
Placeholder for the next version (at the beginning of the line):
|
|
34
34
|
### **WORK IN PROGRESS**
|
|
35
35
|
-->
|
|
36
|
+
### 0.2.19 (2025-07-02)
|
|
37
|
+
* (Dirk-Peter-md) The switch-on hysteresis of the cistern is now stored in the configuration.
|
|
38
|
+
|
|
39
|
+
### 0.2.18 (2025-06-30)
|
|
40
|
+
* (Dirk-Peter-md) Hysteresis switch-on value of the cistern changed to 20%
|
|
41
|
+
|
|
36
42
|
### 0.2.17 (2025-06-15)
|
|
37
43
|
* (Dirk-Peter-md) Valve timing corrected
|
|
38
44
|
|
|
@@ -44,17 +50,6 @@ Wetterabhängige automatische Steuerung der Gartenbewässerung
|
|
|
44
50
|
* (Dirk-Peter-md) Fixed an error when switching off with autoOnOff
|
|
45
51
|
* (Dirk-Peter-md) ioBroker-Bot [W028]
|
|
46
52
|
|
|
47
|
-
### 0.2.14 (2025-03-15)
|
|
48
|
-
* (Dirk-Peter-md) eslint-config added
|
|
49
|
-
* (Dirk-Peter-md) Dependencies updated
|
|
50
|
-
* (Dirk-Peter-md) Update License
|
|
51
|
-
* (Dirk-Peter-md) issue #92 Sprinkler im Gewächshaus solved
|
|
52
|
-
* (Dirk-Peter-md) add Button control.autoStart
|
|
53
|
-
|
|
54
|
-
### 0.2.13 (2022-09-06)
|
|
55
|
-
* (Dirk-Peter-md) various bugs fixed
|
|
56
|
-
* (Dirk-Peter-md) Preparing the stable release
|
|
57
|
-
|
|
58
53
|
## License
|
|
59
54
|
MIT License
|
|
60
55
|
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "Beginnen Sie mit einer festen Startzeit",
|
|
133
133
|
"weather forecast service": "Wettervorhersagedienst",
|
|
134
134
|
"Lead time of the main pump in s": "Vorlaufzeit der Hauptpumpe in s",
|
|
135
|
-
"Lead time of the cistern pump in s": "Vorlaufzeit der Zisternepumpe in s"
|
|
135
|
+
"Lead time of the cistern pump in s": "Vorlaufzeit der Zisternepumpe in s",
|
|
136
|
+
"Switch-on hysteresis in %": "Einschalthysterese in %"
|
|
136
137
|
}
|
|
@@ -82,6 +82,7 @@
|
|
|
82
82
|
"Start, with external signal": "Start, with external signal",
|
|
83
83
|
"Starting conditions": "Starting conditions",
|
|
84
84
|
"Sunday": "Sunday",
|
|
85
|
+
"Switch-on hysteresis in %": "Switch-on hysteresis in %",
|
|
85
86
|
"Switch-on point (soil moisture) of the additional irrigation valves in %": "Switch-on point (soil moisture) of the additional irrigation valves in %",
|
|
86
87
|
"Switch-on point (soil moisture) of the irrigation valves in %": "Switch-on point (soil moisture) of the irrigation valves in %",
|
|
87
88
|
"Switch-on point for watering": "Switch-on point for watering",
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "comenzar con una hora de inicio fija",
|
|
133
133
|
"weather forecast service": "servicio de pronóstico del tiempo",
|
|
134
134
|
"Lead time of the main pump in s": "Tiempo de entrega de la bomba principal en S",
|
|
135
|
-
"Lead time of the cistern pump in s": "Tiempo de entrega de la bomba de cisterna en S"
|
|
135
|
+
"Lead time of the cistern pump in s": "Tiempo de entrega de la bomba de cisterna en S",
|
|
136
|
+
"Switch-on hysteresis in %": "Histéresis de encendido en %"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "commencer avec une heure de début fixe",
|
|
133
133
|
"weather forecast service": "service de prévisions météorologiques",
|
|
134
134
|
"Lead time of the main pump in s": "Temps de livraison de la pompe principale en s",
|
|
135
|
-
"Lead time of the cistern pump in s": "Temps de livraison de la pompe de la citerne en s"
|
|
135
|
+
"Lead time of the cistern pump in s": "Temps de livraison de la pompe de la citerne en s",
|
|
136
|
+
"Switch-on hysteresis in %": "Hystérésis de réaction dans%"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "iniziare con un orario di inizio fisso",
|
|
133
133
|
"weather forecast service": "servizio di previsioni del tempo",
|
|
134
134
|
"Lead time of the main pump in s": "Tempo di consegna della pompa principale in s",
|
|
135
|
-
"Lead time of the cistern pump in s": "Tempo di consegna della pompa di cisterna in s"
|
|
135
|
+
"Lead time of the cistern pump in s": "Tempo di consegna della pompa di cisterna in s",
|
|
136
|
+
"Switch-on hysteresis in %": "Isteresi di accensione in %"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "begin met een vaste starttijd",
|
|
133
133
|
"weather forecast service": "weersvoorspellingsservice",
|
|
134
134
|
"Lead time of the main pump in s": "Doorlooptijd van de hoofdpomp in S",
|
|
135
|
-
"Lead time of the cistern pump in s": "Doorlooptijd van de reserveurpomp in S"
|
|
135
|
+
"Lead time of the cistern pump in s": "Doorlooptijd van de reserveurpomp in S",
|
|
136
|
+
"Switch-on hysteresis in %": "Schakel hysterese in % in"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "zacznij od ustalonego czasu rozpoczęcia",
|
|
133
133
|
"weather forecast service": "usługa prognozy pogody",
|
|
134
134
|
"Lead time of the main pump in s": "Czas realizacji pompy głównej w s",
|
|
135
|
-
"Lead time of the cistern pump in s": "Czas realizacji pompy cysterna w s"
|
|
135
|
+
"Lead time of the cistern pump in s": "Czas realizacji pompy cysterna w s",
|
|
136
|
+
"Switch-on hysteresis in %": "Histereza przełączania w %"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "comece com um horário de início fixo",
|
|
133
133
|
"weather forecast service": "serviço de previsão do tempo",
|
|
134
134
|
"Lead time of the main pump in s": "Líder do tempo da bomba principal em S",
|
|
135
|
-
"Lead time of the cistern pump in s": "Líder do tempo da bomba cisterna em S"
|
|
135
|
+
"Lead time of the cistern pump in s": "Líder do tempo da bomba cisterna em S",
|
|
136
|
+
"Switch-on hysteresis in %": "HISTERESESES EXPUTADAS EM %"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "начать с фиксированного времени начала",
|
|
133
133
|
"weather forecast service": "служба прогноза погоды",
|
|
134
134
|
"Lead time of the main pump in s": "Время выполнения основного насоса в s",
|
|
135
|
-
"Lead time of the cistern pump in s": "Время заказа цистернного насоса в s"
|
|
135
|
+
"Lead time of the cistern pump in s": "Время заказа цистернного насоса в s",
|
|
136
|
+
"Switch-on hysteresis in %": "Включение гистерезиса в %"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "почати з фіксованим часом початку",
|
|
133
133
|
"weather forecast service": "служба прогнозу погоди",
|
|
134
134
|
"Lead time of the main pump in s": "Час виконання головного насоса в S",
|
|
135
|
-
"Lead time of the cistern pump in s": "Час виконання цистернного насоса в s"
|
|
135
|
+
"Lead time of the cistern pump in s": "Час виконання цистернного насоса в s",
|
|
136
|
+
"Switch-on hysteresis in %": "Гістерезис перемикання в %"
|
|
136
137
|
}
|
|
@@ -132,5 +132,6 @@
|
|
|
132
132
|
"start with a fixed start time": "从固定的开始时间开始",
|
|
133
133
|
"weather forecast service": "天气预报服务",
|
|
134
134
|
"Lead time of the main pump in s": "主泵的交货时间",
|
|
135
|
-
"Lead time of the cistern pump in s": "s泵的交货时间"
|
|
135
|
+
"Lead time of the cistern pump in s": "s泵的交货时间",
|
|
136
|
+
"Switch-on hysteresis in %": "以%的切换滞后"
|
|
136
137
|
}
|
package/admin/index_m.html
CHANGED
|
@@ -200,6 +200,11 @@
|
|
|
200
200
|
<input type="number" class="value" id="triggerMinCisternLevel" min=0 max=100 placeholder="0-100" step="5" />
|
|
201
201
|
<label for="triggerMinCisternLevel" class="translate"></label>
|
|
202
202
|
<span class="translate">Minimum fill level of the cysts in %</span>
|
|
203
|
+
</div>
|
|
204
|
+
<div class="col s6 m4 l2 input-field">
|
|
205
|
+
<input type="number" class="value" id="switchOnLevelCistern" min=5 max=100 placeholder="5-100" step="5" value="10" />
|
|
206
|
+
<label for="switchOnLevelCistern" class="translate"></label>
|
|
207
|
+
<span class="translate">Switch-on hysteresis in %</span>
|
|
203
208
|
</div>
|
|
204
209
|
</div>
|
|
205
210
|
</div>
|
package/admin/words.js
CHANGED
|
@@ -142,4 +142,5 @@ systemDictionary = {
|
|
|
142
142
|
"weather forecast service": { "en": "weather forecast service", "de": "Wettervorhersagedienst", "ru": "служба прогноза погоды", "pt": "serviço de previsão do tempo", "nl": "weersvoorspellingsservice", "fr": "service de prévisions météorologiques", "it": "servizio di previsioni del tempo", "es": "servicio de pronóstico del tiempo", "pl": "usługa prognozy pogody", "uk": "служба прогнозу погоди", "zh-cn": "天气预报服务"},
|
|
143
143
|
"Lead time of the main pump in s": { "en": "Lead time of the main pump in s", "de": "Vorlaufzeit der Hauptpumpe in s", "ru": "Время выполнения основного насоса в s", "pt": "Líder do tempo da bomba principal em S", "nl": "Doorlooptijd van de hoofdpomp in S", "fr": "Temps de livraison de la pompe principale en s", "it": "Tempo di consegna della pompa principale in s", "es": "Tiempo de entrega de la bomba principal en S", "pl": "Czas realizacji pompy głównej w s", "uk": "Час виконання головного насоса в S", "zh-cn": "主泵的交货时间"},
|
|
144
144
|
"Lead time of the cistern pump in s": { "en": "Lead time of the cistern pump in s", "de": "Vorlaufzeit der Zisternepumpe in s", "ru": "Время заказа цистернного насоса в s", "pt": "Líder do tempo da bomba cisterna em S", "nl": "Doorlooptijd van de reserveurpomp in S", "fr": "Temps de livraison de la pompe de la citerne en s", "it": "Tempo di consegna della pompa di cisterna in s", "es": "Tiempo de entrega de la bomba de cisterna en S", "pl": "Czas realizacji pompy cysterna w s", "uk": "Час виконання цистернного насоса в s", "zh-cn": "s泵的交货时间"},
|
|
145
|
+
"Switch-on hysteresis in %": { "en": "Switch-on hysteresis in %", "de": "Einschalthysterese in %", "ru": "Включение гистерезиса в %", "pt": "HISTERESESES EXPUTADAS EM %", "nl": "Schakel hysterese in % in", "fr": "Hystérésis de réaction dans%", "it": "Isteresi di accensione in %", "es": "Histéresis de encendido en %", "pl": "Histereza przełączania w %", "uk": "Гістерезис перемикання в %", "zh-cn": "以%的切换滞后"},
|
|
145
146
|
};
|
package/io-package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"common": {
|
|
3
3
|
"name": "sprinklecontrol",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.19",
|
|
5
5
|
"titleLang": {
|
|
6
6
|
"en": "Sprinkler Control",
|
|
7
7
|
"de": "Sprinklersteuerung",
|
|
@@ -19,6 +19,32 @@
|
|
|
19
19
|
"Dirk Peter <dirk.peter@freenet.de>"
|
|
20
20
|
],
|
|
21
21
|
"news": {
|
|
22
|
+
"0.2.19": {
|
|
23
|
+
"en": "The switch-on hysteresis of the cistern is now stored in the configuration.",
|
|
24
|
+
"de": "Die Einschalthysterese der Zisterne wird nun in der Konfiguration gespeichert.",
|
|
25
|
+
"ru": "Гистерезис цистерны теперь хранится в конфигурации.",
|
|
26
|
+
"pt": "A histerese da cisterna é agora armazenada na configuração.",
|
|
27
|
+
"nl": "De inschakelhysterese van de cisterne wordt nu opgeslagen in de configuratie.",
|
|
28
|
+
"fr": "L'hystérie de la citerne est maintenant stockée dans la configuration.",
|
|
29
|
+
"it": "L'isteresi di commutazione della cisterna è ora memorizzata nella configurazione.",
|
|
30
|
+
"es": "La histeresis de la cisterna se almacena ahora en la configuración.",
|
|
31
|
+
"pl": "Przełączanie hysterezy cysterny jest teraz przechowywane w konfiguracji.",
|
|
32
|
+
"uk": "У конфігурації тепер зберігається комутаційний гістерезис цистерни.",
|
|
33
|
+
"zh-cn": "晶体的开关式歇斯底里现保存在配置中."
|
|
34
|
+
},
|
|
35
|
+
"0.2.18": {
|
|
36
|
+
"en": "Hysteresis switch-on value of the cistern changed to 20%",
|
|
37
|
+
"de": "Hysterese Einschaltwert der Zisterne auf 20% geändert",
|
|
38
|
+
"ru": "Значение Hysteresis switch-on цистерны изменилось до 20%",
|
|
39
|
+
"pt": "O valor da histerese da cisterna mudou para 20%",
|
|
40
|
+
"nl": "Hysterese schakelaar waarde van de cisterne veranderd in 20%",
|
|
41
|
+
"fr": "La valeur d'activation de l'hystérie de la citerne est passée à 20%",
|
|
42
|
+
"it": "Il valore di commutazione della cisterna di Hysteresis è cambiato al 20%",
|
|
43
|
+
"es": "El valor de conmutación de la histeria cambió al 20%",
|
|
44
|
+
"pl": "Zmiana wartości hysterezy cysterny na 20%",
|
|
45
|
+
"uk": "Гістерез змінився на 20%",
|
|
46
|
+
"zh-cn": "贮器的开关值改为20%"
|
|
47
|
+
},
|
|
22
48
|
"0.2.17": {
|
|
23
49
|
"en": "Valve timing corrected",
|
|
24
50
|
"de": "Ventilzeit korrigiert",
|
|
@@ -83,32 +109,6 @@
|
|
|
83
109
|
"pl": "różne trąbki ustalono; Preparowanie stabilnego wydania",
|
|
84
110
|
"uk": "виправлено різні помилки; Підготовка стабільного випуску",
|
|
85
111
|
"zh-cn": "(a) 固定地点; 准备稳定释放"
|
|
86
|
-
},
|
|
87
|
-
"0.2.12": {
|
|
88
|
-
"en": "fixDay(twoNd,threeRd) => postpone by one day; Bug fixed => autoOn; Additional post-watering => in case of high evaporation / switchable externally",
|
|
89
|
-
"de": "fixDay(twoNd,threeRd) => Verschiebung um einen Tag; Bug fix => autoOn; Zusätzliche Nachbewässerung => bei hoher Verdampfung / schaltbar extern",
|
|
90
|
-
"ru": "fixDay(дваNd,триRd) => откладываться на один день; Bug Fixed => autoOn; Дополнительный пост-вода => в случае высокой испарения / переключаемый внешне",
|
|
91
|
-
"pt": "fixDay(twoNd,threeRd) => adiar por um dia; Bug corrigido => autoOn; Post-watering adicional => em caso de alta evaporação / comutável externamente",
|
|
92
|
-
"nl": "fixDay(tweeNd,drieRd) => één dag uitstellen; Bug opgelost => autoAan; Extra nabewatering => bij hoge verdamping / extern schakelbaar",
|
|
93
|
-
"fr": "correctionDay(twoNd, threeRd) = repousser d'un jour; Bug corrigé = vaccin autoOn; Additionnel post-arrosage = clinique en cas d'évaporation élevée / commutable extérieurement",
|
|
94
|
-
"it": "fixDay(twoNd,treRd) => rinviare entro un giorno; Bug fisso => autoOn; Ulteriori post-irrigazione => in caso di alta evaporazione / commutabile esternamente",
|
|
95
|
-
"es": "fixDay(twoNd,threeRd) = confianza posponer por un día; Bug fijo = prenda autoOn; Pos-aguas adicionales = prenda en caso de alta evaporación / conmutable externamente",
|
|
96
|
-
"pl": "fixDay(twoNd, tripleRd) =>. Odroczony przez jeden dzień; Bug fixed => autoOn; dodatkowy post-watering => w przypadku dużego odparowania i przełącznika zewnętrznego",
|
|
97
|
-
"uk": "fixDay(twoNd,threeRd) => відкласти на один день; Виправлено помилку => autoOn; Додатковий дополив => у разі високого випаровування / перемикається зовні",
|
|
98
|
-
"zh-cn": "fix Day(两名Nd,三Rd)=> 一天推迟;Bug固定=汽车;额外的水事后=在高度疏散/外部可转换的情况下。"
|
|
99
|
-
},
|
|
100
|
-
"0.2.11": {
|
|
101
|
-
"en": "Bug fixed => analogue soil moisture sensor with negative characteristic; Attention => maximum soil moisture in rain now in %",
|
|
102
|
-
"de": "Fehler behoben => analoger Bodenfeuchtesensor mit negativer Kennlinie; Achtung => maximale Bodenfeuchte bei Regen jetzt in %",
|
|
103
|
-
"ru": "Исправлена ошибка => аналоговый датчик влажности почвы с отрицательной характеристикой; Внимание => максимальная влажность почвы в дождь теперь в %",
|
|
104
|
-
"pt": "Bug corrigido => sensor analógico de umidade do solo com característica negativa; Atenção => umidade máxima do solo na chuva agora em %",
|
|
105
|
-
"nl": "Bug opgelost => analoge bodemvochtsensor met negatieve karakteristiek; Let op => maximale bodemvochtigheid bij regen nu in %",
|
|
106
|
-
"fr": "Bug corrigé => capteur d'humidité du sol analogique avec caractéristique négative ; Attention => humidité maximale du sol sous la pluie maintenant en %",
|
|
107
|
-
"it": "Bug risolto => sensore di umidità del suolo analogico con caratteristica negativa; Attenzione => umidità massima del suolo sotto la pioggia ora in %",
|
|
108
|
-
"es": "Error solucionado => sensor de humedad del suelo analógico con característica negativa; Atención => humedad máxima del suelo en lluvia ahora en %",
|
|
109
|
-
"pl": "Poprawiony błąd => analogowy czujnik wilgotności gleby o charakterystyce ujemnej; Uwaga => maksymalna wilgotność gleby w deszczu teraz w %",
|
|
110
|
-
"uk": "Виправлено помилку => аналоговий датчик вологості ґрунту з негативною характеристикою; Увага => максимальна вологість ґрунту під час дощу зараз у %",
|
|
111
|
-
"zh-cn": "错误修复 => 具有负特性的模拟土壤湿度传感器;注意 => 现在雨中的最大土壤水分百分比"
|
|
112
112
|
}
|
|
113
113
|
},
|
|
114
114
|
"desc": {
|
|
@@ -179,6 +179,7 @@
|
|
|
179
179
|
"cisternPumpLeadTime": "10",
|
|
180
180
|
"actualValueLevel": "",
|
|
181
181
|
"triggerMinCisternLevel": "25",
|
|
182
|
+
"switchOnLevelCistern": "10",
|
|
182
183
|
"wateringStartTime": "livingGoldenHourEnd",
|
|
183
184
|
"timeShift": "0",
|
|
184
185
|
"weekLiving": "06:30",
|
package/lib/valveControl.js
CHANGED
|
@@ -498,11 +498,23 @@ function updateList () {
|
|
|
498
498
|
* → Festlegen der aktuellen Pumpe zur Bewässerung
|
|
499
499
|
*/
|
|
500
500
|
function setActualPump () {
|
|
501
|
+
let switchOnLevelCistern = (parseFloat(adapter.config.triggerMinCisternLevel) + parseFloat(adapter.config.switchOnLevelCistern)) || 5;
|
|
502
|
+
if (switchOnLevelCistern > 100) {
|
|
503
|
+
switchOnLevelCistern = 100;
|
|
504
|
+
adapter.log.info(`Switch-on point limited to 100%`);
|
|
505
|
+
}
|
|
506
|
+
if (switchOnLevelCistern < 5) {
|
|
507
|
+
switchOnLevelCistern = 5;
|
|
508
|
+
adapter.log.info(`Switch-on point increased to 5%`);
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
/* Zisternen-Bewässerung Einstellung in der config (2. Pumpe) aktiviert */
|
|
501
512
|
if (adapter.config.cisternSettings === true) {
|
|
502
|
-
/* Zisternen-Bewässerung Einstellung in der config (2. Pumpe) aktiviert */
|
|
503
513
|
if (currentPumpUse.enable === true) {
|
|
504
514
|
/* Bewässerungspumpen aktiv */
|
|
505
|
-
if ((fillLevelCistern < parseFloat(adapter.config.triggerMinCisternLevel))
|
|
515
|
+
if ((fillLevelCistern < parseFloat(adapter.config.triggerMinCisternLevel))
|
|
516
|
+
&& (currentPumpUse.pumpCistern === true)
|
|
517
|
+
) {
|
|
506
518
|
/* (Zisterne unter Minimum) && (ZisternenPumpe läuft) */
|
|
507
519
|
adapter.setForeignState(currentPumpUse.pumpName, {
|
|
508
520
|
val: false,
|
|
@@ -523,44 +535,33 @@ function setActualPump () {
|
|
|
523
535
|
updateList(); // Wasserverbrauch an Pumpenleistung anpassen
|
|
524
536
|
}
|
|
525
537
|
if (fillLevelCistern < parseFloat(adapter.config.triggerMinCisternLevel)) {
|
|
526
|
-
statusCistern = `Cistern empty: ${fillLevelCistern} % (${
|
|
527
|
-
adapter.setState('info.cisternState', {
|
|
528
|
-
val: statusCistern,
|
|
529
|
-
ack: true
|
|
530
|
-
});
|
|
538
|
+
statusCistern = `Cistern empty: ${fillLevelCistern} % (${switchOnLevelCistern} %)`;
|
|
531
539
|
} else {
|
|
532
540
|
statusCistern = `Cistern filled: ${fillLevelCistern} % (${adapter.config.triggerMinCisternLevel} %)`;
|
|
533
|
-
adapter.setState('info.cisternState', {
|
|
534
|
-
val: statusCistern,
|
|
535
|
-
ack: true
|
|
536
|
-
});
|
|
537
541
|
}
|
|
538
542
|
} else {
|
|
539
543
|
/* Bewässerungspumpen inaktiv */
|
|
540
|
-
if ((fillLevelCistern >=
|
|
544
|
+
if ((fillLevelCistern >= switchOnLevelCistern)
|
|
545
|
+
&& (adapter.config.triggerCisternPump)
|
|
546
|
+
&& (adapter.config.triggerCisternPumpPower)
|
|
547
|
+
) {
|
|
541
548
|
/* Zisterne voll && triggerCisternPump && triggerCisternPumpPower vorhanden*/
|
|
542
549
|
statusCistern = `Cistern filled: ${fillLevelCistern} % (${adapter.config.triggerMinCisternLevel} %)`;
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
550
|
+
if (currentPumpUse.pumpCistern === false
|
|
551
|
+
&& !sendMessageText.onlySendError()
|
|
552
|
+
) {
|
|
553
|
+
currentPumpUse.pumpCistern = true;
|
|
554
|
+
currentPumpUse.pumpName = adapter.config.triggerCisternPump || '';
|
|
555
|
+
currentPumpUse.pumpPower = parseInt(adapter.config.triggerCisternPumpPower);
|
|
556
|
+
currentPumpUse.leadTime = parseInt(adapter.config.cisternPumpLeadTime)*1000 || 1000;
|
|
557
|
+
adapter.setState('control.restFlow', {
|
|
558
|
+
val: `${currentPumpUse.pumpPower} (${currentPumpUse.pumpPower} Zisterne)`,
|
|
559
|
+
ack: true
|
|
560
|
+
});
|
|
548
561
|
sendMessageText.sendMessage(`Cistern filled: ${fillLevelCistern} % (${adapter.config.triggerMinCisternLevel} %)`);
|
|
549
562
|
}
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
currentPumpUse.pumpPower = parseInt(adapter.config.triggerCisternPumpPower);
|
|
553
|
-
currentPumpUse.leadTime = parseInt(adapter.config.cisternPumpLeadTime)*1000 || 1000;
|
|
554
|
-
adapter.setState('control.restFlow', {
|
|
555
|
-
val: `${currentPumpUse.pumpPower} (${currentPumpUse.pumpPower} Zisterne)`,
|
|
556
|
-
ack: true
|
|
557
|
-
});
|
|
558
|
-
} else {
|
|
559
|
-
statusCistern = `Cistern empty: ${fillLevelCistern} % (${adapter.config.triggerMinCisternLevel + 5} %)`;
|
|
560
|
-
adapter.setState('info.cisternState', {
|
|
561
|
-
val: statusCistern,
|
|
562
|
-
ack: true
|
|
563
|
-
});
|
|
563
|
+
} else if (fillLevelCistern < parseFloat(adapter.config.triggerMinCisternLevel)) {
|
|
564
|
+
statusCistern = `Cistern empty: ${fillLevelCistern} % (${switchOnLevelCistern} %)`;
|
|
564
565
|
currentPumpUse.pumpCistern = false;
|
|
565
566
|
currentPumpUse.pumpName = adapter.config.triggerMainPump || '';
|
|
566
567
|
currentPumpUse.pumpPower = parseInt(adapter.config.triggerMainPumpPower);
|
|
@@ -569,12 +570,22 @@ function setActualPump () {
|
|
|
569
570
|
val: `${currentPumpUse.pumpPower} (${currentPumpUse.pumpPower} Grundwasser)`,
|
|
570
571
|
ack: true
|
|
571
572
|
});
|
|
573
|
+
} else {
|
|
574
|
+
if (currentPumpUse.pumpCistern === true) {
|
|
575
|
+
statusCistern = `Cistern filled: ${fillLevelCistern} % (${adapter.config.triggerMinCisternLevel} %)`;
|
|
576
|
+
} else {
|
|
577
|
+
statusCistern = `Cistern empty: ${fillLevelCistern} % (${switchOnLevelCistern} %)`;
|
|
578
|
+
}
|
|
572
579
|
}
|
|
580
|
+
adapter.setState('info.cisternState', {
|
|
581
|
+
val: statusCistern,
|
|
582
|
+
ack: true
|
|
583
|
+
});
|
|
573
584
|
}
|
|
574
585
|
} else {
|
|
575
586
|
/* Pumpe AUS => Zisternen-Bewässerung nicht aktiviert */
|
|
576
587
|
if (adapter.config.triggerCisternPump) {
|
|
577
|
-
statusCistern = `Cistern settings are not active!${(fillLevelCistern > 0)?(` level sensor: ${fillLevelCistern}
|
|
588
|
+
statusCistern = `Cistern settings are not active!${(fillLevelCistern > 0)?(` level sensor: ${fillLevelCistern} % ${(adapter.config.triggerMinCisternLevel !== '')?(`${adapter.config.triggerMinCisternLevel} %`):('')}`):('')}`;
|
|
578
589
|
adapter.setState('info.cisternState', {
|
|
579
590
|
val: statusCistern,
|
|
580
591
|
ack: true
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iobroker.sprinklecontrol",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.19",
|
|
4
4
|
"description": "Control of several sprinklers depending on weather conditions and pump performance.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Dirk Peter",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"@iobroker/testing": "^5.0.4",
|
|
44
44
|
"chai": "^5.2.0",
|
|
45
45
|
"chai-as-promised": "^8.0.1",
|
|
46
|
-
"mocha": "^11.
|
|
46
|
+
"mocha": "^11.7.1",
|
|
47
47
|
"sinon": "^21.0.0",
|
|
48
48
|
"sinon-chai": "^4.0.0"
|
|
49
49
|
},
|