From d6f6894dcd8c0ffc98db00a60a6f8b7fc741fcd4 Mon Sep 17 00:00:00 2001 From: Marc Plogas Date: Sun, 8 Sep 2024 22:30:33 +0200 Subject: [PATCH] huh wild. the main part of the pr was missing :D --- .../Mapping/ApiDataExtension.cs | 13 ++++++++++--- src/Ecowitt.Controller/appsettings.json | 15 ++------------- 2 files changed, 12 insertions(+), 16 deletions(-) diff --git a/src/Ecowitt.Controller/Mapping/ApiDataExtension.cs b/src/Ecowitt.Controller/Mapping/ApiDataExtension.cs index f8814ae..0522aba 100644 --- a/src/Ecowitt.Controller/Mapping/ApiDataExtension.cs +++ b/src/Ecowitt.Controller/Mapping/ApiDataExtension.cs @@ -319,15 +319,22 @@ public static Gateway Map(this GatewayApiData gatewayApiData, bool isMetric = tr double value; double maxVoltage; double minVoltage; + + /* + * + wh90batt - voltage of the AA batteries + ws90cap_volt - voltage of the capacitor battery (solar charged) + + */ if (propertyName.Equals("wh90batt", StringComparison.InvariantCultureIgnoreCase)) { - maxVoltage = 5.3; - minVoltage = 2.0; + maxVoltage = 3.0; + minVoltage = 2.2; value = doubleVal / 100; } else { - minVoltage = 1.2; + minVoltage = 1.1; maxVoltage = 1.5; value = doubleVal / 10; } diff --git a/src/Ecowitt.Controller/appsettings.json b/src/Ecowitt.Controller/appsettings.json index 46d4524..15f0ba4 100644 --- a/src/Ecowitt.Controller/appsettings.json +++ b/src/Ecowitt.Controller/appsettings.json @@ -13,25 +13,14 @@ "user": "", "password": "", "port": 1883, - "basetopic": "ecowitt-dev", + "basetopic": "ec-dev", "clientId": "ecowitt-controller", "reconnect": true, "reconnectAttemps": 5 }, "ecowitt": { "pollingInterval": 3, - "autodiscovery": true, - "retries": 2, - "gateways": [ - { - "name": "Garten", - "ip": "192.168.103.162" - }, - { - "name": "Haus", - "ip": "192.168.103.241" - } - ] + "autodiscovery": true }, "controller": { "precision": 2,