Skip to content

Commit 90e3ca9

Browse files
authored
Merge pull request #3 from mplogas/issue/1
huh wild. the main part of the pr was missing :D
2 parents ff0c0ad + d6f6894 commit 90e3ca9

File tree

2 files changed

+12
-16
lines changed

2 files changed

+12
-16
lines changed

src/Ecowitt.Controller/Mapping/ApiDataExtension.cs

+10-3
Original file line numberDiff line numberDiff line change
@@ -319,15 +319,22 @@ public static Gateway Map(this GatewayApiData gatewayApiData, bool isMetric = tr
319319
double value;
320320
double maxVoltage;
321321
double minVoltage;
322+
323+
/*
324+
*
325+
wh90batt - voltage of the AA batteries
326+
ws90cap_volt - voltage of the capacitor battery (solar charged)
327+
328+
*/
322329
if (propertyName.Equals("wh90batt", StringComparison.InvariantCultureIgnoreCase))
323330
{
324-
maxVoltage = 5.3;
325-
minVoltage = 2.0;
331+
maxVoltage = 3.0;
332+
minVoltage = 2.2;
326333
value = doubleVal / 100;
327334
}
328335
else
329336
{
330-
minVoltage = 1.2;
337+
minVoltage = 1.1;
331338
maxVoltage = 1.5;
332339
value = doubleVal / 10;
333340
}

src/Ecowitt.Controller/appsettings.json

+2-13
Original file line numberDiff line numberDiff line change
@@ -13,25 +13,14 @@
1313
"user": "",
1414
"password": "",
1515
"port": 1883,
16-
"basetopic": "ecowitt-dev",
16+
"basetopic": "ec-dev",
1717
"clientId": "ecowitt-controller",
1818
"reconnect": true,
1919
"reconnectAttemps": 5
2020
},
2121
"ecowitt": {
2222
"pollingInterval": 3,
23-
"autodiscovery": true,
24-
"retries": 2,
25-
"gateways": [
26-
{
27-
"name": "Garten",
28-
"ip": "192.168.103.162"
29-
},
30-
{
31-
"name": "Haus",
32-
"ip": "192.168.103.241"
33-
}
34-
]
23+
"autodiscovery": true
3524
},
3625
"controller": {
3726
"precision": 2,

0 commit comments

Comments
 (0)