homebridge-gree-ac 2.1.7 → 2.2.0-beta.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/CHANGELOG.md CHANGED
@@ -1,5 +1,37 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.2.0] - 2025-01-??
4
+
5
+ **<ins>Reminders:</ins>**
6
+ - **All devices on the local subnet are automatically added to Homebridge since v2.1.7 Please use the "disabled" parameter to skip any device!**
7
+ - **If the fan control is disabled, the Home App interprets the device in fan mode as if it is turned off.**
8
+ - **Similarly, the dry mode is considered to be off by the Home App, because the dry mode is not supported at all.**
9
+
10
+ When upgrading from v2.0.0 - v2.1.1 to v2.1.2 or later, configuration settings should be updated.
11
+ The following configuration parameters are applied only once, when the device is enabled:
12
+ * name
13
+ * model
14
+ * speedSteps
15
+ * minimumTargetTemperature
16
+ * maximumTargetTemperature
17
+ * temperatureStepSize
18
+
19
+ Changes of the above parameters are ignored until the device is disabled and re-enabled. But keep in mind that disabling the device breaks all associated automations in Home App also.
20
+
21
+ ### New features
22
+ - Support of customized default parameters
23
+ - Support of fan mode
24
+
25
+ ### Fixes
26
+ - Minimal configuration without a "devices" entry failed to load
27
+ - Sometimes the plugin has sent multiple power commands to the device before device response
28
+ - Vertical swing position was overridden on mode change, which was not the desiged and documented behaviour
29
+ - In some cases, certain speed values ​​could not be set
30
+ - Plugin allowed sending some unsupported combination of parameters to the device
31
+
32
+ ### Updates
33
+ - In versions before v2.2.0 fan and dry modes were considered to be auto heating-cooling mode by Home App. Now - by default - these modes are considered to be off by Home App, but fan mode support can be enabled.
34
+
3
35
  ## [2.1.7] - 2024-12-27
4
36
 
5
37
  **Unlisted devices are not skipped any more if they are on the same subnet. If you want to skip them please add these devices to the configuration and set the "disabled" parameter to true!**
package/README.md CHANGED
@@ -13,19 +13,21 @@
13
13
 
14
14
  [Homebridge GREE Air Conditioner Platform Plugin](https://github.com/eibenp/homebridge-gree-airconditioner) is a dynamic platform plugin for [Homebridge](https://github.com/homebridge/homebridge) which allows control of GREE Air Conditioner devices from [Apple's Home App](https://www.apple.com/home-app/). (Makes GREE Air Conditioners HomeKit compatible.)
15
15
 
16
- The plugin finds and adds all GREE Air Conditioner devices to the Home App automatically if they are located on the same subnet as Homebridge. In most cases only a minimal configuration is required. If default configuration is not appropriate the parameters can be customized. To customize a device you have to specify it's MAC address. Each device appears in the Home App as a Heater Cooler device. It is also possible to add a separate Temperature Sensor (if temperature sensor is supported by the physical device). This allows to define automations (e.g. turn on) based on current temperature in the room. _Be careful, if the device does not support internal temperature sensor but is added as a separate accessory, Home App will use the target temperature not the measured one._ Child accessory does not appear in Home App if physical sensor is not available in the AC unit.
16
+ The plugin finds and adds all GREE Air Conditioner devices to the Home App automatically if they are located on the same subnet as Homebridge. In most cases only a minimal configuration is required. If default configuration is not appropriate, then the parameters can be customized. To set some parameters to a custom value assigned to all devices, a special device has to be added to the configuration with MAC address set to 'default'. To customize a specific device you have to specify it's MAC address. Device specific parameters override the default parameters. Each Air Conditioner device appears in the Home App as a Heater Cooler device (and a Fan device if fan control is enabled). It is also possible to add a separate Temperature Sensor accessory to Home App (if temperature sensor is supported by the physical device). This allows to define automations (e.g. turn on) based on current temperature in the room. _Be careful, if the device does not support internal temperature sensor but is added as a separate accessory, Home App will use the target temperature not the measured one._ Child accessory does not appear in Home App if physical sensor is not available in the AC unit.
17
17
 
18
- Quiet / Auto / Powerful mode is supported by the fan speed control. Zero means off. Minimum value turns on Quiet mode. Next value is Auto mode. Maximum value is Powerful mode. All other values between them are exact fan speeds (Low, MediumLow**, Medium, MediumHigh**, High)
18
+ Quiet / Auto / Powerful mode is supported by the fan speed control. In Heater Cooler accessory zero fan speed means off. Minimum value turns on Quiet mode. Next value is Auto mode. Maximum value is Powerful mode. All other values between them are exact fan speeds (Low, MediumLow**, Medium, MediumHigh**, High) Quiet and Powerful modes are unsupported in Auto mode. If these speed modes are selected in Home App then the device will fix the incorrect settings and the Home App's speed control will be automatically adjusted to the nearest supported value.
19
+
20
+ Optional fan accessory has it's own speed control. It displays fan speed as a percentage value, but the percentage displayed in the Home App is not related to the actual fan speed percentage of the AC device. (GREE Air Conditioners do not support controlling the fan speed by percentage.) Fan accessory's zero fan speed means off. Quiet mode and Powerful mode are not supported by Air Conditioner devices in fan mode. Fan accessory's maximum value (100%) means Auto mode. All other values between 0% and 100% are exact fan speeds (Low, MediumLow**, Medium, MediumHigh**, High). The actual percentage values of the Home App fan accessory is based on the AC device type (3- or 5-speed model).
19
21
 
20
22
  (**) these values are supported only on 5-speed models
21
23
 
22
- Devices are identified by MAC Address (Serial Number). It can be queried using the official [GREE+ mobile app](https://apps.apple.com/us/app/gree/id1167857672). (The app is required to connect the devices to the local WiFi network for the first time.) If you want to customize a device (e.g. set a custom name) then you have to add it to the configuration and specify it's MAC address. Adding a device located on a different subnet also requires to add the device to the configuration and specify the MAC address and the IP address. To skip a device from Home App also requires to add it's MAC address to the configuration and set the "disabled" parameter to true. Some parameters are changeable only by disabling and re-enabling the device because they are read by Home App only once. _(These parameters are discussed later.)_
24
+ Devices are identified by MAC Address (Serial Number). It can be queried using the official [GREE+ mobile app](https://apps.apple.com/us/app/gree/id1167857672). (The app is required to connect the devices to the local WiFi network for the first time.) If you want to customize a device (e.g. set a custom name) then you have to add it to the configuration and specify it's MAC address. Adding a device located on a different subnet also requires to add the device to the configuration and specify the MAC address and the IP address. To skip a device from Home App also requires to add it's MAC address to the configuration and set the "disabled" parameter to true. Some parameters are changeable only by disabling and re-enabling the device because they are read by Home App only once. _(These parameters are discussed later.)_ To customize all devices on the same way, a special device has to be added to the configuration. This special device must have the MAC address parameter set to "default". Parameters of devices identified by exact MAC addresses take precedence over parameters set by the "default" device.
23
25
 
24
26
  xFan function is supported, but it works automatically if enabled in Homebridge configuration. If xFan is enabled for the device, it is automatically turned on when you select a supported operating mode in Home App. If xFan is disabled, the Home App will not modify its actual setting in any case.
25
27
 
26
28
  Temperature display units of the physical device can be controlled using the Home App. (Configuration settings are required to be specified always in Degrees Celsius, independently from the display units.)
27
29
 
28
- Vertical swing mode can be turned on/off, but special swing settings can't be controlled using the Home App. If device default vertical swing position is not acceptable in disabled swing mode, it can be overridden to a pre selected position by configuration settings. (Only default position is overridden when this feature is enabled. Other positions selected by remote control are kept and not modified by Home App. The AC unit may keep the actual vertical swing position on turning off oscillation in Home App.)
30
+ Vertical swing mode can be turned on/off, but special swing settings can't be controlled using the Home App. If device default vertical swing position is not acceptable when oscillation is disabled, it can be overridden to a pre selected position by configuration settings. (Only default position is overridden when this feature is enabled. Other positions selected by remote control are kept and not modified by Home App.)
29
31
 
30
32
  This plugin is designed to be as simple and clear as possible and supports primarily the functions of the Home App's Heater Cooler accessory.
31
33
 
@@ -46,16 +48,19 @@ This is not plugin dependency but its good to know that Homebridge server host a
46
48
  * May work with other GREE compatible AC units (e.g. Sinclair)
47
49
  * Successfully tested with Sinclair SIH-13BITW
48
50
 
49
- > If you get _"error:1C80006B:Provider routines::wrong final block length"_ error message then your device is not supported.
51
+ > If you get _"error:1C80006B:Provider routines::wrong final block length"_ error message then your device is not supported or incorrect encryption version is selected.
50
52
  >
51
53
  > If you get _"Error: Device is not bound ..."_ error message then your device may not be supported. (The same error occures when device is malfunctioning but if turning the power supply off and on does not solve the problem then your device is not supported.)
52
54
 
55
+ It is not recommended to use Home App and the Official GREE+ or Ewpe Smart mobile apps side by side. In some cases the mobile apps can set the Air Conditioner device into a restricted state where Homebridge can't bind the plugin to the device because the device does not respond on device query requests which are required to initalize the plugin. It is highly recommended to use the mobile app only for the initial setup of the air conditioner, and later it is fine to use only the Home App and the physical remote control for everyday tasks. (Usually when the AC device is not responding to the Homebridge plugin but is communicating fine with the mobile app, then power cycling the AC device resolves the problem.)
56
+
53
57
  By default this plugin tries to auto detect the network protocol encryption version. If not the right version is selected there can get errors and the AC device will not correctly work. It is possible to force a network protocol encryption version in configuration file. If auto detection does not work then it is recommended to try all possible values to check if the device is compatible or not.
54
58
 
55
59
  ## Known limitations
56
60
 
57
61
  This plugin was designed to support the Home App's Heater Cooler functionality using GREE Air Conditioners. Some special features of GREE AC's are not supported natively by Apple and also dismiss support in this plugin.
58
- * Fan and dry modes are not supported. They may work if set directly on the device until you change operating mode. They can't be turned on using Home App.
62
+ * Fan mode is supported by an additional Fan control accessory in Home App. Using this Fan control is optional. If Fan control is disabled, the Home App sees the AC device operating in fan mode as off. The Heater Cooler accessory and the Fan accessory cannot be active at the same time. The Heater Cooler accessory is always inactive if the AC device is operating in fan mode, and the Fan accessory is always inactive if the AC device is operating in heating or cooling mode.
63
+ * Dry mode is not supported. The Home App sees the AC device operating in dry mode as off.
59
64
  * Lights of the AC unit can't be controlled.
60
65
  * Additional device functions (e.g. health mode, sleep, SE) are not supported.
61
66
  * Horizontal swing control is not supported, it remains the same as set directly on the device.
@@ -72,17 +77,20 @@ Command line install:
72
77
  ```
73
78
  npm install homebridge-gree-ac -g
74
79
  ```
75
- If successfully installed and configured, your devices will appear on the Homebridge GUI Accessories page and also in Home App (if Homebridge is already connected to the Home App). (If the additional temperature sensor is enabled, then 2 items will be displayed for supported devices (Heater Cooler and Temperature Sensor).)
80
+ If successfully installed and configured, your devices will appear on the Homebridge GUI Accessories page and also in Home App (if Homebridge is already connected to the Home App). (If the additional temperature sensor is enabled, then 2 items will be displayed for supported devices (Heater Cooler and Temperature Sensor). If Fan control is enabled, then an additional Fan accessory is also displayed in Home App.)
76
81
 
77
82
  ## Upgrade
78
83
 
79
84
  Always check out your current settings in Homebridge and also in Home App (including scenes and automation rules) before you start an upgrade!
80
85
 
81
- ### Any version to v2.1.7
86
+ ### Any version to v2.1.7 - v2.2.0
82
87
 
83
- The upgrade is automatic by installing the latest version. If upgrading from v2.1.6 no configuration changes are needed. Please see the following upgrade sections if upgrading from an earlier version.
88
+ The upgrade is automatic by installing the latest version. If upgrading from v2.1.6 or later no configuration changes are needed to continue the use of the plugin with original settings. Please see the following upgrade sections if upgrading from an earlier version.
84
89
 
85
- **Important change: All devices are automatically added to Home App if they are not listed and disabled in configuration and they are located on the same subnet.** Earlier versions skipped the devices which were not found in configuration file.
90
+ Fan mode support is new in version v2.2.0. It is disabled by default. To enable it the "fanControlEnabled" parameter must be set in configuration file.
91
+ In v2.2.0 it is also possible to set default customized parameters for multiple devices by adding a special device with MAC address set to 'default'. To use this feature it is required to update the plugin's configuration.
92
+
93
+ **Important change: All devices are automatically added to the Home App if they are not listed and disabled in configuration and they are located on the same subnet.** Earlier versions skipped the devices which were not found in configuration file.
86
94
 
87
95
  ### v2.1.2 - v2.1.5 to v2.1.6
88
96
 
@@ -151,6 +159,8 @@ The upgrade is automatic by installing the latest version but configuration sett
151
159
  - Restart Homebridge
152
160
  - If any device was disabled and re-enabled in previous steps then recreate automations _(automations are lost when you disable a device)_
153
161
 
162
+ Some new parameters were introduced in version v2.2.0. They have to be added to configuration if the new features should be turned on.
163
+
154
164
  ### v1.x.x to v2.0.0 or later
155
165
 
156
166
  There is no clean way to update the plugin to release v2.0.0 or later if you are using an older version (v1.x.x). You need to remove and reinstall the plugin during upgrade.
@@ -175,7 +185,7 @@ Minimal configuration requires no special knowledge and uses default values for
175
185
  "platforms": [
176
186
  {
177
187
  "name": "Gree Air Conditioner",
178
- "platform": "GREEAirConditioner",
188
+ "platform": "GREEAirConditioner"
179
189
  }
180
190
  ]
181
191
  ```
@@ -183,12 +193,58 @@ Minimal configuration requires no special knowledge and uses default values for
183
193
  * name - Unique name of the platform plugin
184
194
  * platform - **GREEAirConditioner** (fixed name, it identifies the plugin)
185
195
 
186
- Minimal configuration is appropriate for 5-speed models. Device names are read from the AC units (usually the MAC address or part of the MAC address). Target temperature can be set between 16 and 30 °C. The temperature display units settings are read from the UI settings (or using Fahrenheit if not set in UI configuration). Target temperature step size is set to 0.5 in Fahrenheit mode and 1 in Celsius mode. xFan function is enabled. No other special features (e.g. additional temperature sensor) are enabled.
196
+ Minimal configuration is appropriate for 5-speed models. Device names are read from the AC units (usually the MAC address or part of the MAC address). Target temperature can be set between 16 and 30 °C. The temperature display units settings are read from the UI settings (or using Fahrenheit if not set in UI configuration). Target temperature step size is set to 0.5 in Fahrenheit mode and 1 in Celsius mode. xFan function is enabled. No other special features (e.g. additional temperature sensor, fan mode support) are enabled.
187
197
 
188
198
  Minimal configuration:
189
199
 
190
200
  ![Homebridge UI](./uiconfigmin.jpg)
191
201
 
202
+ ### Customized default parameters
203
+
204
+ It is possible to set some or all parameters to a customized value which is assigned to each device which does not override the parameter. This functionality requires a custom device with MAC address set to 'default'.
205
+
206
+ ```
207
+ "platforms": [
208
+ {
209
+ "name": "Gree Air Conditioner",
210
+ "platform": "GREEAirConditioner",
211
+ "devices": [
212
+ {
213
+ "mac": "default",
214
+ "statusUpdateInterval": 10,
215
+ "encryptionVersion": 0,
216
+ "model": "Pulse 3.2kW GWH12AGB-K6DNA1A/I",
217
+ "speedSteps": 5,
218
+ "minimumTargetTemperature": 16,
219
+ "maximumTargetTemperature": 30,
220
+ "sensorOffset": 40,
221
+ "temperatureStepSize": 1,
222
+ "temperatureSensor": "disabled",
223
+ "xFanEnabled": true,
224
+ "overrideDefaultVerticalSwing": 0,
225
+ "defaultVerticalSwing": 0,
226
+ "fanControlEnabled": false,
227
+ "disabled": false
228
+ }
229
+ ]
230
+ }
231
+ ]
232
+ ```
233
+
234
+ * mac - this parameter has a special fixed value 'default' if you want to customize parameters to be assigned to multiple devices
235
+ * disabled - if set to 'true' then no parameters are read from the configuration as customized defaults
236
+
237
+ See the [Full configuration section](#full-configuration) for more information about the parameters!
238
+
239
+ The following parameters are ignored in 'default' device entry:
240
+ - name
241
+ - ip
242
+ - port
243
+
244
+ ![Homebridge UI](./uiconfigcustdef.jpg)
245
+
246
+ You can always override any default parameter by adding a device identified by MAC address.
247
+
192
248
  ### Full configuration
193
249
 
194
250
  ```
@@ -216,6 +272,7 @@ Minimal configuration:
216
272
  "xFanEnabled": true,
217
273
  "overrideDefaultVerticalSwing": 0,
218
274
  "defaultVerticalSwing": 0,
275
+ "fanControlEnabled": false,
219
276
  "disabled": false
220
277
  }
221
278
  ]
@@ -224,30 +281,31 @@ Minimal configuration:
224
281
  ```
225
282
  _It's not recommended to add the port and ip parameters. The above example contains them but only for showing all optional parameters also._
226
283
 
227
- * name - Unique name of the platform plugin
228
- * platform - **GREEAirConditioner** (fixed name, it identifies the plugin)
229
- * port - free UDP port (optional) (plugin will use this port for network communication; valid values: 1025 - 65535) **Do not specify a port unless you have trouble with automatic port assignment!**
230
- * scanInterval - time period in seconds between device query retries (defaults to 60 sec if missing)
231
- * devices - devices should be listed in this block (specify as many devices as you want to customize or disable)
232
- * mac - MAC address (Serial Number) of the device (required to identify the device, also if only one device exists)
233
- * name* - custom name of the device (optional) Please use only alphanumeric, space, and apostrophe characters. Ensure it starts and ends with an alphabetic or numeric character, and avoid emojis. (The name is changeable in Home App and any changes made in Home App are kept until the device is disabled which removes it from Home App.)
234
- * ip - device IP address (optional) Address is auto detected if this parameter is missing. **Specify only if device is located on a different subnet then homebridge!**
235
- * port - free UDP port (optional) (plugin will listen on this port for data received from the device; valid values: 1025 - 65535) **Do not specify a port unless you have trouble with automatic port assignment!**
236
- * statusUpdateInterval - device status will be refreshed based on this interval (in seconds, default is 10 seconds)
237
- * encryptionVersion - Auto (0) is fine for most AC units. If auto does not work then you can force v1 (1) or v2 (2) encryption version to use in network communication
238
- * model* - model name, information only (optional)
239
- * speedSteps* - fan speed steps of the unit (valid values are: 3 and 5)
240
- * minimumTargetTemperature* - minimum target temperature accepted by the device (default is 16 °C, must be specified in °C, valid values: 8-30, values less than 16 work only in heating mode and on selected models only)
241
- * maximumTargetTemperature* - maximum target temperature accepted by the device (default is 30 °C, must be specified in °C, valid values: 8-30, values less than 16 work only in heating mode and on selected models only)
242
- * sensorOffset - device temperature sensor offset value for current temperature calibration (default is 40 °C, must be specified in °C)
243
- * temperatureStepSize* - numeric parameter, valid values: 0.5 and 1 (if missing then default value is based on the UI configuration: 0.5 if UI is set to Fahrenheit temperature units and 1 if UI is set to Celsius temperature units) Controls the acceptable temperature values in Home App (It is recommended to set it to 1 if Celsius display mode is used on the AC unit and 0.5 in Fahrenheit display mode.)
244
- * temperatureSensor - controls additional temperature sensor accessory in Home App (disabled = do not add to Home App / child = add as a child accessory / separate = add as a separate (independent) accessory)
245
- * xFanEnabled - automatically turn on xFan functionality in supported device modes (xFan actual setting is not modified by the Home App if disabled)
246
- * overrideDefaultVerticalSwing - by default this plugin does not change the vertical swing position of the AC unit but some devices do not keep the original vertical position set by the remote control if controlled from Homebridge and return back to device default position; this setting allows to override the default position -> if AC unit is set to default vertical swing position Homebridge modifies it to a predefined position (set by defaultVerticalSwing) (Never (0) = turn off override, let device use default / After power on (1) = override default position on each power on / After power on and swing disable (2) = override default position on each power on and each time when swing is switched to disabled)
247
- * defaultVerticalSwing - specify the vertical swing position to be used instead of device default when overriding is enabled (Device default (0) = use device default, same position as used by device by default without overriding / one of the following 5 positions: fixed Highest (2), fixed Higher (3), fixed Middle (4), fixed Lower (5), fixed Lowest (6))
248
- * disabled - set to true if you do not want to control this device in the Home App _(can be used also to temporarily remove the device from Home App but not if the device is not responding any more on the network)_
249
-
250
- (*) these parameters are initalized only once on device enable; device must be disabled an re-enabled to apply a new value
284
+ * **name** - Unique name of the platform plugin
285
+ * **platform** - **GREEAirConditioner** (fixed name, it identifies the plugin)
286
+ * **port** - free UDP port (optional) (plugin will use this port for network communication; valid values: 1025 - 65535) **Do not specify a port unless you have trouble with automatic port assignment!**
287
+ * **scanInterval** - time period in seconds between device query retries (defaults to 60 sec if missing)
288
+ * **devices** - devices should be listed in this block (specify as many devices as you want to customize or disable)
289
+ * **mac** - MAC address (Serial Number) of the device (required to identify the device, also if only one device exists) Use the 'default' keyword instead of the MAC address to define default configuration for multiple devices. **Must be unique across all devices!**
290
+ * **name*** - custom name of the device (optional) Please use only alphanumeric, space, and apostrophe characters. Ensure it starts and ends with an alphabetic or numeric character, and avoid emojis. (The name is changeable in Home App and any changes made in Home App are kept until the device is disabled which removes it from Home App.)
291
+ * **ip** - device IP address (optional) Address is auto detected if this parameter is missing. **Specify only if device is located on a different subnet than homebridge!**
292
+ * **port** - free UDP port (optional) (plugin will listen on this port for data received from the device; valid values: 1025 - 65535) **Do not specify a port unless you have trouble with automatic port assignment!**
293
+ * **statusUpdateInterval** - device status will be refreshed based on this interval (in seconds, default is 10 seconds)
294
+ * **encryptionVersion** - Auto (0) is fine for most AC units. If auto does not work then you can force v1 (1) or v2 (2) encryption version to use in network communication
295
+ * **model*** - model name, information only (optional)
296
+ * **speedSteps*** - fan speed steps of the unit (valid values are: 3 and 5)
297
+ * **minimumTargetTemperature*** - minimum target temperature accepted by the device (default is 16 °C, must be specified in °C, valid values: 8-30, values less than 16 work only in heating mode and on selected models only)
298
+ * **maximumTargetTemperature*** - maximum target temperature accepted by the device (default is 30 °C, must be specified in °C, valid values: 8-30, values less than 16 work only in heating mode and on selected models only)
299
+ * **sensorOffset** - device temperature sensor offset value for current temperature calibration (default is 40 °C, must be specified in °C)
300
+ * **temperatureStepSize*** - numeric parameter, valid values: 0.5 and 1 (if missing then default value is based on the UI configuration: 0.5 if UI is set to Fahrenheit temperature units and 1 if UI is set to Celsius temperature units) Controls the acceptable temperature values in Home App (It is recommended to set it to 1 if Celsius display mode is used on the AC unit and 0.5 in Fahrenheit display mode.)
301
+ * **temperatureSensor** - controls additional temperature sensor accessory in Home App (disabled = do not add to Home App / child = add as a child accessory / separate = add as a separate (independent) accessory) _Only independent accessories can be used by automations to control other accessories._
302
+ * **xFanEnabled** - automatically turn on xFan functionality in supported device modes (xFan actual setting is not modified by the Home App if disabled)
303
+ * **overrideDefaultVerticalSwing** - by default this plugin sets the vertical swing position to the default position of the AC device when oscillation is turned off; this parameter allows the plugin to override the default position (the actual position is controlled by the "defaultVerticalSwing" parameter); valid values: Never (0) = turn off override, let device use default / After power on (1) = override the default position each time the device is powered on / After power on and swing disable (2) = override the default position each time the device is powered on and when oscillation is turned off (by the Home App)
304
+ * **defaultVerticalSwing** - specify the vertical swing position to be used instead of device default when overriding is enabled (Device default (0) = use device default, same position as used by device by default without overriding / one of the following 5 positions: fixed Highest (2), fixed Higher (3), fixed Middle (4), fixed Lower (5), fixed Lowest (6)) _(Only the default position is changing to the selected one when turning on the device. All other positions are kept by the Home App. Turning off oscillation sets the selected fixed position.)_
305
+ * **fanControlEnabled** - by default fan mode is not supported by the plugin because Apple's Heater Cooler accessory does not support fan mode; setting this parameter to true adds an additional Fan accessory to the Home App and turns on fan mode support in the plugin
306
+ * **disabled** - set to true if you do not want to control this device in the Home App _(can be used also to temporarily remove the device from Home App but not if the device is not responding on the network any more)_
307
+
308
+ (*) these parameters are initalized only once on device enable; device must be disabled an re-enabled to apply a new value; name is customizable in Home App independently from Homebridge settings
251
309
 
252
310
  Recommended customized configuration:
253
311
 
@@ -270,12 +328,18 @@ If you are not familiar with the GREE+ mobile app there is an alternative method
270
328
  - (Re)start Homebridge
271
329
  - GREE Air Conditioner Platform Plugin will auto detect all accessible devices and write an entry to the log
272
330
 
273
- Unfortunaltely if you have multiple devices you will not know which MAC address belongs to which AC unit. In this case you have to test it. This may require some adding - removal - re-adding cycle before final configuration if default configuration is not appropriate.
331
+ E.g.:
332
+
333
+ > [2025. 01. 05. 22:48:52] [Gree Air Conditioner] [c6000000 -- 192.168.1.2] Device is bound -> 502cc6000000
334
+
335
+ The MAC address is visible at the end of the "Device is bound" entry. 502cc6000000 in the above example.
336
+
337
+ Unfortunaltely if you have multiple devices you will not know which MAC address belongs to which AC unit. In this case you have to test it. This may require some adding - removal - re-adding cycle before final configuration if default or customized default configuration is not appropriate.
274
338
 
275
339
  ### Device settings
276
340
 
277
341
  Some settings are initialized by Home App only once (when enabling the device). They can only be changed by disabling and re-enabling the device. The following settings are affected:
278
- * name
342
+ * name*
279
343
  * model
280
344
  * speedSteps
281
345
  * minimumTargetTemperature
@@ -284,13 +348,15 @@ Some settings are initialized by Home App only once (when enabling the device).
284
348
 
285
349
  Changes of the above parameters are ignored until the device is disabled and re-enabled.
286
350
 
351
+ (*) name can be customized and changed in Home App any time independently from Homebridge settings
352
+
287
353
  All other settings are applied when starting up Homebridge. You have to restart Homebridge to apply changes in configuration settings.
288
354
 
289
- __Keep in mind that disabling the device breaks all associated automations in Home App.__
355
+ _Keep in mind that disabling the device breaks all associated automations in Home App._
290
356
 
291
357
  ### IP address
292
358
 
293
- IP addresses of the AC units are determined automatically by the plugin. However this auto detection works only if the AC unit is on the same subnet as homebridge. There is an optional IP address parameter which can be used to specifiy the unit's IP address if it is on a different subnet. (Routing should be correctly set up to communicate with units on different subnets.)
359
+ IP addresses of the AC units are determined automatically by the plugin. However this auto detection works only if the AC unit is on the same subnet as homebridge. There is an optional IP address parameter which can be used to specifiy the unit's IP address if it is on a different subnet. _(Routing should be correctly set up to communicate with units on different subnets.)_
294
360
 
295
361
  ### Port
296
362
 
@@ -305,7 +371,7 @@ All ports are set up automatically by default. In some cases auto detection is n
305
371
 
306
372
  Home App allows to set the device temperature display units but it is independent from the temperature units shown in Home App. Home App always displays temperature values as specified by iOS/iPadOS/MacOS (can be changed in Preferences / Regional settings section). Display unit conversion is made by the Home App device (e.g. iPhone).
307
373
 
308
- GREE Air Conditioners do not support displaying decimals of temperature values. If you normally use the AC unit in Celsius display mode then it is recommended to use also the Home App device (e.g. iPhone) in Celsius mode and set the temperatureStepSize parameter to 1. Fahrenheit mode recommends the same consistency (Fahrenheit mode on both sides and temperatureStepSize parameter set to 0.5) This helps to avoid displaying inconsistent values on the connected devices. In minimal configuration - when the device is not listed in the configuration file - the temperatureStepSize parameter is based on the Homebridge UI configuration (temperature units parameter).
374
+ GREE Air Conditioners do not support displaying decimals of temperature values. If you normally use the AC unit in Celsius display mode then it is recommended to use also the Home App device (e.g. iPhone) in Celsius mode and set the "temperatureStepSize" parameter to 1. Fahrenheit mode recommends the same consistency (Fahrenheit mode on both sides and "temperatureStepSize" parameter set to 0.5) This helps to avoid displaying inconsistent values on the connected devices. In minimal configuration - when the device is not listed in the configuration file - the "temperatureStepSize" parameter is based on the Homebridge UI configuration (temperature units parameter). This is also true for all configurations where "temperatureStepSize" parameter is not specified in the configuration file.
309
375
 
310
376
  ### Temperature measurement
311
377
 
@@ -317,14 +383,26 @@ Some AC units have a built-in temperature sensor but the actual room temperature
317
383
 
318
384
  ### Fan speed
319
385
 
386
+ #### Fan speed in heating or cooling mode
387
+
320
388
  Fan speed is adjustable on the Heater Cooler's settings page in Home App. There is a gear icon in the buttom right corner of the Heater Cooler page if it was opened from the Home App (gear icon is missing if opened from control center or home view of control center). This gear icon can be used to access settings (and fan speed).
321
389
 
322
390
  ![Home App Heater Cooler settings](./ha_settings.jpg)
323
391
 
324
- Slider description: Zero means off. Minimum value turns on Quiet mode. Next value is Auto mode. Maximum value is Powerful mode. All other values between them are exact fan speeds (Low, MediumLow**, Medium, MediumHigh**, High)
392
+ Slider description: Zero means off. Minimum value turns on Quiet mode. Next value is Auto mode. Maximum value is Powerful mode. All other values between them are exact fan speeds (Low, MediumLow**, Medium, MediumHigh**, High) Quiet and Powerful modes are unsupported in Auto mode. If these speed modes are selected in Home App then the device will fix the incorrect settings and the Home App's speed control will be automatically adjusted to the nearest supported value.
325
393
 
326
394
  (**) these values are supported only on 5-speed models
327
395
 
396
+ #### Fan speed in fan mode
397
+
398
+ Fan speed in fan mode is adjustable directly by the Fan accessory in Home App. It displays fan speed as a percentage value, but the percentage displayed in the Home App is not related to the actual fan speed percentage of the AC device. (GREE Air Conditioners do not support controlling the fan speed by percentage.) Fan accessory's zero fan speed means off. Quiet mode and Powerful mode are not supported by Air Conditioner devices in fan mode. Fan accessory's maximum value (100%) means Auto mode. All other values between 0% and 100% are exact fan speeds (Low, MediumLow**, Medium, MediumHigh**, High). The actual percentage values of the Home App fan accessory is based on the AC device type (3- or 5-speed model).
399
+
400
+ (**) these values are supported only on 5-speed models
401
+
402
+ Fan mode active and speed set to auto:
403
+
404
+ ![Home App Fan](./ha_fan.jpg)
405
+
328
406
  ### Accessory removal
329
407
 
330
408
  If an AC unit is still working and accessible on the network you can remove the associated accessory by setting the device's "disabled" parameter to true and restarting Homebridge.
@@ -29,7 +29,7 @@
29
29
  "mac": {
30
30
  "type": "string",
31
31
  "required": true,
32
- "pattern": "^[a-f0-9]{12}$"
32
+ "pattern": "^[a-f0-9]{12}|default$"
33
33
  },
34
34
  "name": {
35
35
  "type": "string",
@@ -221,6 +221,9 @@
221
221
  "type": "string",
222
222
  "required": false,
223
223
  "format": "ipv4"
224
+ },
225
+ "fanControlEnabled": {
226
+ "type": "boolean"
224
227
  }
225
228
  }
226
229
  }
@@ -267,21 +270,24 @@
267
270
  "key": "devices[].mac",
268
271
  "flex": "1 1 50%",
269
272
  "title": "MAC address (Serial Number):",
270
- "description": "MAC address of the device using lowercase letters and no separators"
273
+ "description": "MAC address of the device using lowercase letters and no separators<br />OR<br />special value: <b>default</b>"
271
274
  },
272
275
  {
273
276
  "key": "devices[].name",
274
277
  "flex": "1 1 50%",
275
278
  "title": "Device name:",
276
- "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."
279
+ "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.",
280
+ "condition": {
281
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac));"
282
+ }
277
283
  },
278
284
  {
279
285
  "key": "devices[].disabled",
280
286
  "flex": "1 1 100%",
281
287
  "title": "Disabled",
282
- "description": "If checked, this accessory will be removed and ignored from HomeKit.",
288
+ "description": "If checked, this accessory will be removed and ignored by HomeKit",
283
289
  "condition": {
284
- "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}$/.test(model.devices[arrayIndices].mac));"
290
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac));"
285
291
  }
286
292
  },
287
293
  {
@@ -308,7 +314,7 @@
308
314
  "title": "Status update interval:",
309
315
  "description": "Update interval (in seconds)",
310
316
  "condition": {
311
- "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);"
317
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
312
318
  }
313
319
  },
314
320
  {
@@ -317,7 +323,7 @@
317
323
  "title": "Network protocol encryption version:",
318
324
  "description": "Leave this on Auto. If Auto doesn't work then set to the desired version.",
319
325
  "condition": {
320
- "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);"
326
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
321
327
  }
322
328
  },
323
329
  {
@@ -325,7 +331,7 @@
325
331
  "flex": "1 1 50%",
326
332
  "title": "Device model:",
327
333
  "condition": {
328
- "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);"
334
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
329
335
  }
330
336
  },
331
337
  {
@@ -333,7 +339,7 @@
333
339
  "flex": "1 1 50%",
334
340
  "title": "Fan speed steps:",
335
341
  "condition": {
336
- "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);"
342
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
337
343
  }
338
344
  },
339
345
  {
@@ -342,7 +348,7 @@
342
348
  "title": "Minimum target temperature:",
343
349
  "description": "Minimum target temperature (in ℃)",
344
350
  "condition": {
345
- "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);"
351
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
346
352
  }
347
353
  },
348
354
  {
@@ -351,7 +357,7 @@
351
357
  "title": "Maximum target temperature:",
352
358
  "description": "Maximum target temperature (in ℃)",
353
359
  "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);"
360
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
355
361
  }
356
362
  },
357
363
  {
@@ -360,16 +366,16 @@
360
366
  "title": "Temperature offset:",
361
367
  "description": "Temperature sensor calibration (in ℃)",
362
368
  "condition": {
363
- "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);"
369
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
364
370
  }
365
371
  },
366
372
  {
367
373
  "key": "devices[].temperatureStepSize",
368
374
  "flex": "1 1 50%",
369
375
  "title": "Temperature step size:",
370
- "description": "Valid values: 0.5 (for °F) and 1 (for °C)<BR />(0.5 if empty or invalid)",
376
+ "description": "Valid values: 0.5 (for °F) and 1 (for °C)<BR />(Calculate from Homebridge UI temperature units parameter if empty or invalid)",
371
377
  "condition": {
372
- "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);"
378
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
373
379
  }
374
380
  },
375
381
  {
@@ -378,7 +384,7 @@
378
384
  "title": "xFan enabled",
379
385
  "description": "If enabled, then xFan functionality is turned on automatically on the device",
380
386
  "condition": {
381
- "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);"
387
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
382
388
  }
383
389
  },
384
390
  {
@@ -387,7 +393,7 @@
387
393
  "title": "Temperature sensor:",
388
394
  "description": "Additional temperature sensor in Home App",
389
395
  "condition": {
390
- "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);"
396
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
391
397
  }
392
398
  },
393
399
  {
@@ -396,7 +402,7 @@
396
402
  "title": "Override default vertical position:",
397
403
  "description": "When to override vertical swing position",
398
404
  "condition": {
399
- "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);"
405
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
400
406
  }
401
407
  },
402
408
  {
@@ -405,7 +411,16 @@
405
411
  "title": "Vertical position:",
406
412
  "description": "Default vertical swing position to be used istead of what device considers a default",
407
413
  "condition": {
408
- "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 && model.devices[arrayIndices].overrideDefaultVerticalSwing !== 0);"
414
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true && model.devices[arrayIndices].overrideDefaultVerticalSwing !== 0);"
415
+ }
416
+ },
417
+ {
418
+ "key": "devices[].fanControlEnabled",
419
+ "flex": "1 1 100%",
420
+ "title": "Fan control enabled",
421
+ "description": "If checked, a fan control is added to Home App and fan mode support is enabled",
422
+ "condition": {
423
+ "functionBody": "return (model.devices && model.devices[arrayIndices] && model.devices[arrayIndices].mac && /^[a-f0-9]{12}|default$/.test(model.devices[arrayIndices].mac) && model.devices[arrayIndices].disabled !== true);"
409
424
  }
410
425
  }
411
426
  ]
@@ -1 +1 @@
1
- {"version":3,"file":"platform.d.ts","sourceRoot":"","sources":["../src/platform.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,GAAG,EAAE,qBAAqB,EAAE,MAAM,EAAE,iBAAiB,EAAE,cAAc,EAAE,OAAO,EAAE,cAAc,EAAc,MAAM,YAAY,CAAC;AAUxI,MAAM,WAAW,mBAAoB,SAAQ,iBAAiB;IAC5D,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;;;GAIG;AACH,qBAAa,cAAe,YAAW,qBAAqB;aAcxC,GAAG,EAAE,MAAM;aACX,MAAM,EAAE,cAAc;aACtB,GAAG,EAAE,GAAG;IAf1B,SAAgB,OAAO,EAAE,OAAO,OAAO,CAAwB;IAC/D,SAAgB,cAAc,EAAE,OAAO,cAAc,CAA+B;IAGpF,OAAO,CAAC,OAAO,CAAsC;IACrD,OAAO,CAAC,gBAAgB,CAA0B;IAClD,OAAO,CAAC,cAAc,CAA0B;IAChD,OAAO,CAAC,MAAM,CAAe;IAC7B,OAAO,CAAC,eAAe,CAA8B;IAC9C,KAAK,EAAE,MAAM,EAAE,CAAM;IAC5B,OAAO,CAAC,QAAQ,CAAS;gBAGP,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,cAAc,EACtB,GAAG,EAAE,GAAG;IA+C1B;;;OAGG;IACH,kBAAkB,CAAC,SAAS,EAAE,mBAAmB;IAsBjD;;;OAGG;IACH,YAAY;IAUZ,eAAe;IAUf,aAAa,iCA6CX;IAEF,cAAc,4BAgKZ;IAEF,QAAQ;IAiBR,mBAAmB;IAqDZ,YAAY,CAAC,GAAG,EAAE,MAAM;CAGhC"}
1
+ {"version":3,"file":"platform.d.ts","sourceRoot":"","sources":["../src/platform.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,GAAG,EAAE,qBAAqB,EAAE,MAAM,EAAE,iBAAiB,EAAE,cAAc,EAAE,OAAO,EAAE,cAAc,EAAc,MAAM,YAAY,CAAC;AAUxI,MAAM,WAAW,mBAAoB,SAAQ,iBAAiB;IAC5D,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED;;;;GAIG;AACH,qBAAa,cAAe,YAAW,qBAAqB;aAcxC,GAAG,EAAE,MAAM;aACX,MAAM,EAAE,cAAc;aACtB,GAAG,EAAE,GAAG;IAf1B,SAAgB,OAAO,EAAE,OAAO,OAAO,CAAwB;IAC/D,SAAgB,cAAc,EAAE,OAAO,cAAc,CAA+B;IAGpF,OAAO,CAAC,OAAO,CAAsC;IACrD,OAAO,CAAC,gBAAgB,CAA0B;IAClD,OAAO,CAAC,cAAc,CAA0B;IAChD,OAAO,CAAC,MAAM,CAAe;IAC7B,OAAO,CAAC,eAAe,CAA8B;IAC9C,KAAK,EAAE,MAAM,EAAE,CAAM;IAC5B,OAAO,CAAC,QAAQ,CAAS;gBAGP,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,cAAc,EACtB,GAAG,EAAE,GAAG;IA+C1B;;;OAGG;IACH,kBAAkB,CAAC,SAAS,EAAE,mBAAmB;IAsBjD;;;OAGG;IACH,YAAY;IAUZ,eAAe;IAUf,aAAa,iCA6CX;IAEF,cAAc,4BA4MZ;IAEF,QAAQ;IAiBR,mBAAmB;IAqDZ,YAAY,CAAC,GAAG,EAAE,MAAM;CAGhC"}