@switchbot/homebridge-switchbot 1.4.1-beta.5 → 1.5.1-beta.0
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/.github/FUNDING.yml +4 -0
- package/CHANGELOG.md +9 -2
- package/config.schema.json +2 -2
- package/dist/irdevices/airconditioners.d.ts +29 -11
- package/dist/irdevices/airconditioners.d.ts.map +1 -1
- package/dist/irdevices/airconditioners.js +319 -142
- package/dist/irdevices/airconditioners.js.map +1 -1
- package/package.json +2 -2
- package/src/irdevices/airconditioners.ts +321 -139
package/CHANGELOG.md
CHANGED
|
@@ -2,7 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. This project uses [Semantic Versioning](https://semver.org/)
|
|
4
4
|
|
|
5
|
-
## [Beta - Version 1.5.
|
|
5
|
+
## [Beta - Version 1.5.1](https://github.com/OpenWonderLabs/homebridge-switchbot/releases/tag/v1.5.1) (2021-12-XX)
|
|
6
|
+
|
|
7
|
+
## What's Changed
|
|
8
|
+
* Fixed Bug: Contact Sensor talks about Curtain Light + Motion Sensor. [#164](https://github.com/OpenWonderLabs/homebridge-switchbot/issues/164)
|
|
9
|
+
|
|
10
|
+
**Full Changelog**: https://github.com/OpenWonderLabs/homebridge-switchbot/compare/v1.5.0...v1.5.1
|
|
11
|
+
|
|
12
|
+
## [Version 1.5.0](https://github.com/OpenWonderLabs/homebridge-switchbot/releases/tag/v1.5.0) (2021-12-27)
|
|
6
13
|
|
|
7
14
|
## What's Changed
|
|
8
15
|
### Major Change To `Logging`:
|
|
@@ -17,7 +24,7 @@ All notable changes to this project will be documented in this file. This projec
|
|
|
17
24
|
* Added an option to override `refreshRate` for each Device, by using the Device Config.
|
|
18
25
|
|
|
19
26
|
### Other Changes
|
|
20
|
-
* Fixed Bug:
|
|
27
|
+
* Fixed Bug: Air conditioner temperature not able to change. [#43](https://github.com/OpenWonderLabs/homebridge-switchbot/issues/43)
|
|
21
28
|
* Housekeeping and updated dependencies.
|
|
22
29
|
|
|
23
30
|
**Full Changelog**: https://github.com/OpenWonderLabs/homebridge-switchbot/compare/v1.4.0...v1.5.0
|
package/config.schema.json
CHANGED
|
@@ -303,14 +303,14 @@
|
|
|
303
303
|
"type": "object",
|
|
304
304
|
"properties": {
|
|
305
305
|
"hide_lightsensor": {
|
|
306
|
-
"title": "Hide
|
|
306
|
+
"title": "Hide Contact Sensor's Light Sensor",
|
|
307
307
|
"type": "boolean",
|
|
308
308
|
"condition": {
|
|
309
309
|
"functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' && model.options.devices[arrayIndices].deviceId);"
|
|
310
310
|
}
|
|
311
311
|
},
|
|
312
312
|
"hide_motionsensor": {
|
|
313
|
-
"title": "Hide
|
|
313
|
+
"title": "Hide Contact Sensor's Motion Sensor",
|
|
314
314
|
"type": "boolean",
|
|
315
315
|
"condition": {
|
|
316
316
|
"functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' && model.options.devices[arrayIndices].deviceId);"
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { AxiosResponse } from 'axios';
|
|
1
2
|
import { SwitchBotPlatform } from '../platform';
|
|
2
3
|
import { irDevicesConfig, irdevice, payload } from '../settings';
|
|
3
4
|
import { CharacteristicValue, PlatformAccessory, Service } from 'homebridge';
|
|
@@ -14,11 +15,17 @@ export declare class AirConditioner {
|
|
|
14
15
|
Active: CharacteristicValue;
|
|
15
16
|
ActiveCached: CharacteristicValue;
|
|
16
17
|
RotationSpeed: CharacteristicValue;
|
|
17
|
-
|
|
18
|
+
RotationSpeedCached: CharacteristicValue;
|
|
18
19
|
CurrentTemperature: CharacteristicValue;
|
|
19
20
|
CurrentTemperatureCached: CharacteristicValue;
|
|
20
|
-
TargetHeaterCoolerState
|
|
21
|
+
TargetHeaterCoolerState: CharacteristicValue;
|
|
22
|
+
TargetHeaterCoolerStateCached: CharacteristicValue;
|
|
21
23
|
CurrentHeaterCoolerState: CharacteristicValue;
|
|
24
|
+
CurrentHeaterCoolerStateCached: CharacteristicValue;
|
|
25
|
+
HeatingThresholdTemperature: CharacteristicValue;
|
|
26
|
+
HeatingThresholdTemperatureCached: CharacteristicValue;
|
|
27
|
+
CoolingThresholdTemperature: CharacteristicValue;
|
|
28
|
+
CoolingThresholdTemperatureCached: CharacteristicValue;
|
|
22
29
|
state: string;
|
|
23
30
|
Busy: any;
|
|
24
31
|
Timeout: any;
|
|
@@ -29,15 +36,9 @@ export declare class AirConditioner {
|
|
|
29
36
|
static MODE_COOL: number;
|
|
30
37
|
static MODE_HEAT: number;
|
|
31
38
|
deviceLogging: string;
|
|
39
|
+
hide_automode?: boolean;
|
|
32
40
|
constructor(platform: SwitchBotPlatform, accessory: PlatformAccessory, device: irdevice & irDevicesConfig);
|
|
33
41
|
logs(): void;
|
|
34
|
-
private RotationSpeedSet;
|
|
35
|
-
private RotationSpeedGet;
|
|
36
|
-
private ActiveSet;
|
|
37
|
-
private updateHomeKitCharacteristics;
|
|
38
|
-
private CurrentTemperatureGet;
|
|
39
|
-
private TargetHeaterCoolerStateSet;
|
|
40
|
-
private CurrentHeaterCoolerStateGet;
|
|
41
42
|
/**
|
|
42
43
|
* Pushes the requested changes to the SwitchBot API
|
|
43
44
|
* deviceType commandType Command command parameter Description
|
|
@@ -47,13 +48,30 @@ export declare class AirConditioner {
|
|
|
47
48
|
* AirConditioner: "command" "middleSpeed" "default" = fan speed to medium
|
|
48
49
|
* AirConditioner: "command" "highSpeed" "default" = fan speed to high
|
|
49
50
|
*/
|
|
50
|
-
pushAirConditionerOnChanges(): Promise<void>;
|
|
51
51
|
pushAirConditionerOffChanges(): Promise<void>;
|
|
52
52
|
pushAirConditionerStatusChanges(): Promise<void>;
|
|
53
53
|
pushAirConditionerDetailsChanges(): Promise<void>;
|
|
54
54
|
pushChanges(payload: payload): Promise<void>;
|
|
55
|
-
|
|
55
|
+
statusCode(push: AxiosResponse<{
|
|
56
|
+
statusCode: number;
|
|
57
|
+
}>): void;
|
|
58
|
+
updateHomeKitCharacteristics(): void;
|
|
56
59
|
apiError(e: any): void;
|
|
60
|
+
CurrentTemperatureGet(): CharacteristicValue;
|
|
61
|
+
RotationSpeedGet(): number;
|
|
62
|
+
RotationSpeedSet(value: CharacteristicValue): void;
|
|
63
|
+
ActiveSet(value: CharacteristicValue): void;
|
|
64
|
+
TargetHeaterCoolerStateGet(): CharacteristicValue;
|
|
65
|
+
TargetHeaterCoolerStateSet(value: CharacteristicValue): void;
|
|
66
|
+
private TargetHeaterCoolerStateAUTO;
|
|
67
|
+
private TargetHeaterCoolerStateCOOL;
|
|
68
|
+
private TargetHeaterCoolerStateHEAT;
|
|
69
|
+
CurrentHeaterCoolerStateGet(): CharacteristicValue;
|
|
70
|
+
private HeatingThresholdTemperatureGet;
|
|
71
|
+
private HeatingThresholdTemperatureSet;
|
|
72
|
+
private CoolingThresholdTemperatureGet;
|
|
73
|
+
private CoolingThresholdTemperatureSet;
|
|
74
|
+
private CurrentTemperatureUndefined;
|
|
57
75
|
/**
|
|
58
76
|
* Logging for Device
|
|
59
77
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"airconditioners.d.ts","sourceRoot":"","sources":["../../src/irdevices/airconditioners.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"airconditioners.d.ts","sourceRoot":"","sources":["../../src/irdevices/airconditioners.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AACtC,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,EAAE,eAAe,EAAa,QAAQ,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAC5E,OAAO,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAE7E;;;;GAIG;A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