homebridge-melcloud-control 4.4.0-beta.23 → 4.4.0-beta.25

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/index.js CHANGED
@@ -90,7 +90,7 @@ class MelCloudPlatform {
90
90
  melcloud = new MelCloud(account, accountFile, buildingsFile, true);
91
91
  break;
92
92
  case 'melcloudhome':
93
- timmers = [{ name: 'connect', sampling: 3300000 }, { name: 'checkDevicesList', sampling: 3000 }];
93
+ timmers = [{ name: 'connect', sampling: 3300000 }, { name: 'checkDevicesList', sampling: 5000 }];
94
94
  melcloud = new MelCloudHome(account, accountFile, buildingsFile, true);
95
95
  break;
96
96
  default:
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "MELCloud Control",
3
3
  "name": "homebridge-melcloud-control",
4
- "version": "4.4.0-beta.23",
4
+ "version": "4.4.0-beta.25",
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/deviceatw.js CHANGED
@@ -1115,7 +1115,7 @@ class DeviceAtw extends EventEmitter {
1115
1115
  })
1116
1116
  .onSet(async (value) => {
1117
1117
  try {
1118
- let { min, max } = await this.functions.adjustTempProtection(deviceData.FrostProtection.Min, deviceData.FrostProtection.Max, value, 4, 14, 6, 16);
1118
+ let { min, max } = await this.functions.adjustTempProtection(deviceData.FrostProtection.Min, deviceData.FrostProtection.Max, value, 'max', 4, 14, 6, 16);
1119
1119
  deviceData.FrostProtection.Min = min;
1120
1120
  deviceData.FrostProtection.Max = max;
1121
1121
  if (this.logInfo) this.emit('info', `Set frost protection max. temperature: ${max}${this.accessory.temperatureUnit}`);
@@ -1136,7 +1136,7 @@ class DeviceAtw extends EventEmitter {
1136
1136
  })
1137
1137
  .onSet(async (value) => {
1138
1138
  try {
1139
- let { min, max } = await this.functions.adjustTempProtection(deviceData.FrostProtection.Min, deviceData.FrostProtection.Max, value, 4, 14, 6, 16);
1139
+ let { min, max } = await this.functions.adjustTempProtection(deviceData.FrostProtection.Min, deviceData.FrostProtection.Max, value, 'min', 4, 14, 6, 16);
1140
1140
  deviceData.FrostProtection.Min = min;
1141
1141
  deviceData.FrostProtection.Max = max;
1142
1142
  if (this.logInfo) this.emit('info', `Set frost protection min. temperature: ${min}${this.accessory.temperatureUnit}`);
@@ -314,7 +314,12 @@ class MelCloudAta extends EventEmitter {
314
314
  //send payload
315
315
  if (this.logDebug) this.emit('debug', `Send data: ${JSON.stringify(payload, null, 2)}`);
316
316
  await this.client(path, { method: method, data: payload });
317
- if (update) this.emit('deviceState', deviceData);
317
+
318
+ if (update) {
319
+ setTimeout(() => {
320
+ this.emit('deviceState', deviceData);
321
+ }, 500);
322
+ }
318
323
 
319
324
  return true;
320
325
  default: