@lv426/homebridge-systemair-enhanced 1.0.5 → 1.0.6
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/index.js +22 -36
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -26,51 +26,37 @@ class SystemairVentilator {
|
|
|
26
26
|
TARGET_TEMP: '2000', // Target temperature setting
|
|
27
27
|
HUMIDITY: '12135', // Current humidity sensor reading
|
|
28
28
|
ECO_MODE: '2504', // Turning ECO mode on / off
|
|
29
|
-
FREE_COOLING: '4100', // Free Cooling activate /
|
|
29
|
+
FREE_COOLING: '4100', // Free Cooling activate / deactiva
|
|
30
30
|
};
|
|
31
31
|
|
|
32
32
|
this.axiosInstance = axios.create({
|
|
33
33
|
timeout: 20000, // 20 seconds timeout
|
|
34
34
|
});
|
|
35
35
|
|
|
36
|
-
//
|
|
37
|
-
this.fanService =
|
|
38
|
-
this.accessory.getService(Service.Fanv2) ??
|
|
39
|
-
this.accessory.addService(Service.Fanv2, `${this.config.name} Fan`);
|
|
40
|
-
|
|
41
|
-
// REFRESH (Switch #1) — add subtype "refresh"
|
|
42
|
-
this.refreshService =
|
|
43
|
-
this.accessory.getServiceById(Service.Switch, 'refresh') ??
|
|
44
|
-
this.accessory.addService(
|
|
45
|
-
Service.Switch,
|
|
46
|
-
`${this.config.name} Refresh`,
|
|
47
|
-
'refresh'
|
|
48
|
-
);
|
|
36
|
+
// Fan service
|
|
37
|
+
this.fanService = new Service.Fanv2(this.config.name + ' Fan');
|
|
49
38
|
|
|
50
|
-
//
|
|
51
|
-
this.
|
|
52
|
-
this.
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
`${this.config.name} Eco Mode`,
|
|
56
|
-
'eco'
|
|
57
|
-
);
|
|
39
|
+
// Refresh service (with subtype for uniqueness)
|
|
40
|
+
this.refreshService = new Service.Switch(
|
|
41
|
+
this.config.name + ' Refresh',
|
|
42
|
+
'refresh'
|
|
43
|
+
);
|
|
58
44
|
|
|
59
|
-
//
|
|
60
|
-
this.
|
|
61
|
-
this.
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
`${this.config.name} Thermostat`
|
|
65
|
-
);
|
|
45
|
+
// Eco Mode service (with subtype for uniqueness)
|
|
46
|
+
this.ecoModeService = new Service.Switch(
|
|
47
|
+
this.config.name + ' Eco Mode',
|
|
48
|
+
'eco'
|
|
49
|
+
);
|
|
66
50
|
|
|
67
|
-
//
|
|
68
|
-
this.
|
|
69
|
-
this.
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
51
|
+
// Thermostat service
|
|
52
|
+
this.thermostatService = new Service.Thermostat(
|
|
53
|
+
this.config.name + ' Thermostat'
|
|
54
|
+
);
|
|
55
|
+
|
|
56
|
+
// Humidity sensor service
|
|
57
|
+
this.humiditySensorService = new Service.HumiditySensor(
|
|
58
|
+
this.config.name + ' Humidity'
|
|
59
|
+
);
|
|
74
60
|
|
|
75
61
|
this.setupCharacteristics();
|
|
76
62
|
}
|