homebridge-melcloud-control 4.0.0-beta.501 → 4.0.0-beta.503

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
@@ -12,17 +12,22 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
12
12
  - v1 After update to v1 and above from v0 the devices need to be added to the Home app again and the old unresponsive remove!!! This devices will be removed from all automations and scenes!!!
13
13
  - v2 After update to v2 from v1 only RESTFull and MQTT config settings need to be updated in config.
14
14
  - v2.4 and above require upcomming homebridge v2
15
- - v3 After update to v3 the plugin need to be configured using Config UI X.
16
- - do not configure it manually, always using Config UI X
15
+ - v3 After update to v3 the plugin need to be configured using Homebridge UI.
16
+ - do not configure it manually, always using Homebridge UI
17
17
  - required Homebridge v2.0.0 and above
18
+ - v4 Added support for MELCloud Home.
18
19
 
19
- ## [4.0.0] - (xx.10.2025)
20
+ ## Warning
21
+
22
+ - Do not use Homebridge UI > v5.5.0 because of break config.json
23
+
24
+ ## [4.0.0] - (xx.11.2025)
20
25
 
21
26
  ## Changes
22
27
 
23
28
  - added support for MELCloud Home [#215](https://github.com/grzegorz914/homebridge-melcloud-control/issues/215)
24
- - redme updated
25
29
  - config schema updated
30
+ - redme updated
26
31
  - cleanup
27
32
 
28
33
  ## [3.9.5] - (02.09.2025)
package/README.md CHANGED
@@ -277,21 +277,19 @@ Homebridge plugin for Air Conditioner, Heat Pump and Energy Recovery Ventilation
277
277
  | `refreshInterval` | Here set the background account data refresh time in (sec), default `120s`. |
278
278
  | `log{}` | Log object. |
279
279
  | `log.deviceInfo` | If enabled, log device info will be displayed by every connections device to the network. |
280
- | `log.sSuccess` | If enabled, success log will be displayed in console. |
280
+ | `log.success` | If enabled, success log will be displayed in console. |
281
281
  | `log.info` | If enabled, info log will be displayed in console. |
282
282
  | `log.warn` | If enabled, warn log will be displayed in console. |
283
283
  | `log.error` | If enabled, error log will be displayed in console. |
284
284
  | `log.debug` | If enabled, debug log will be displayed in console. |
285
285
  | `restFul{}` | RSTful object. |
286
286
  | `restFul.enable` | If enabled, RESTful server will start automatically and respond to any path request. |
287
- | `restFul.debug` | If enabled, deep log will be present in homebridge console for RESTFul server. |
288
287
  | `mqtt{}` | MQTT object. |
289
288
  | `mqtt.enable` | If enabled, MQTT Broker will start automatically and publish all awailable PV data. |
290
289
  | `mqtt.host` | Here set the `IP Address` or `Hostname` for MQTT Broker. |
291
290
  | `mqtt.port` | Here set the `Port` for MQTT Broker, default 1883. |
292
291
  | `mqtt.clientId` | Here optional set the `Client Id` of MQTT Broker. |
293
292
  | `mqtt.prefix` | Here set the `Prefix` for `Topic` or leave empty. |
294
- | `mqtt.debug` | If enabled, deep log will be present in homebridge console for MQTT. |
295
293
  | `mqtt.auth{}` | MQTT authorization object. |
296
294
  | `mqtt.auth.enable` | Here enable authorization for MQTT Broker. |
297
295
  | `mqtt.auth.user` | Here set the MQTT Broker user. |
package/index.js CHANGED
@@ -200,7 +200,7 @@ class MelCloudPlatform {
200
200
  if (logLevel.success) log.success(`${accountName}, ${deviceTypeText}, ${deviceName}, Published as external accessory.`);
201
201
 
202
202
  //start impulse generators\
203
- const timmers = accountType === 'melcloudhome' ? [{ name: 'connect', sampling: 300000 }, { name: 'checkDevicesList', sampling: deviceRefreshInterval }] : [{ name: 'checkDevicesList', sampling: refreshInterval }];
203
+ const timmers = accountType === 'melcloudhome' ? [{ name: 'connect', sampling: 600000 }, { name: 'checkDevicesList', sampling: deviceRefreshInterval }] : [{ name: 'checkDevicesList', sampling: refreshInterval }];
204
204
  await melCloud.impulseGenerator.state(true, timmers);
205
205
  await configuredDevice.startStopImpulseGenerator(true, [{ name: 'checkState', sampling: deviceRefreshInterval }]);
206
206
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "MELCloud Control",
3
3
  "name": "homebridge-melcloud-control",
4
- "version": "4.0.0-beta.501",
4
+ "version": "4.0.0-beta.503",
5
5
  "description": "Homebridge plugin to control Mitsubishi Air Conditioner, Heat Pump and Energy Recovery Ventilation.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",
package/src/melcloud.js CHANGED
@@ -344,13 +344,13 @@ class MelCloud extends EventEmitter {
344
344
  page.on('close', () => { if (this.logDebug) this.emit('debug', 'Page was closed unexpectedly'); });
345
345
  browser.on('disconnected', () => { if (this.logWarn) this.emit('debug', 'Browser disconnected unexpectedly'); });
346
346
 
347
- page.setDefaultTimeout(30000);
348
- page.setDefaultNavigationTimeout(30000);
347
+ page.setDefaultTimeout(45000);
348
+ page.setDefaultNavigationTimeout(45000);
349
349
 
350
350
  // Now safe to navigate
351
351
  this.emit('warn', `Test 4`);
352
352
  await page.goto(ApiUrlsHome.BaseURL, { waitUntil: ['domcontentloaded', 'networkidle2'] });
353
- await new Promise(r => setTimeout(r, 3500));
353
+ await new Promise(r => setTimeout(r, 4000));
354
354
 
355
355
  let loginBtn;
356
356
  try {
@@ -7,7 +7,7 @@ import { ApiUrls, ApiUrlsHome, AirConditioner } from './constants.js';
7
7
  class MelCloudAta extends EventEmitter {
8
8
  constructor(account, device, devicesFile, defaultTempsFile) {
9
9
  super();
10
- this.accountType = account.type
10
+ this.accountType = account.type;
11
11
  this.deviceId = device.id;
12
12
  this.logWarn = device.log?.warn;
13
13
  this.logError = device.log?.error;
@@ -120,7 +120,6 @@ class MelCloudAta extends EventEmitter {
120
120
  return acc;
121
121
  }, { indoor: {}, outdoor: {} });
122
122
 
123
-
124
123
  //display info if units are not configured in MELCloud service
125
124
  if (unitsCount === 0) {
126
125
  if (this.logDebug) this.emit('debug', `Units are not configured in MELCloud service`);
@@ -7,7 +7,7 @@ import { ApiUrls, ApiUrlsHome, HeatPump } from './constants.js';
7
7
  class MelCloudAtw extends EventEmitter {
8
8
  constructor(account, device, devicesFile, defaultTempsFile) {
9
9
  super();
10
- this.accountType = account.type
10
+ this.accountType = account.type;
11
11
  this.deviceId = device.id;
12
12
  this.logWarn = device.log?.warn;
13
13
  this.logError = device.log?.error;
@@ -58,6 +58,10 @@ class MelCloudAtw extends EventEmitter {
58
58
  return null;
59
59
  }
60
60
  const deviceData = devicesData.find(device => device.DeviceID === this.deviceId);
61
+ if (this.accountType === 'melcloudhome') {
62
+ deviceData.SerialNumber = deviceData.Device.DeviceID || '4.0.0';
63
+ deviceData.Device.FirmwareAppVersion = '4.0.0';
64
+ }
61
65
  if (this.logDebug) this.emit('debug', `Device Data: ${JSON.stringify(deviceData, null, 2)}`);
62
66
 
63
67
  //device info
@@ -99,7 +103,7 @@ class MelCloudAtw extends EventEmitter {
99
103
  const unitsCount = units.length;
100
104
  const manufacturer = 'Mitsubishi';
101
105
 
102
- const { indoor, outdoor } = units.reduce((acc, unit) => {
106
+ const { indoor, outdoor } = units.reduce((acc, unit) => {
103
107
  const target = unit.IsIndoor ? 'indoor' : 'outdoor';
104
108
  acc[target] = {
105
109
  id: unit.ID,
@@ -7,7 +7,7 @@ import { ApiUrls, ApiUrlsHome, Ventilation } from './constants.js';
7
7
  class MelCloudErv extends EventEmitter {
8
8
  constructor(account, device, devicesFile, defaultTempsFile) {
9
9
  super();
10
- this.accountType = account.type
10
+ this.accountType = account.type;
11
11
  this.deviceId = device.id;
12
12
  this.logWarn = device.log?.warn;
13
13
  this.logError = device.log?.error;
@@ -58,6 +58,10 @@ class MelCloudErv extends EventEmitter {
58
58
  return null;
59
59
  }
60
60
  const deviceData = devicesData.find(device => device.DeviceID === this.deviceId);
61
+ if (this.accountType === 'melcloudhome') {
62
+ deviceData.SerialNumber = deviceData.Device.DeviceID || '4.0.0';
63
+ deviceData.Device.FirmwareAppVersion = '4.0.0';
64
+ }
61
65
  if (this.logDebug) this.emit('debug', `Device Data: ${JSON.stringify(deviceData, null, 2)}`);
62
66
 
63
67
  //presets