homebridge-gree-ac 2.2.2-beta.4 → 2.2.2-beta.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.
Files changed (45) hide show
  1. package/CHANGELOG.md +9 -4
  2. package/LICENSE +175 -175
  3. package/README.md +511 -500
  4. package/config.schema.json +520 -495
  5. package/dist/commands.d.ts +35 -160
  6. package/dist/commands.js +160 -162
  7. package/dist/commands.js.map +1 -1
  8. package/dist/crypto.d.ts +10 -11
  9. package/dist/crypto.js +28 -33
  10. package/dist/crypto.js.map +1 -1
  11. package/dist/index.d.ts +6 -7
  12. package/dist/index.js +8 -6
  13. package/dist/index.js.map +1 -1
  14. package/dist/platform.d.ts +47 -43
  15. package/dist/platform.js +585 -533
  16. package/dist/platform.js.map +1 -1
  17. package/dist/platformAccessory.d.ts +108 -100
  18. package/dist/platformAccessory.js +1763 -1688
  19. package/dist/platformAccessory.js.map +1 -1
  20. package/dist/settings.d.ts +72 -112
  21. package/dist/settings.js +97 -103
  22. package/dist/settings.js.map +1 -1
  23. package/dist/tsAccessory.d.ts +32 -34
  24. package/dist/tsAccessory.js +69 -71
  25. package/dist/tsAccessory.js.map +1 -1
  26. package/dist/version.d.ts +1 -2
  27. package/dist/version.js +2 -5
  28. package/dist/version.js.map +1 -1
  29. package/greedevice.jpg +0 -0
  30. package/greedevinfo.jpg +0 -0
  31. package/greemac.jpg +0 -0
  32. package/ha_fan.jpg +0 -0
  33. package/ha_settings.jpg +0 -0
  34. package/package.json +56 -52
  35. package/uiconfig.jpg +0 -0
  36. package/uiconfigcustdef.jpg +0 -0
  37. package/uiconfigmin.jpg +0 -0
  38. package/dist/commands.d.ts.map +0 -1
  39. package/dist/crypto.d.ts.map +0 -1
  40. package/dist/index.d.ts.map +0 -1
  41. package/dist/platform.d.ts.map +0 -1
  42. package/dist/platformAccessory.d.ts.map +0 -1
  43. package/dist/settings.d.ts.map +0 -1
  44. package/dist/tsAccessory.d.ts.map +0 -1
  45. package/dist/version.d.ts.map +0 -1
@@ -1,495 +1,520 @@
1
- {
2
- "pluginAlias": "GREEAirConditioner",
3
- "pluginType": "platform",
4
- "singular": true,
5
- "schema": {
6
- "type": "object",
7
- "properties": {
8
- "name": {
9
- "type": "string",
10
- "required": true,
11
- "default": "GREE Air Conditioner"
12
- },
13
- "port": {
14
- "type": "integer",
15
- "required": false,
16
- "minimum": 1025
17
- },
18
- "scanInterval": {
19
- "type": "integer",
20
- "required": false,
21
- "default": 60,
22
- "minimum": 5
23
- },
24
- "devices": {
25
- "type": "array",
26
- "items": {
27
- "type": "object",
28
- "properties": {
29
- "mac": {
30
- "type": "string",
31
- "required": true,
32
- "pattern": "^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$"
33
- },
34
- "name": {
35
- "type": "string",
36
- "required": false
37
- },
38
- "model": {
39
- "type": "string",
40
- "required": false
41
- },
42
- "speedSteps": {
43
- "type": "integer",
44
- "required": true,
45
- "default": 5,
46
- "oneOf": [
47
- {
48
- "title": "3-step model",
49
- "enum": [
50
- 3
51
- ]
52
- },
53
- {
54
- "title": "5-step model",
55
- "enum": [
56
- 5
57
- ]
58
- }
59
- ]
60
- },
61
- "statusUpdateInterval": {
62
- "type": "integer",
63
- "required": false,
64
- "minimum": 1,
65
- "placeholder": 10
66
- },
67
- "sensorOffset": {
68
- "type": "integer",
69
- "required": false,
70
- "placeholder": 40
71
- },
72
- "minimumTargetTemperature": {
73
- "type": "integer",
74
- "required": false,
75
- "minimum": 8,
76
- "placeholder": 16
77
- },
78
- "maximumTargetTemperature": {
79
- "type": "integer",
80
- "required": false,
81
- "maximum": 30,
82
- "placeholder": 30
83
- },
84
- "xFanEnabled": {
85
- "type": "boolean",
86
- "default": true
87
- },
88
- "temperatureSensor": {
89
- "type": "string",
90
- "required": true,
91
- "default": "disabled",
92
- "oneOf": [
93
- {
94
- "title": "Disabled",
95
- "enum": [
96
- "disabled"
97
- ]
98
- },
99
- {
100
- "title": "Child accessory",
101
- "enum": [
102
- "child"
103
- ]
104
- },
105
- {
106
- "title": "Separate accessory",
107
- "enum": [
108
- "separate"
109
- ]
110
- }
111
- ]
112
- },
113
- "temperatureStepSize": {
114
- "type": "number",
115
- "minimum": 0.5,
116
- "multipleOf": 0.5,
117
- "required": false
118
- },
119
- "disabled": {
120
- "type": "boolean"
121
- },
122
- "modifyVerticalSwingPosition": {
123
- "type": "integer",
124
- "required": true,
125
- "default": 0,
126
- "oneOf": [
127
- {
128
- "title": "Never",
129
- "enum": [
130
- 0
131
- ]
132
- },
133
- {
134
- "title": "Override default after power on",
135
- "enum": [
136
- 1
137
- ]
138
- },
139
- {
140
- "title": "Override default after power on or oscillation off",
141
- "enum": [
142
- 2
143
- ]
144
- },
145
- {
146
- "title": "Always set after power on",
147
- "enum": [
148
- 3
149
- ]
150
- },
151
- {
152
- "title": "Always set after power on or oscillation off",
153
- "enum": [
154
- 4
155
- ]
156
- }
157
- ]
158
- },
159
- "defaultVerticalSwing": {
160
- "type": "integer",
161
- "required": true,
162
- "default": 0,
163
- "oneOf": [
164
- {
165
- "title": "Device default",
166
- "enum": [
167
- 0
168
- ]
169
- },
170
- {
171
- "title": "fixed Highest",
172
- "enum": [
173
- 2
174
- ]
175
- },
176
- {
177
- "title": "fixed Higher",
178
- "enum": [
179
- 3
180
- ]
181
- },
182
- {
183
- "title": "fixed Middle",
184
- "enum": [
185
- 4
186
- ]
187
- },
188
- {
189
- "title": "fixed Lower",
190
- "enum": [
191
- 5
192
- ]
193
- },
194
- {
195
- "title": "fixed Lowest",
196
- "enum": [
197
- 6
198
- ]
199
- }
200
- ]
201
- },
202
- "defaultFanVerticalSwing": {
203
- "type": "integer",
204
- "required": true,
205
- "default": 0,
206
- "oneOf": [
207
- {
208
- "title": "Device default",
209
- "enum": [
210
- 0
211
- ]
212
- },
213
- {
214
- "title": "fixed Highest",
215
- "enum": [
216
- 2
217
- ]
218
- },
219
- {
220
- "title": "fixed Higher",
221
- "enum": [
222
- 3
223
- ]
224
- },
225
- {
226
- "title": "fixed Middle",
227
- "enum": [
228
- 4
229
- ]
230
- },
231
- {
232
- "title": "fixed Lower",
233
- "enum": [
234
- 5
235
- ]
236
- },
237
- {
238
- "title": "fixed Lowest",
239
- "enum": [
240
- 6
241
- ]
242
- }
243
- ]
244
- },
245
- "encryptionVersion" : {
246
- "type": "integer",
247
- "required": true,
248
- "default": 0,
249
- "oneOf": [
250
- {
251
- "title": "Auto",
252
- "enum": [
253
- 0
254
- ]
255
- },
256
- {
257
- "title": "v1",
258
- "enum": [
259
- 1
260
- ]
261
- },
262
- {
263
- "title": "v2",
264
- "enum": [
265
- 2
266
- ]
267
- }
268
- ]
269
- },
270
- "port": {
271
- "type": "integer",
272
- "required": false,
273
- "minimum": 1025
274
- },
275
- "ip": {
276
- "type": "string",
277
- "required": false,
278
- "format": "ipv4"
279
- },
280
- "fanControlEnabled": {
281
- "type": "boolean"
282
- }
283
- }
284
- }
285
- }
286
- }
287
- },
288
- "layout": [
289
- {
290
- "key": "name",
291
- "title": "Name:"
292
- },
293
- {
294
- "type": "flex",
295
- "flex-flow": "row wrap",
296
- "items": [
297
- {
298
- "key": "port",
299
- "flex": "1 1 50%",
300
- "title": "Port:",
301
- "description": "Platform level UDP port (auto if empty)"
302
- },
303
- {
304
- "key": "scanInterval",
305
- "flex": "1 1 50%",
306
- "title": "Scan interval:",
307
- "description": "Interval in seconds between device discovery retries (60 sec if empty)"
308
- }
309
- ]
310
- },
311
- {
312
- "type": "array",
313
- "key": "devices",
314
- "title": "Devices",
315
- "buttonText": "Add device",
316
- "expandable": true,
317
- "expanded": false,
318
- "items": [
319
- {
320
- "type": "div",
321
- "displayFlex": true,
322
- "flex-flow": "row wrap",
323
- "items": [
324
- {
325
- "key": "devices[].mac",
326
- "flex": "1 1 50%",
327
- "title": "MAC address (Serial Number):",
328
- "description": "MAC address of the device using lowercase letters and no separators<br />OR<br />special value: <b>default</b>"
329
- },
330
- {
331
- "key": "devices[].name",
332
- "flex": "1 1 50%",
333
- "title": "Device name:",
334
- "description": "Custom name of the device. Please use only alphanumeric, space, and apostrophe characters. Ensure it starts and ends with an alphabetic or numeric character, and avoid emojis.",
335
- "condition": {
336
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac));"
337
- }
338
- },
339
- {
340
- "key": "devices[].disabled",
341
- "flex": "1 1 100%",
342
- "title": "Disabled",
343
- "description": "If checked, this accessory will be removed and ignored by HomeKit",
344
- "condition": {
345
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac));"
346
- }
347
- },
348
- {
349
- "key": "devices[].ip",
350
- "flex": "1 1 50%",
351
- "title": "IP address:",
352
- "description": "Device IP address (auto if empty)",
353
- "condition": {
354
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
355
- }
356
- },
357
- {
358
- "key": "devices[].port",
359
- "flex": "1 1 50%",
360
- "title": "Port:",
361
- "description": "Device specific UDP port (auto if empty)",
362
- "condition": {
363
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
364
- }
365
- },
366
- {
367
- "key": "devices[].statusUpdateInterval",
368
- "flex": "1 1 50%",
369
- "title": "Status update interval:",
370
- "description": "Update interval (in seconds)",
371
- "condition": {
372
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
373
- }
374
- },
375
- {
376
- "key": "devices[].encryptionVersion",
377
- "flex": "1 1 50%",
378
- "title": "Network protocol encryption version:",
379
- "description": "Leave this on Auto. If Auto doesn't work then set to the desired version.",
380
- "condition": {
381
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
382
- }
383
- },
384
- {
385
- "key": "devices[].model",
386
- "flex": "1 1 50%",
387
- "title": "Device model:",
388
- "condition": {
389
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
390
- }
391
- },
392
- {
393
- "key": "devices[].speedSteps",
394
- "flex": "1 1 50%",
395
- "title": "Fan speed steps:",
396
- "condition": {
397
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
398
- }
399
- },
400
- {
401
- "key": "devices[].minimumTargetTemperature",
402
- "flex": "1 1 50%",
403
- "title": "Minimum target temperature:",
404
- "description": "Minimum target temperature (in ℃)",
405
- "condition": {
406
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
407
- }
408
- },
409
- {
410
- "key": "devices[].maximumTargetTemperature",
411
- "flex": "1 1 50%",
412
- "title": "Maximum target temperature:",
413
- "description": "Maximum target temperature (in )",
414
- "condition": {
415
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
416
- }
417
- },
418
- {
419
- "key": "devices[].sensorOffset",
420
- "flex": "1 1 50%",
421
- "title": "Temperature offset:",
422
- "description": "Temperature sensor calibration (in )",
423
- "condition": {
424
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
425
- }
426
- },
427
- {
428
- "key": "devices[].temperatureStepSize",
429
- "flex": "1 1 50%",
430
- "title": "Temperature step size:",
431
- "description": "Valid values: 0.5 (for °F) and 1 (for °C)<BR />(Calculate from Homebridge UI temperature units parameter if empty or invalid)",
432
- "condition": {
433
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
434
- }
435
- },
436
- {
437
- "key": "devices[].xFanEnabled",
438
- "flex": "1 1 50%",
439
- "title": "xFan enabled",
440
- "description": "If enabled, then xFan functionality is turned on automatically on the device",
441
- "condition": {
442
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
443
- }
444
- },
445
- {
446
- "key": "devices[].temperatureSensor",
447
- "flex": "1 1 50%",
448
- "title": "Temperature sensor:",
449
- "description": "Additional temperature sensor in Home App",
450
- "condition": {
451
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
452
- }
453
- },
454
- {
455
- "key": "devices[].modifyVerticalSwingPosition",
456
- "flex": "1 1 50%",
457
- "title": "Modify vertical position:",
458
- "description": "When to modify vertical swing position",
459
- "condition": {
460
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
461
- }
462
- },
463
- {
464
- "key": "devices[].defaultVerticalSwing",
465
- "flex": "1 1 50%",
466
- "title": "Vertical position:",
467
- "description": "Vertical swing position to be used when overriding enabled or set in heating/cooling modes",
468
- "condition": {
469
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true && model.devices[arrayIndices].modifyVerticalSwingPosition !== 0);"
470
- }
471
- },
472
- {
473
- "key": "devices[].fanControlEnabled",
474
- "flex": "1 1 50%",
475
- "title": "Fan control enabled",
476
- "description": "If checked, a fan control is added to Home App and fan mode support is enabled",
477
- "condition": {
478
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
479
- }
480
- },
481
- {
482
- "key": "devices[].defaultFanVerticalSwing",
483
- "flex": "1 1 50%",
484
- "title": "Vertical fan position:",
485
- "description": "Vertical swing position to be set in fan mode",
486
- "condition": {
487
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true && [3, 4].includes(model.devices[arrayIndices].modifyVerticalSwingPosition) && model.devices[arrayIndices].fanControlEnabled === true);"
488
- }
489
- }
490
- ]
491
- }
492
- ]
493
- }
494
- ]
495
- }
1
+ {
2
+ "pluginAlias": "GREEAirConditioner",
3
+ "pluginType": "platform",
4
+ "singular": true,
5
+ "strictValidation": false,
6
+ "schema": {
7
+ "type": "object",
8
+ "properties": {
9
+ "name": {
10
+ "type": "string",
11
+ "required": true,
12
+ "default": "GREE Air Conditioner"
13
+ },
14
+ "port": {
15
+ "type": "integer",
16
+ "required": false,
17
+ "minimum": 1025
18
+ },
19
+ "scanInterval": {
20
+ "type": "integer",
21
+ "required": false,
22
+ "default": 60,
23
+ "minimum": 5
24
+ },
25
+ "disableAutoDetection": {
26
+ "type": "boolean",
27
+ "default": false
28
+ },
29
+ "devices": {
30
+ "type": "array",
31
+ "items": {
32
+ "type": "object",
33
+ "properties": {
34
+ "mac": {
35
+ "type": "string",
36
+ "required": true,
37
+ "pattern": "^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$"
38
+ },
39
+ "name": {
40
+ "type": "string",
41
+ "required": false
42
+ },
43
+ "model": {
44
+ "type": "string",
45
+ "required": false
46
+ },
47
+ "speedSteps": {
48
+ "type": "integer",
49
+ "required": true,
50
+ "default": 5,
51
+ "oneOf": [
52
+ {
53
+ "title": "3-step model",
54
+ "enum": [
55
+ 3
56
+ ]
57
+ },
58
+ {
59
+ "title": "5-step model",
60
+ "enum": [
61
+ 5
62
+ ]
63
+ }
64
+ ]
65
+ },
66
+ "statusUpdateInterval": {
67
+ "type": "integer",
68
+ "required": false,
69
+ "minimum": 1,
70
+ "placeholder": 10
71
+ },
72
+ "sensorOffset": {
73
+ "type": "integer",
74
+ "required": false,
75
+ "placeholder": 40
76
+ },
77
+ "minimumTargetTemperature": {
78
+ "type": "integer",
79
+ "required": false,
80
+ "minimum": 8,
81
+ "placeholder": 16
82
+ },
83
+ "maximumTargetTemperature": {
84
+ "type": "integer",
85
+ "required": false,
86
+ "maximum": 30,
87
+ "placeholder": 30
88
+ },
89
+ "xFanEnabled": {
90
+ "type": "boolean",
91
+ "default": true
92
+ },
93
+ "temperatureSensor": {
94
+ "type": "string",
95
+ "required": true,
96
+ "default": "disabled",
97
+ "oneOf": [
98
+ {
99
+ "title": "Disabled",
100
+ "enum": [
101
+ "disabled"
102
+ ]
103
+ },
104
+ {
105
+ "title": "Child accessory",
106
+ "enum": [
107
+ "child"
108
+ ]
109
+ },
110
+ {
111
+ "title": "Separate accessory",
112
+ "enum": [
113
+ "separate"
114
+ ]
115
+ }
116
+ ]
117
+ },
118
+ "temperatureStepSize": {
119
+ "type": "number",
120
+ "minimum": 0.5,
121
+ "multipleOf": 0.5,
122
+ "required": false
123
+ },
124
+ "disabled": {
125
+ "type": "boolean"
126
+ },
127
+ "modifyVerticalSwingPosition": {
128
+ "type": "integer",
129
+ "required": true,
130
+ "default": 0,
131
+ "oneOf": [
132
+ {
133
+ "title": "Never",
134
+ "enum": [
135
+ 0
136
+ ]
137
+ },
138
+ {
139
+ "title": "Override default after power on",
140
+ "enum": [
141
+ 1
142
+ ]
143
+ },
144
+ {
145
+ "title": "Override default after power on or oscillation off",
146
+ "enum": [
147
+ 2
148
+ ]
149
+ },
150
+ {
151
+ "title": "Always set after power on",
152
+ "enum": [
153
+ 3
154
+ ]
155
+ },
156
+ {
157
+ "title": "Always set after power on or oscillation off",
158
+ "enum": [
159
+ 4
160
+ ]
161
+ }
162
+ ]
163
+ },
164
+ "defaultVerticalSwing": {
165
+ "type": "integer",
166
+ "required": true,
167
+ "default": 0,
168
+ "oneOf": [
169
+ {
170
+ "title": "Device default",
171
+ "enum": [
172
+ 0
173
+ ]
174
+ },
175
+ {
176
+ "title": "fixed Highest",
177
+ "enum": [
178
+ 2
179
+ ]
180
+ },
181
+ {
182
+ "title": "fixed Higher",
183
+ "enum": [
184
+ 3
185
+ ]
186
+ },
187
+ {
188
+ "title": "fixed Middle",
189
+ "enum": [
190
+ 4
191
+ ]
192
+ },
193
+ {
194
+ "title": "fixed Lower",
195
+ "enum": [
196
+ 5
197
+ ]
198
+ },
199
+ {
200
+ "title": "fixed Lowest",
201
+ "enum": [
202
+ 6
203
+ ]
204
+ }
205
+ ]
206
+ },
207
+ "defaultFanVerticalSwing": {
208
+ "type": "integer",
209
+ "required": true,
210
+ "default": 0,
211
+ "oneOf": [
212
+ {
213
+ "title": "Device default",
214
+ "enum": [
215
+ 0
216
+ ]
217
+ },
218
+ {
219
+ "title": "fixed Highest",
220
+ "enum": [
221
+ 2
222
+ ]
223
+ },
224
+ {
225
+ "title": "fixed Higher",
226
+ "enum": [
227
+ 3
228
+ ]
229
+ },
230
+ {
231
+ "title": "fixed Middle",
232
+ "enum": [
233
+ 4
234
+ ]
235
+ },
236
+ {
237
+ "title": "fixed Lower",
238
+ "enum": [
239
+ 5
240
+ ]
241
+ },
242
+ {
243
+ "title": "fixed Lowest",
244
+ "enum": [
245
+ 6
246
+ ]
247
+ }
248
+ ]
249
+ },
250
+ "encryptionVersion" : {
251
+ "type": "integer",
252
+ "required": true,
253
+ "default": 0,
254
+ "oneOf": [
255
+ {
256
+ "title": "Auto",
257
+ "enum": [
258
+ 0
259
+ ]
260
+ },
261
+ {
262
+ "title": "v1",
263
+ "enum": [
264
+ 1
265
+ ]
266
+ },
267
+ {
268
+ "title": "v2",
269
+ "enum": [
270
+ 2
271
+ ]
272
+ }
273
+ ]
274
+ },
275
+ "port": {
276
+ "type": "integer",
277
+ "required": false,
278
+ "minimum": 1025
279
+ },
280
+ "ip": {
281
+ "type": "string",
282
+ "required": false,
283
+ "format": "ipv4"
284
+ },
285
+ "fanControlEnabled": {
286
+ "type": "boolean"
287
+ },
288
+ "silentTimeRange": {
289
+ "type": "string",
290
+ "required": false,
291
+ "pattern": "^(0[0-9]|1[0-9]|2[0-3]):[0-5][0-9]-(((0[0-9]|1[0-9]|2[0-3]):[0-5][0-9])|24:00)$"
292
+ }
293
+ }
294
+ }
295
+ }
296
+ }
297
+ },
298
+ "layout": [
299
+ {
300
+ "key": "name",
301
+ "title": "Name:"
302
+ },
303
+ {
304
+ "type": "flex",
305
+ "flex-flow": "row wrap",
306
+ "items": [
307
+ {
308
+ "key": "port",
309
+ "flex": "1 1 50%",
310
+ "title": "Port:",
311
+ "description": "Platform level UDP port (auto if empty)"
312
+ },
313
+ {
314
+ "key": "scanInterval",
315
+ "flex": "1 1 50%",
316
+ "title": "Scan interval:",
317
+ "description": "Interval in seconds between device discovery retries (60 sec if empty)"
318
+ },
319
+ {
320
+ "key": "disableAutoDetection",
321
+ "flex": "1 1 100%",
322
+ "title": "Disable auto detection",
323
+ "description": "If auto detection is disabled, only the AC units listed in the devices section will be enabled"
324
+ }
325
+ ]
326
+ },
327
+ {
328
+ "type": "array",
329
+ "key": "devices",
330
+ "title": "Devices",
331
+ "buttonText": "Add device",
332
+ "expandable": true,
333
+ "expanded": false,
334
+ "items": [
335
+ {
336
+ "type": "div",
337
+ "displayFlex": true,
338
+ "flex-flow": "row wrap",
339
+ "items": [
340
+ {
341
+ "key": "devices[].mac",
342
+ "flex": "1 1 50%",
343
+ "title": "MAC address (Serial Number):",
344
+ "description": "MAC address of the device using lowercase letters and no separators<br />OR<br />special value: <b>default</b>"
345
+ },
346
+ {
347
+ "key": "devices[].name",
348
+ "flex": "1 1 50%",
349
+ "title": "Device name:",
350
+ "description": "Custom name of the device. Please use only alphanumeric, space, and apostrophe characters. Ensure it starts and ends with an alphabetic or numeric character, and avoid emojis.",
351
+ "condition": {
352
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac));"
353
+ }
354
+ },
355
+ {
356
+ "key": "devices[].disabled",
357
+ "flex": "1 1 100%",
358
+ "title": "Disabled",
359
+ "description": "If checked, this accessory will be removed and ignored by HomeKit",
360
+ "condition": {
361
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac));"
362
+ }
363
+ },
364
+ {
365
+ "key": "devices[].ip",
366
+ "flex": "1 1 50%",
367
+ "title": "IP address:",
368
+ "description": "Device IP address (auto if empty)",
369
+ "condition": {
370
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
371
+ }
372
+ },
373
+ {
374
+ "key": "devices[].port",
375
+ "flex": "1 1 50%",
376
+ "title": "Port:",
377
+ "description": "Device specific UDP port (auto if empty)",
378
+ "condition": {
379
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
380
+ }
381
+ },
382
+ {
383
+ "key": "devices[].statusUpdateInterval",
384
+ "flex": "1 1 50%",
385
+ "title": "Status update interval:",
386
+ "description": "Update interval (in seconds)",
387
+ "condition": {
388
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
389
+ }
390
+ },
391
+ {
392
+ "key": "devices[].encryptionVersion",
393
+ "flex": "1 1 50%",
394
+ "title": "Network protocol encryption version:",
395
+ "description": "Leave this on Auto. If Auto doesn't work then set to the desired version.",
396
+ "condition": {
397
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
398
+ }
399
+ },
400
+ {
401
+ "key": "devices[].model",
402
+ "flex": "1 1 50%",
403
+ "title": "Device model:",
404
+ "condition": {
405
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
406
+ }
407
+ },
408
+ {
409
+ "key": "devices[].speedSteps",
410
+ "flex": "1 1 50%",
411
+ "title": "Fan speed steps:",
412
+ "condition": {
413
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
414
+ }
415
+ },
416
+ {
417
+ "key": "devices[].minimumTargetTemperature",
418
+ "flex": "1 1 50%",
419
+ "title": "Minimum target temperature:",
420
+ "description": "Minimum target temperature (in ℃)",
421
+ "condition": {
422
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
423
+ }
424
+ },
425
+ {
426
+ "key": "devices[].maximumTargetTemperature",
427
+ "flex": "1 1 50%",
428
+ "title": "Maximum target temperature:",
429
+ "description": "Maximum target temperature (in ℃)",
430
+ "condition": {
431
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
432
+ }
433
+ },
434
+ {
435
+ "key": "devices[].sensorOffset",
436
+ "flex": "1 1 50%",
437
+ "title": "Temperature offset:",
438
+ "description": "Temperature sensor calibration (in ℃)",
439
+ "condition": {
440
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
441
+ }
442
+ },
443
+ {
444
+ "key": "devices[].temperatureStepSize",
445
+ "flex": "1 1 50%",
446
+ "title": "Temperature step size:",
447
+ "description": "Valid values: 0.5 (for °F) and 1 (for °C)<BR />(Calculate from Homebridge UI temperature units parameter if empty or invalid)",
448
+ "condition": {
449
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
450
+ }
451
+ },
452
+ {
453
+ "key": "devices[].xFanEnabled",
454
+ "flex": "1 1 50%",
455
+ "title": "xFan enabled",
456
+ "description": "If enabled, then xFan functionality is turned on automatically on the device",
457
+ "condition": {
458
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
459
+ }
460
+ },
461
+ {
462
+ "key": "devices[].temperatureSensor",
463
+ "flex": "1 1 50%",
464
+ "title": "Temperature sensor:",
465
+ "description": "Additional temperature sensor in Home App",
466
+ "condition": {
467
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
468
+ }
469
+ },
470
+ {
471
+ "key": "devices[].modifyVerticalSwingPosition",
472
+ "flex": "1 1 50%",
473
+ "title": "Modify vertical position:",
474
+ "description": "When to modify vertical swing position",
475
+ "condition": {
476
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
477
+ }
478
+ },
479
+ {
480
+ "key": "devices[].defaultVerticalSwing",
481
+ "flex": "1 1 50%",
482
+ "title": "Vertical position:",
483
+ "description": "Vertical swing position to be used when overriding enabled or set in heating/cooling modes",
484
+ "condition": {
485
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true && model.devices[arrayIndices].modifyVerticalSwingPosition !== 0);"
486
+ }
487
+ },
488
+ {
489
+ "key": "devices[].fanControlEnabled",
490
+ "flex": "1 1 50%",
491
+ "title": "Fan control enabled",
492
+ "description": "If checked, a fan control is added to Home App and fan mode support is enabled",
493
+ "condition": {
494
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
495
+ }
496
+ },
497
+ {
498
+ "key": "devices[].defaultFanVerticalSwing",
499
+ "flex": "1 1 50%",
500
+ "title": "Vertical fan position:",
501
+ "description": "Vertical swing position to be set in fan mode",
502
+ "condition": {
503
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true && [3, 4].includes(model.devices[arrayIndices].modifyVerticalSwingPosition) && model.devices[arrayIndices].fanControlEnabled === true);"
504
+ }
505
+ },
506
+ {
507
+ "key": "devices[].silentTimeRange",
508
+ "flex": "1 1 50%",
509
+ "title": "Silent time range:",
510
+ "description": "Time range when device shouldn't beep on commands received (format: HH:MM-HH:MM, e.g.: 22:00-08:00)",
511
+ "condition": {
512
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default|[a-f0-9]+@[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
513
+ }
514
+ }
515
+ ]
516
+ }
517
+ ]
518
+ }
519
+ ]
520
+ }