@homebridge-plugins/homebridge-smarthq 0.4.5 → 0.4.7

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.
Files changed (69) hide show
  1. package/CHANGELOG.md +176 -0
  2. package/dist/devices/advantium.d.ts +10 -0
  3. package/dist/devices/advantium.d.ts.map +1 -0
  4. package/dist/devices/advantium.js +72 -0
  5. package/dist/devices/advantium.js.map +1 -0
  6. package/dist/devices/beverageCenter.d.ts +10 -0
  7. package/dist/devices/beverageCenter.d.ts.map +1 -0
  8. package/dist/devices/beverageCenter.js +122 -0
  9. package/dist/devices/beverageCenter.js.map +1 -0
  10. package/dist/devices/clothesDryer.d.ts.map +1 -1
  11. package/dist/devices/clothesDryer.js +43 -8
  12. package/dist/devices/clothesDryer.js.map +1 -1
  13. package/dist/devices/clothesWasher.d.ts.map +1 -1
  14. package/dist/devices/clothesWasher.js +43 -8
  15. package/dist/devices/clothesWasher.js.map +1 -1
  16. package/dist/devices/coffeeMaker.d.ts +10 -0
  17. package/dist/devices/coffeeMaker.d.ts.map +1 -0
  18. package/dist/devices/coffeeMaker.js +76 -0
  19. package/dist/devices/coffeeMaker.js.map +1 -0
  20. package/dist/devices/dishwasher.d.ts.map +1 -1
  21. package/dist/devices/dishwasher.js +44 -24
  22. package/dist/devices/dishwasher.js.map +1 -1
  23. package/dist/devices/microwave.d.ts +10 -0
  24. package/dist/devices/microwave.d.ts.map +1 -0
  25. package/dist/devices/microwave.js +81 -0
  26. package/dist/devices/microwave.js.map +1 -0
  27. package/dist/devices/oven.d.ts.map +1 -1
  28. package/dist/devices/oven.js +71 -52
  29. package/dist/devices/oven.js.map +1 -1
  30. package/dist/devices/refrigerator.d.ts.map +1 -1
  31. package/dist/devices/refrigerator.js +106 -7
  32. package/dist/devices/refrigerator.js.map +1 -1
  33. package/dist/devices/waterFilter.d.ts +10 -0
  34. package/dist/devices/waterFilter.d.ts.map +1 -0
  35. package/dist/devices/waterFilter.js +65 -0
  36. package/dist/devices/waterFilter.js.map +1 -0
  37. package/dist/devices/waterHeater.d.ts +10 -0
  38. package/dist/devices/waterHeater.d.ts.map +1 -0
  39. package/dist/devices/waterHeater.js +94 -0
  40. package/dist/devices/waterHeater.js.map +1 -0
  41. package/dist/devices/waterSoftener.d.ts +10 -0
  42. package/dist/devices/waterSoftener.d.ts.map +1 -0
  43. package/dist/devices/waterSoftener.js +65 -0
  44. package/dist/devices/waterSoftener.js.map +1 -0
  45. package/dist/platform.d.ts +7 -0
  46. package/dist/platform.d.ts.map +1 -1
  47. package/dist/platform.js +267 -0
  48. package/dist/platform.js.map +1 -1
  49. package/docs/classes/SmartHQPlatform.html +8 -8
  50. package/docs/interfaces/DeviceOptions.html +2 -2
  51. package/docs/interfaces/SmartHQPlatformConfig.html +2 -2
  52. package/docs/interfaces/SmartHqContext.html +2 -2
  53. package/docs/interfaces/SmartHqERDResponse.html +2 -2
  54. package/docs/interfaces/credentials.html +2 -2
  55. package/docs/interfaces/devicesConfig.html +2 -2
  56. package/docs/interfaces/options.html +2 -2
  57. package/docs/variables/API_URL.html +1 -1
  58. package/docs/variables/ERD_CODES.html +1 -1
  59. package/docs/variables/ERD_TYPES.html +1 -1
  60. package/docs/variables/KEEPALIVE_TIMEOUT.html +1 -1
  61. package/docs/variables/LOGIN_URL.html +1 -1
  62. package/docs/variables/OAUTH2_CLIENT_ID.html +1 -1
  63. package/docs/variables/OAUTH2_CLIENT_SECRET.html +1 -1
  64. package/docs/variables/OAUTH2_REDIRECT_URI.html +1 -1
  65. package/docs/variables/PLATFORM_NAME.html +1 -1
  66. package/docs/variables/PLUGIN_NAME.html +1 -1
  67. package/docs/variables/SECURE_URL.html +1 -1
  68. package/docs/variables/default.html +1 -1
  69. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -2,6 +2,182 @@
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
+ ## [0.4.6](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.4...v0.4.6) (2025-12-22)
6
+
7
+
8
+
9
+ ## [0.4.4](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.3...v0.4.4) (2025-12-22)
10
+
11
+
12
+ ### Reverts
13
+
14
+ * Revert "update dependenices" ([b3fe90e](https://github.com/homebridge-plugins/homebridge-smarthq/commit/b3fe90ea172fb78b8acd360695cbc3c6b97f0326))
15
+
16
+
17
+
18
+ ## [0.4.3](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.1...v0.4.3) (2025-12-22)
19
+
20
+
21
+ ### Features
22
+
23
+ * support hood ([#57](https://github.com/homebridge-plugins/homebridge-smarthq/issues/57)) ([2659b21](https://github.com/homebridge-plugins/homebridge-smarthq/commit/2659b21a0a483cb15e0622733f58d75603d99cab))
24
+
25
+
26
+
27
+ ## [0.4.1](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.0...v0.4.1) (2025-09-18)
28
+
29
+
30
+ ### Bug Fixes
31
+
32
+ * **air conditioner:** fix temperature setting and update switch display names ([#38](https://github.com/homebridge-plugins/homebridge-smarthq/issues/38)) ([1675205](https://github.com/homebridge-plugins/homebridge-smarthq/commit/16752059c93d6a5b26b782f2b42246e622b4b830))
33
+ * **air conditioner:** preserve decimal precision when converting Celsius to Fahrenheit ([#40](https://github.com/homebridge-plugins/homebridge-smarthq/issues/40)) ([38c8285](https://github.com/homebridge-plugins/homebridge-smarthq/commit/38c82852015d8ea0ceb0f4dd4b9ddf0622f57963))
34
+ * **air conditioner:** report all operating modes off when unit is off ([#42](https://github.com/homebridge-plugins/homebridge-smarthq/issues/42)) ([d44ebe3](https://github.com/homebridge-plugins/homebridge-smarthq/commit/d44ebe34590a2da6645e30db0db269e1dbbe4f3b))
35
+
36
+
37
+ ### Features
38
+
39
+ * add Portable AC as supported device ([#45](https://github.com/homebridge-plugins/homebridge-smarthq/issues/45)) ([50d83b1](https://github.com/homebridge-plugins/homebridge-smarthq/commit/50d83b1e003d8d238485459a5c882f357e1c61fb))
40
+
41
+
42
+
43
+ # [0.4.0](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.2.0...v0.4.0) (2025-06-27)
44
+
45
+
46
+
47
+ # 0.2.0 (2025-02-23)
48
+
49
+ ## [0.4.6](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.4...v0.4.6) (2025-12-22)
50
+
51
+
52
+
53
+ ## [0.4.4](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.3...v0.4.4) (2025-12-22)
54
+
55
+
56
+ ### Reverts
57
+
58
+ * Revert "update dependenices" ([b3fe90e](https://github.com/homebridge-plugins/homebridge-smarthq/commit/b3fe90ea172fb78b8acd360695cbc3c6b97f0326))
59
+
60
+
61
+
62
+ ## [0.4.3](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.1...v0.4.3) (2025-12-22)
63
+
64
+
65
+ ### Features
66
+
67
+ * support hood ([#57](https://github.com/homebridge-plugins/homebridge-smarthq/issues/57)) ([2659b21](https://github.com/homebridge-plugins/homebridge-smarthq/commit/2659b21a0a483cb15e0622733f58d75603d99cab))
68
+
69
+
70
+
71
+ ## [0.4.1](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.0...v0.4.1) (2025-09-18)
72
+
73
+
74
+ ### Bug Fixes
75
+
76
+ * **air conditioner:** fix temperature setting and update switch display names ([#38](https://github.com/homebridge-plugins/homebridge-smarthq/issues/38)) ([1675205](https://github.com/homebridge-plugins/homebridge-smarthq/commit/16752059c93d6a5b26b782f2b42246e622b4b830))
77
+ * **air conditioner:** preserve decimal precision when converting Celsius to Fahrenheit ([#40](https://github.com/homebridge-plugins/homebridge-smarthq/issues/40)) ([38c8285](https://github.com/homebridge-plugins/homebridge-smarthq/commit/38c82852015d8ea0ceb0f4dd4b9ddf0622f57963))
78
+ * **air conditioner:** report all operating modes off when unit is off ([#42](https://github.com/homebridge-plugins/homebridge-smarthq/issues/42)) ([d44ebe3](https://github.com/homebridge-plugins/homebridge-smarthq/commit/d44ebe34590a2da6645e30db0db269e1dbbe4f3b))
79
+
80
+
81
+ ### Features
82
+
83
+ * add Portable AC as supported device ([#45](https://github.com/homebridge-plugins/homebridge-smarthq/issues/45)) ([50d83b1](https://github.com/homebridge-plugins/homebridge-smarthq/commit/50d83b1e003d8d238485459a5c882f357e1c61fb))
84
+
85
+
86
+
87
+ # [0.4.0](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.2.0...v0.4.0) (2025-06-27)
88
+
89
+
90
+
91
+ # 0.2.0 (2025-02-23)
92
+
93
+ ## [0.4.6](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.4...v0.4.6) (2025-12-22)
94
+
95
+
96
+
97
+ ## [0.4.4](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.3...v0.4.4) (2025-12-22)
98
+
99
+
100
+ ### Reverts
101
+
102
+ * Revert "update dependenices" ([b3fe90e](https://github.com/homebridge-plugins/homebridge-smarthq/commit/b3fe90ea172fb78b8acd360695cbc3c6b97f0326))
103
+
104
+
105
+
106
+ ## [0.4.3](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.1...v0.4.3) (2025-12-22)
107
+
108
+
109
+ ### Features
110
+
111
+ * support hood ([#57](https://github.com/homebridge-plugins/homebridge-smarthq/issues/57)) ([2659b21](https://github.com/homebridge-plugins/homebridge-smarthq/commit/2659b21a0a483cb15e0622733f58d75603d99cab))
112
+
113
+
114
+
115
+ ## [0.4.1](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.0...v0.4.1) (2025-09-18)
116
+
117
+
118
+ ### Bug Fixes
119
+
120
+ * **air conditioner:** fix temperature setting and update switch display names ([#38](https://github.com/homebridge-plugins/homebridge-smarthq/issues/38)) ([1675205](https://github.com/homebridge-plugins/homebridge-smarthq/commit/16752059c93d6a5b26b782f2b42246e622b4b830))
121
+ * **air conditioner:** preserve decimal precision when converting Celsius to Fahrenheit ([#40](https://github.com/homebridge-plugins/homebridge-smarthq/issues/40)) ([38c8285](https://github.com/homebridge-plugins/homebridge-smarthq/commit/38c82852015d8ea0ceb0f4dd4b9ddf0622f57963))
122
+ * **air conditioner:** report all operating modes off when unit is off ([#42](https://github.com/homebridge-plugins/homebridge-smarthq/issues/42)) ([d44ebe3](https://github.com/homebridge-plugins/homebridge-smarthq/commit/d44ebe34590a2da6645e30db0db269e1dbbe4f3b))
123
+
124
+
125
+ ### Features
126
+
127
+ * add Portable AC as supported device ([#45](https://github.com/homebridge-plugins/homebridge-smarthq/issues/45)) ([50d83b1](https://github.com/homebridge-plugins/homebridge-smarthq/commit/50d83b1e003d8d238485459a5c882f357e1c61fb))
128
+
129
+
130
+
131
+ # [0.4.0](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.2.0...v0.4.0) (2025-06-27)
132
+
133
+
134
+
135
+ # 0.2.0 (2025-02-23)
136
+
137
+ ## [0.4.5](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.4...v0.4.5) (2025-12-22)
138
+
139
+
140
+
141
+ ## [0.4.4](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.3...v0.4.4) (2025-12-22)
142
+
143
+
144
+ ### Reverts
145
+
146
+ * Revert "update dependenices" ([b3fe90e](https://github.com/homebridge-plugins/homebridge-smarthq/commit/b3fe90ea172fb78b8acd360695cbc3c6b97f0326))
147
+
148
+
149
+
150
+ ## [0.4.3](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.1...v0.4.3) (2025-12-22)
151
+
152
+
153
+ ### Features
154
+
155
+ * support hood ([#57](https://github.com/homebridge-plugins/homebridge-smarthq/issues/57)) ([2659b21](https://github.com/homebridge-plugins/homebridge-smarthq/commit/2659b21a0a483cb15e0622733f58d75603d99cab))
156
+
157
+
158
+
159
+ ## [0.4.1](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.0...v0.4.1) (2025-09-18)
160
+
161
+
162
+ ### Bug Fixes
163
+
164
+ * **air conditioner:** fix temperature setting and update switch display names ([#38](https://github.com/homebridge-plugins/homebridge-smarthq/issues/38)) ([1675205](https://github.com/homebridge-plugins/homebridge-smarthq/commit/16752059c93d6a5b26b782f2b42246e622b4b830))
165
+ * **air conditioner:** preserve decimal precision when converting Celsius to Fahrenheit ([#40](https://github.com/homebridge-plugins/homebridge-smarthq/issues/40)) ([38c8285](https://github.com/homebridge-plugins/homebridge-smarthq/commit/38c82852015d8ea0ceb0f4dd4b9ddf0622f57963))
166
+ * **air conditioner:** report all operating modes off when unit is off ([#42](https://github.com/homebridge-plugins/homebridge-smarthq/issues/42)) ([d44ebe3](https://github.com/homebridge-plugins/homebridge-smarthq/commit/d44ebe34590a2da6645e30db0db269e1dbbe4f3b))
167
+
168
+
169
+ ### Features
170
+
171
+ * add Portable AC as supported device ([#45](https://github.com/homebridge-plugins/homebridge-smarthq/issues/45)) ([50d83b1](https://github.com/homebridge-plugins/homebridge-smarthq/commit/50d83b1e003d8d238485459a5c882f357e1c61fb))
172
+
173
+
174
+
175
+ # [0.4.0](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.2.0...v0.4.0) (2025-06-27)
176
+
177
+
178
+
179
+ # 0.2.0 (2025-02-23)
180
+
5
181
  ## [0.4.5](https://github.com/homebridge-plugins/homebridge-smarthq/compare/v0.4.4...v0.4.5) (2025-12-22)
6
182
 
7
183
 
@@ -0,0 +1,10 @@
1
+ import type { PlatformAccessory } from 'homebridge';
2
+ import type { SmartHQPlatform } from '../platform.js';
3
+ import type { devicesConfig, SmartHqContext } from '../settings.js';
4
+ import { deviceBase } from './device.js';
5
+ export declare class SmartHQAdvantium extends deviceBase {
6
+ readonly platform: SmartHQPlatform;
7
+ readonly device: SmartHqContext['device'] & devicesConfig;
8
+ constructor(platform: SmartHQPlatform, accessory: PlatformAccessory<SmartHqContext>, device: SmartHqContext['device'] & devicesConfig);
9
+ }
10
+ //# sourceMappingURL=advantium.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"advantium.d.ts","sourceRoot":"","sources":["../../src/devices/advantium.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AACrD,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEnE,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,qBAAa,gBAAiB,SAAQ,UAAU;IAE5C,QAAQ,CAAC,QAAQ,EAAE,eAAe;IAElC,QAAQ,CAAC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,aAAa;gBAFhD,QAAQ,EAAE,eAAe,EAClC,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EACnC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,aAAa;CA+D5D"}
@@ -0,0 +1,72 @@
1
+ import { deviceBase } from './device.js';
2
+ export class SmartHQAdvantium extends deviceBase {
3
+ platform;
4
+ device;
5
+ constructor(platform, accessory, device) {
6
+ super(platform, accessory, device);
7
+ this.platform = platform;
8
+ this.device = device;
9
+ this.debugLog(`Advantium Features: ${JSON.stringify(accessory.context.device.features)}`);
10
+ // Advantium Light
11
+ const light = this.accessory.getService('Advantium Light') ?? this.accessory.addService(this.platform.Service.Lightbulb, 'Advantium Light', 'AdvantiumLight');
12
+ light
13
+ .getCharacteristic(this.platform.Characteristic.On)
14
+ .onGet(async () => {
15
+ try {
16
+ // TODO: Implement light state ERD
17
+ return false;
18
+ }
19
+ catch (error) {
20
+ this.warnLog?.(`Advantium Light error: ${error?.message ?? error}`);
21
+ return false;
22
+ }
23
+ })
24
+ .onSet(async (value) => {
25
+ try {
26
+ // TODO: Implement light control ERD
27
+ this.debugLog(`Advantium Light set to: ${value}`);
28
+ }
29
+ catch (error) {
30
+ this.warnLog?.(`Advantium Light set error: ${error?.message ?? error}`);
31
+ }
32
+ });
33
+ // Advantium Temperature Sensor
34
+ const tempSensor = this.accessory.getService('Advantium Temperature') ?? this.accessory.addService(this.platform.Service.TemperatureSensor, 'Advantium Temperature', 'AdvantiumTemp');
35
+ tempSensor
36
+ .getCharacteristic(this.platform.Characteristic.CurrentTemperature)
37
+ .onGet(async () => {
38
+ try {
39
+ // TODO: Implement current temperature ERD
40
+ return 0;
41
+ }
42
+ catch (error) {
43
+ this.warnLog?.(`Advantium Temperature error: ${error?.message ?? error}`);
44
+ return 0;
45
+ }
46
+ });
47
+ // Advantium Running State (Switch)
48
+ const runningSwitch = this.accessory.getService('Advantium Running') ?? this.accessory.addService(this.platform.Service.Switch, 'Advantium Running', 'AdvantiumRunning');
49
+ runningSwitch
50
+ .getCharacteristic(this.platform.Characteristic.On)
51
+ .onGet(async () => {
52
+ try {
53
+ // TODO: Implement running state ERD
54
+ return false;
55
+ }
56
+ catch (error) {
57
+ this.warnLog?.(`Advantium Running error: ${error?.message ?? error}`);
58
+ return false;
59
+ }
60
+ })
61
+ .onSet(async (value) => {
62
+ try {
63
+ // TODO: Implement running control ERD
64
+ this.debugLog(`Advantium Running set to: ${value}`);
65
+ }
66
+ catch (error) {
67
+ this.warnLog?.(`Advantium Running set error: ${error?.message ?? error}`);
68
+ }
69
+ });
70
+ }
71
+ }
72
+ //# sourceMappingURL=advantium.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"advantium.js","sourceRoot":"","sources":["../../src/devices/advantium.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,MAAM,OAAO,gBAAiB,SAAQ,UAAU;IAEnC;IAEA;IAHX,YACW,QAAyB,EAClC,SAA4C,EACnC,MAAgD;QAEzD,KAAK,CAAC,QAAQ,EAAE,SAAS,EAAE,MAAM,CAAC,CAAA;QAJzB,aAAQ,GAAR,QAAQ,CAAiB;QAEzB,WAAM,GAAN,MAAM,CAA0C;QAGzD,IAAI,CAAC,QAAQ,CAAC,uBAAuB,IAAI,CAAC,SAAS,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CACF"}
@@ -0,0 +1,10 @@
1
+ import type { PlatformAccessory } from 'homebridge';
2
+ import type { SmartHQPlatform } from '../platform.js';
3
+ import type { devicesConfig, SmartHqContext } from '../settings.js';
4
+ import { deviceBase } from './device.js';
5
+ export declare class SmartHQBeverageCenter extends deviceBase {
6
+ readonly platform: SmartHQPlatform;
7
+ readonly device: SmartHqContext['device'] & devicesConfig;
8
+ constructor(platform: SmartHQPlatform, accessory: PlatformAccessory<SmartHqContext>, device: SmartHqContext['device'] & devicesConfig);
9
+ }
10
+ //# sourceMappingURL=beverageCenter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"beverageCenter.d.ts","sourceRoot":"","sources":["../../src/devices/beverageCenter.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AACrD,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEnE,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,qBAAa,qBAAsB,SAAQ,UAAU;IAEjD,QAAQ,CAAC,QAAQ,EAAE,eAAe;IAElC,QAAQ,CAAC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,aAAa;gBAFhD,QAAQ,EAAE,eAAe,EAClC,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EACnC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,aAAa;CAkH5D"}
@@ -0,0 +1,122 @@
1
+ import { deviceBase } from './device.js';
2
+ export class SmartHQBeverageCenter extends deviceBase {
3
+ platform;
4
+ device;
5
+ constructor(platform, accessory, device) {
6
+ super(platform, accessory, device);
7
+ this.platform = platform;
8
+ this.device = device;
9
+ this.debugLog(`Beverage Center Features: ${JSON.stringify(accessory.context.device.features)}`);
10
+ // Beverage Center Temperature Sensor
11
+ const tempSensor = this.accessory.getService('Beverage Temperature') ?? this.accessory.addService(this.platform.Service.TemperatureSensor, 'Beverage Temperature', 'BeverageTemp');
12
+ tempSensor
13
+ .getCharacteristic(this.platform.Characteristic.CurrentTemperature)
14
+ .onGet(async () => {
15
+ try {
16
+ // TODO: Implement current temperature ERD
17
+ return 4;
18
+ }
19
+ catch (error) {
20
+ this.warnLog?.(`Beverage Center Temperature error: ${error?.message ?? error}`);
21
+ return 4;
22
+ }
23
+ });
24
+ // Beverage Center Door Sensor
25
+ const doorSensor = this.accessory.getService('Beverage Door') ?? this.accessory.addService(this.platform.Service.ContactSensor, 'Beverage Door', 'BeverageDoor');
26
+ doorSensor
27
+ .getCharacteristic(this.platform.Characteristic.ContactSensorState)
28
+ .onGet(async () => {
29
+ try {
30
+ // TODO: Implement door status ERD
31
+ return this.platform.Characteristic.ContactSensorState.CONTACT_DETECTED;
32
+ }
33
+ catch (error) {
34
+ this.warnLog?.(`Beverage Center Door error: ${error?.message ?? error}`);
35
+ return this.platform.Characteristic.ContactSensorState.CONTACT_DETECTED;
36
+ }
37
+ });
38
+ // Beverage Center Thermostat Control
39
+ const thermostat = this.accessory.getService('Beverage Thermostat') ?? this.accessory.addService(this.platform.Service.Thermostat, 'Beverage Thermostat', 'BeverageThermostat');
40
+ thermostat
41
+ .getCharacteristic(this.platform.Characteristic.CurrentHeatingCoolingState)
42
+ .onGet(async () => {
43
+ try {
44
+ // TODO: Implement cooling state ERD
45
+ return this.platform.Characteristic.CurrentHeatingCoolingState.COOL;
46
+ }
47
+ catch (error) {
48
+ this.warnLog?.(`Beverage Center State error: ${error?.message ?? error}`);
49
+ return this.platform.Characteristic.CurrentHeatingCoolingState.OFF;
50
+ }
51
+ });
52
+ thermostat
53
+ .getCharacteristic(this.platform.Characteristic.TargetHeatingCoolingState)
54
+ .setProps({
55
+ validValues: [this.platform.Characteristic.TargetHeatingCoolingState.OFF, this.platform.Characteristic.TargetHeatingCoolingState.COOL],
56
+ })
57
+ .onGet(async () => {
58
+ try {
59
+ // TODO: Implement target state ERD
60
+ return this.platform.Characteristic.TargetHeatingCoolingState.COOL;
61
+ }
62
+ catch (error) {
63
+ this.warnLog?.(`Beverage Center Target State error: ${error?.message ?? error}`);
64
+ return this.platform.Characteristic.TargetHeatingCoolingState.OFF;
65
+ }
66
+ })
67
+ .onSet(async (value) => {
68
+ try {
69
+ // TODO: Implement target state control ERD
70
+ this.debugLog(`Beverage Center set to: ${value}`);
71
+ }
72
+ catch (error) {
73
+ this.warnLog?.(`Beverage Center Target State set error: ${error?.message ?? error}`);
74
+ }
75
+ });
76
+ thermostat
77
+ .getCharacteristic(this.platform.Characteristic.CurrentTemperature)
78
+ .onGet(async () => {
79
+ try {
80
+ // TODO: Implement current temperature ERD
81
+ return 4;
82
+ }
83
+ catch (error) {
84
+ this.warnLog?.(`Beverage Center Current Temp error: ${error?.message ?? error}`);
85
+ return 4;
86
+ }
87
+ });
88
+ thermostat
89
+ .getCharacteristic(this.platform.Characteristic.TargetTemperature)
90
+ .setProps({
91
+ minValue: 2,
92
+ maxValue: 8,
93
+ minStep: 1,
94
+ })
95
+ .onGet(async () => {
96
+ try {
97
+ // TODO: Implement target temperature ERD
98
+ return 4;
99
+ }
100
+ catch (error) {
101
+ this.warnLog?.(`Beverage Center Target Temp error: ${error?.message ?? error}`);
102
+ return 4;
103
+ }
104
+ })
105
+ .onSet(async (value) => {
106
+ try {
107
+ // TODO: Implement target temperature control ERD
108
+ this.debugLog(`Beverage Center temperature set to: ${value}°C`);
109
+ }
110
+ catch (error) {
111
+ this.warnLog?.(`Beverage Center Target Temp set error: ${error?.message ?? error}`);
112
+ }
113
+ });
114
+ thermostat
115
+ .getCharacteristic(this.platform.Characteristic.TemperatureDisplayUnits)
116
+ .onGet(async () => this.platform.Characteristic.TemperatureDisplayUnits.CELSIUS)
117
+ .onSet(async (value) => {
118
+ this.debugLog(`Beverage Center display units set to: ${value}`);
119
+ });
120
+ }
121
+ }
122
+ //# sourceMappingURL=beverageCenter.js.map
@@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N,CAAC;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"clothesDryer.d.ts","sourceRoot":"","sources":["../../src/devices/clothesDryer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAExE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEpD,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,qBAAa,mBAAoB,SAAQ,UAAU;IACjD,OAAO,CAAC,YAAY,CAEnB;gBAGC,QAAQ,EAAE,GAAG,EACb,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EAC5C,MAAM,EAAE,GAAG;IAgBP,WAAW,IAAI,OAAO,CAAC,mBAAmB,CAAC;IAY3C,WAAW,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC;CAS7D"}
1
+ {"version":3,"file":"clothesDryer.d.ts","sourceRoot":"","sources":["../../src/devices/clothesDryer.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAExE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEpD,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,qBAAa,mBAAoB,SAAQ,UAAU;IACjD,OAAO,CAAC,YAAY,CAEnB;gBAGC,QAAQ,EAAE,GAAG,EACb,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EAC5C,MAAM,EAAE,GAAG;IAqDP,WAAW,IAAI,OAAO,CAAC,mBAAmB,CAAC;IAY3C,WAAW,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC;CAS7D"}
@@ -4,16 +4,51 @@ export class SmartHQClothesDryer extends deviceBase {
4
4
  constructor(platform, accessory, device) {
5
5
  super(platform, accessory, device);
6
6
  this.debugLog(`Clothes Dryer Features: ${JSON.stringify(accessory.context.device.features)}`);
7
- accessory.context.device.features.forEach((feature) => {
8
- if (feature === 'CLOTHES_DRYER_V1_FOUNDATION') {
9
- const dryer = this.accessory.getService(accessory.displayName) ?? this.accessory.addService(this.platform.Service.Switch, accessory.displayName, 'Clothes Dryer');
10
- dryer.getCharacteristic(this.platform.Characteristic.On)
11
- .onGet(this.handleGetOn.bind(this))
12
- .onSet(this.handleSetOn.bind(this));
7
+ // Dryer Running State (Valve)
8
+ const dryerValve = this.accessory.getService('Dryer') ?? this.accessory.addService(this.platform.Service.Valve, 'Dryer', 'Dryer');
9
+ dryerValve.setCharacteristic(this.platform.Characteristic.ValveType, this.platform.Characteristic.ValveType.GENERIC_VALVE);
10
+ dryerValve
11
+ .getCharacteristic(this.platform.Characteristic.Active)
12
+ .onGet(async () => {
13
+ try {
14
+ return this.ClothesDryer?.On ? this.platform.Characteristic.Active.ACTIVE : this.platform.Characteristic.Active.INACTIVE;
13
15
  }
14
- else {
15
- this.debugLog(`Feature not supported: ${feature}`);
16
+ catch (error) {
17
+ this.warnLog?.(`Dryer Active error: ${error?.message ?? error}`);
18
+ return this.platform.Characteristic.Active.INACTIVE;
16
19
  }
20
+ })
21
+ .onSet(this.handleSetOn.bind(this));
22
+ dryerValve
23
+ .getCharacteristic(this.platform.Characteristic.InUse)
24
+ .onGet(async () => {
25
+ try {
26
+ return this.ClothesDryer?.On ? this.platform.Characteristic.InUse.IN_USE : this.platform.Characteristic.InUse.NOT_IN_USE;
27
+ }
28
+ catch (error) {
29
+ this.warnLog?.(`Dryer InUse error: ${error?.message ?? error}`);
30
+ return this.platform.Characteristic.InUse.NOT_IN_USE;
31
+ }
32
+ });
33
+ // Door Lock
34
+ const doorLock = this.accessory.getService('Dryer Door Lock') ?? this.accessory.addService(this.platform.Service.LockMechanism, 'Dryer Door Lock', 'DryerDoorLock');
35
+ doorLock
36
+ .getCharacteristic(this.platform.Characteristic.LockCurrentState)
37
+ .onGet(async () => {
38
+ try {
39
+ // TODO: Implement door lock state when ERD available
40
+ return this.platform.Characteristic.LockCurrentState.UNSECURED;
41
+ }
42
+ catch (error) {
43
+ this.warnLog?.(`Dryer Door Lock error: ${error?.message ?? error}`);
44
+ return this.platform.Characteristic.LockCurrentState.UNSECURED;
45
+ }
46
+ });
47
+ doorLock
48
+ .getCharacteristic(this.platform.Characteristic.LockTargetState)
49
+ .onGet(async () => this.platform.Characteristic.LockTargetState.UNSECURED)
50
+ .onSet(async (value) => {
51
+ this.debugLog(`Dryer Door Lock set to: ${value}`);
17
52
  });
18
53
  }
19
54
  async handleGetOn() {
@@ -1 +1 @@
1
- {"version":3,"file":"clothesDryer.js","sourceRoot":"","sources":["../../src/devices/clothesDryer.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,MAAM,OAAO,mBAAoB,SAAQ,UAAU;IACzC,YAAY,CAEnB;IAED,YACE,QAAa,EACb,SAA4C,EAC5C,MAAW;QAEX,KAAK,CAAC,QAAQ,EAAE,SAAS,EAAE,MAAM,CAAC,CAAA;QAClC,IAAI,CAAC,QAAQ,CAAC,2BAA2B,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAA;QAC7F,SAAS,CAAC,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,OAAe,EAAE,EAAE;YAC5D,IAAI,OAAO,KAAK,6BAA6B,EAAE,CAAC;gBAC9C,MAAM,KAAK,GAAG,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,SAAS,CAAC,WAAW,CAAC,IAAI,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,MAAM,EAAE,SAAS,CAAC,WAAW,EAAE,eAAe,CAAC,CAAA;gBACjK,KAAK,CAAC,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,cAAc,CAAC,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BAGC,QAAQ,EAAE,GAAG,EACb,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EAC5C,MAAM,EAAE,GAAG;IAgBP,WAAW,IAAI,OAAO,CAAC,mBAAmB,CAAC;IAY3C,WAAW,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC;CAS7D"}
1
+ {"version":3,"file":"clothesWasher.d.ts","sourceRoot":"","sources":["../../src/devices/clothesWasher.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAExE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEpD,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,qBAAa,oBAAqB,SAAQ,UAAU;IAClD,OAAO,CAAC,aAAa,CAEpB;gBAGC,QAAQ,EAAE,GAAG,EACb,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EAC5C,MAAM,EAAE,GAAG;IAqDP,WAAW,IAAI,OAAO,CAAC,mBAAmB,CAAC;IAY3C,WAAW,CAAC,KAAK,EAAE,mBAAmB,GAAG,OAAO,CAAC,IAAI,CAAC;CAS7D"}
@@ -4,16 +4,51 @@ export class SmartHQClothesWasher extends deviceBase {
4
4
  constructor(platform, accessory, device) {
5
5
  super(platform, accessory, device);
6
6
  this.debugLog(`Clothes Washer Features: ${JSON.stringify(accessory.context.device.features)}`);
7
- accessory.context.device.features.forEach((feature) => {
8
- if (feature === 'CLOTHES_WASHER_V1_FOUNDATION') {
9
- const washer = this.accessory.getService(accessory.displayName) ?? this.accessory.addService(this.platform.Service.Switch, accessory.displayName, 'Clothes Washer');
10
- washer.getCharacteristic(this.platform.Characteristic.On)
11
- .onGet(this.handleGetOn.bind(this))
12
- .onSet(this.handleSetOn.bind(this));
7
+ // Washer Running State (Valve)
8
+ const washerValve = this.accessory.getService('Washer') ?? this.accessory.addService(this.platform.Service.Valve, 'Washer', 'Washer');
9
+ washerValve.setCharacteristic(this.platform.Characteristic.ValveType, this.platform.Characteristic.ValveType.GENERIC_VALVE);
10
+ washerValve
11
+ .getCharacteristic(this.platform.Characteristic.Active)
12
+ .onGet(async () => {
13
+ try {
14
+ return this.ClothesWasher?.On ? this.platform.Characteristic.Active.ACTIVE : this.platform.Characteristic.Active.INACTIVE;
13
15
  }
14
- else {
15
- this.debugLog(`Feature not supported: ${feature}`);
16
+ catch (error) {
17
+ this.warnLog(`Washer Active error: ${error?.message ?? error}`);
18
+ return this.platform.Characteristic.Active.INACTIVE;
16
19
  }
20
+ })
21
+ .onSet(this.handleSetOn.bind(this));
22
+ washerValve
23
+ .getCharacteristic(this.platform.Characteristic.InUse)
24
+ .onGet(async () => {
25
+ try {
26
+ return this.ClothesWasher?.On ? this.platform.Characteristic.InUse.IN_USE : this.platform.Characteristic.InUse.NOT_IN_USE;
27
+ }
28
+ catch (error) {
29
+ this.warnLog(`Washer InUse error: ${error?.message ?? error}`);
30
+ return this.platform.Characteristic.InUse.NOT_IN_USE;
31
+ }
32
+ });
33
+ // Door Lock
34
+ const doorLock = this.accessory.getService('Washer Door Lock') ?? this.accessory.addService(this.platform.Service.LockMechanism, 'Washer Door Lock', 'WasherDoorLock');
35
+ doorLock
36
+ .getCharacteristic(this.platform.Characteristic.LockCurrentState)
37
+ .onGet(async () => {
38
+ try {
39
+ // TODO: Implement door lock state when ERD available
40
+ return this.platform.Characteristic.LockCurrentState.UNSECURED;
41
+ }
42
+ catch (error) {
43
+ this.warnLog(`Washer Door Lock error: ${error?.message ?? error}`);
44
+ return this.platform.Characteristic.LockCurrentState.UNSECURED;
45
+ }
46
+ });
47
+ doorLock
48
+ .getCharacteristic(this.platform.Characteristic.LockTargetState)
49
+ .onGet(async () => this.platform.Characteristic.LockTargetState.UNSECURED)
50
+ .onSet(async (value) => {
51
+ this.debugLog(`Washer Door Lock set to: ${value}`);
17
52
  });
18
53
  }
19
54
  async handleGetOn() {
@@ -1 +1 @@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AAA;QACxC,CAAC;QAAC,OAAO,KAAU,EAAE,CAAC;YACpB,IAAI,CAAC,OAAO,CAAC,oCAAoC,KAAK,EAAE,OAAO,IAAI,KAAK,EAAE,CAAC,CAAA;YAC3E,OAAO,KAAK,CAAA;QACd,CAAC;IACH,CAAC;IAED,KAAK,CAAC,WAAW,CAAC,KAA0B;QAC1C,IAAI,CAAC;YACH,sEAAsE;YACtE,qEAAqE;YACrE,IAAI,CAAC,aAAa,CAAC,EAAE,GAAG,KAAK,CAAA;QAC/B,CAAC;QAAC,OAAO,KAAU,EAAE,CAAC;YACpB,IAAI,CAAC,OAAO,CAAC,oCAAoC,KAAK,EAAE,OAAO,IAAI,KAAK,EAAE,CAAC,CAAA;QAC7E,CAAC;IACH,CAAC;CACF"}
@@ -0,0 +1,10 @@
1
+ import type { PlatformAccessory } from 'homebridge';
2
+ import type { SmartHQPlatform } from '../platform.js';
3
+ import type { devicesConfig, SmartHqContext } from '../settings.js';
4
+ import { deviceBase } from './device.js';
5
+ export declare class SmartHQCoffeeMaker extends deviceBase {
6
+ readonly platform: SmartHQPlatform;
7
+ readonly device: SmartHqContext['device'] & devicesConfig;
8
+ constructor(platform: SmartHQPlatform, accessory: PlatformAccessory<SmartHqContext>, device: SmartHqContext['device'] & devicesConfig);
9
+ }
10
+ //# sourceMappingURL=coffeeMaker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coffeeMaker.d.ts","sourceRoot":"","sources":["../../src/devices/coffeeMaker.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAA;AAEnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AACrD,OAAO,KAAK,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAEnE,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAA;AAExC,qBAAa,kBAAmB,SAAQ,UAAU;IAE9C,QAAQ,CAAC,QAAQ,EAAE,eAAe;IAElC,QAAQ,CAAC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,aAAa;gBAFhD,QAAQ,EAAE,eAAe,EAClC,SAAS,EAAE,iBAAiB,CAAC,cAAc,CAAC,EACnC,MAAM,EAAE,cAAc,CAAC,QAAQ,CAAC,GAAG,aAAa;CAoE5D"}