iobroker.device-watcher 0.2.0 → 0.2.1
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 +3 -0
- package/io-package.json +13 -1
- package/main.js +7 -15
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -74,6 +74,9 @@ If you found a bug or you have an improvement suggestion, feel free to open an i
|
|
|
74
74
|
Placeholder for the next version (at the beginning of the line):
|
|
75
75
|
### **WORK IN PROGRESS**
|
|
76
76
|
-->
|
|
77
|
+
### 0.2.1 (2022-07-27)
|
|
78
|
+
- removed test states
|
|
79
|
+
|
|
77
80
|
### 0.2.0 (2022-07-24)
|
|
78
81
|
- added function to create data of each adapter
|
|
79
82
|
|
package/io-package.json
CHANGED
|
@@ -1,8 +1,20 @@
|
|
|
1
1
|
{
|
|
2
2
|
"common": {
|
|
3
3
|
"name": "device-watcher",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.1",
|
|
5
5
|
"news": {
|
|
6
|
+
"0.2.1": {
|
|
7
|
+
"en": "- removed test states",
|
|
8
|
+
"de": "- entfernte testzustände",
|
|
9
|
+
"ru": "- удаленные состояния тестов",
|
|
10
|
+
"pt": "- estados de teste removidos",
|
|
11
|
+
"nl": "verwijderde teststaat",
|
|
12
|
+
"fr": "- états d ' essai enlevés",
|
|
13
|
+
"it": "- stati di test rimossi",
|
|
14
|
+
"es": "- estados de prueba eliminados",
|
|
15
|
+
"pl": "- zlikwidowane państwa testowe",
|
|
16
|
+
"zh-cn": "- 取消试验国"
|
|
17
|
+
},
|
|
6
18
|
"0.2.0": {
|
|
7
19
|
"en": "- added function to create data of each adapter",
|
|
8
20
|
"de": "- zusätzliche funktion zur erstellung von daten jedes adapters",
|
package/main.js
CHANGED
|
@@ -43,11 +43,6 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
43
43
|
|
|
44
44
|
// arrays of supported adapters
|
|
45
45
|
this.arrApart = {
|
|
46
|
-
//**** This Datapoints are only for the dev ****//
|
|
47
|
-
test: {'Selektor':'0_userdata.*.UNREACH', 'adapter':'homematic', 'rssiState':'.RSSI_DEVICE', 'battery':'.OPERATING_VOLTAGE', 'reach':'.UNREACH', 'isLowBat':'.LOW_BAT'},
|
|
48
|
-
test2: {'Selektor':'0_userdata.*.alive', 'adapter':'test2', 'rssiState': '.Wifi_RSSI', 'battery':'none', 'reach':'.alive', 'isLowBat':'none', 'id':'.name'},
|
|
49
|
-
test3: {'Selektor':'0_userdata.*.link_quality', 'adapter':'test3', 'battery':'.battery', 'reach':'available', 'isLowBat':'none'},
|
|
50
|
-
//**** End of Dev Datapoints ****//
|
|
51
46
|
alexa2: {
|
|
52
47
|
'Selektor':'alexa2.*.online',
|
|
53
48
|
'adapter':'alexa2',
|
|
@@ -282,7 +277,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
282
277
|
'role': 'json',
|
|
283
278
|
'read': true,
|
|
284
279
|
'write': false,
|
|
285
|
-
'def': [{Device: '--keine--', Adapter: '', Last_contact: ''}]
|
|
280
|
+
'def': JSON.stringify([{Device: '--keine--', Adapter: '', Last_contact: ''}])
|
|
286
281
|
},
|
|
287
282
|
'native': {}
|
|
288
283
|
});
|
|
@@ -294,7 +289,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
294
289
|
'role': 'json',
|
|
295
290
|
'read': true,
|
|
296
291
|
'write': false,
|
|
297
|
-
'def': [{Device: '--keine--', Adapter: '', Battery: '', Last_contact: '', Link_quality: ''}]
|
|
292
|
+
'def': JSON.stringify([{Device: '--keine--', Adapter: '', Battery: '', Last_contact: '', Link_quality: ''}])
|
|
298
293
|
},
|
|
299
294
|
'native': {}
|
|
300
295
|
});
|
|
@@ -306,7 +301,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
306
301
|
'role': 'json',
|
|
307
302
|
'read': true,
|
|
308
303
|
'write': false,
|
|
309
|
-
'def': [{Device: '--keine--', Adapter: '', Link_quality: ''}]
|
|
304
|
+
'def': JSON.stringify([{Device: '--keine--', Adapter: '', Link_quality: ''}])
|
|
310
305
|
},
|
|
311
306
|
'native': {}
|
|
312
307
|
});
|
|
@@ -330,7 +325,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
330
325
|
'role': 'json',
|
|
331
326
|
'read': true,
|
|
332
327
|
'write': false,
|
|
333
|
-
'def': [{Device: '--keine--', Adapter: '', Battery: ''}]
|
|
328
|
+
'def': JSON.stringify([{Device: '--keine--', Adapter: '', Battery: ''}])
|
|
334
329
|
},
|
|
335
330
|
'native': {}
|
|
336
331
|
});
|
|
@@ -342,7 +337,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
342
337
|
'role': 'json',
|
|
343
338
|
'read': true,
|
|
344
339
|
'write': false,
|
|
345
|
-
'def': [{Device: '--keine--', Adapter: '', Battery: ''}]
|
|
340
|
+
'def': JSON.stringify([{Device: '--keine--', Adapter: '', Battery: ''}])
|
|
346
341
|
},
|
|
347
342
|
'native': {}
|
|
348
343
|
});
|
|
@@ -407,7 +402,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
407
402
|
|
|
408
403
|
//Get ID for Switchbot and ESPHome Devices
|
|
409
404
|
switch (this.arrDev[i].adapter) {
|
|
410
|
-
case '
|
|
405
|
+
case 'switchbotBle':
|
|
411
406
|
case 'esphome':
|
|
412
407
|
deviceName = await this.getInitValue(currDeviceString + this.arrDev[i].id);
|
|
413
408
|
break;
|
|
@@ -827,7 +822,7 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
827
822
|
);
|
|
828
823
|
}
|
|
829
824
|
break;
|
|
830
|
-
case '
|
|
825
|
+
case 'switchbotBle':
|
|
831
826
|
if (this.config.switchbotMaxMinutes === -1) {
|
|
832
827
|
if (!deviceUnreachState) {
|
|
833
828
|
deviceState = 'Offline'; //set online state to offline
|
|
@@ -1094,9 +1089,6 @@ class DeviceWatcher extends utils.Adapter {
|
|
|
1094
1089
|
sonos: this.config.sonosDevices,
|
|
1095
1090
|
mihome: this.config.mihomeDevices,
|
|
1096
1091
|
mihomeGW: this.config.mihomeDevices,
|
|
1097
|
-
test: false, // Only for Developer
|
|
1098
|
-
test2: false, // Only for Developer
|
|
1099
|
-
test3: false // Only for Developer
|
|
1100
1092
|
};
|
|
1101
1093
|
|
|
1102
1094
|
for(const [id] of Object.entries(this.arrApart)) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iobroker.device-watcher",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "Watchdog for wireless devices",
|
|
5
5
|
"author": "Christian Behrends <mail@christian-behrends.de>",
|
|
6
6
|
"homepage": "https://github.com/ciddi89/ioBroker.device-watcher",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
],
|
|
14
14
|
"repository": {
|
|
15
15
|
"type": "git",
|
|
16
|
-
"url": "git
|
|
16
|
+
"url": "git@github.com:ciddi89/ioBroker.device-watcher.git"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@iobroker/adapter-core": "^2.6.0"
|