homebridge-tasmota-control 1.6.6 → 1.6.8

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "Tasmota Control",
3
3
  "name": "homebridge-tasmota-control",
4
- "version": "1.6.6",
4
+ "version": "1.6.8",
5
5
  "description": "Homebridge plugin to control Tasmota flashed devices.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",
package/src/fans.js CHANGED
@@ -103,7 +103,9 @@ class Fans extends EventEmitter {
103
103
  //update characteristics
104
104
  const lightService = this.lightServices?.[i];
105
105
  if (lightService) {
106
- lightService.updateCharacteristic(Characteristic.On, power);
106
+ const serviceName = this.lightsNamePrefix ? `${this.info.deviceName} ${friendlyName}` : friendlyName;
107
+ lightService.updateCharacteristic(Characteristic.ConfiguredName, serviceName)
108
+ .updateCharacteristic(Characteristic.On, power);
107
109
  }
108
110
 
109
111
  //fan
@@ -122,7 +124,9 @@ class Fans extends EventEmitter {
122
124
  //update characteristics
123
125
  const fanService = this.fanServices?.[i];
124
126
  if (fanService) {
125
- fanService.updateCharacteristic(Characteristic.On, powerFan)
127
+ const serviceName = this.fansNamePrefix ? `${this.info.deviceName} ${friendlyName}` : friendlyName;
128
+ fanService.updateCharacteristic(Characteristic.ConfiguredName, serviceName)
129
+ .updateCharacteristic(Characteristic.On, powerFan)
126
130
  // .updateCharacteristic(Characteristic.Direction, direction)
127
131
  .updateCharacteristic(Characteristic.RotationSpeed, speed);
128
132
  }
package/src/lights.js CHANGED
@@ -120,6 +120,8 @@ class Lights extends EventEmitter {
120
120
  //update characteristics
121
121
  const service = this.lightServices?.[i];
122
122
  if (service) {
123
+ const serviceName = this.lightsNamePrefix ? `${this.info.deviceName} ${friendlyName}` : friendlyName;
124
+ service.updateCharacteristic(Characteristic.ConfiguredName, serviceName);
123
125
  service.updateCharacteristic(Characteristic.On, power);
124
126
 
125
127
  if (brightnessType > 0) {
package/src/mielhvac.js CHANGED
@@ -849,6 +849,8 @@ class MiElHvac extends EventEmitter {
849
849
  //services
850
850
  this.miElHvacService = new Service.HeaterCooler(accessoryName, `HeaterCooler ${this.serialNumber}`);
851
851
  this.miElHvacService.setPrimaryService(true);
852
+ this.miElHvacService.addOptionalCharacteristic(Characteristic.ConfiguredName);
853
+ this.miElHvacService.setCharacteristic(Characteristic.ConfiguredName, accessoryName);
852
854
  this.miElHvacService.getCharacteristic(Characteristic.Active)
853
855
  .onGet(async () => {
854
856
  const state = this.mielHvac.power;
package/src/sensors.js CHANGED
@@ -251,7 +251,7 @@ class Sensors extends EventEmitter {
251
251
  //Prepare services
252
252
  if (this.sensorsCount > 0) {
253
253
  const debug = this.enableDebugMode ? this.emit('debug', `Prepare Sensor Services`) : false;
254
- this.emperatureServices = [];
254
+ this.temperatureServices = [];
255
255
  this.temperatureReferenceServices = [];
256
256
  this.temperatureObjServices = [];
257
257
  this.temperatureAmbServices = [];
package/src/switches.js CHANGED
@@ -86,6 +86,8 @@ class Switches extends EventEmitter {
86
86
  //update characteristics
87
87
  const service = this.lightServices?.[i];
88
88
  if (service) {
89
+ const serviceName = this.relaysNamePrefix ? `${this.info.deviceName} ${friendlyName}` : friendlyName;
90
+ service.updateCharacteristic(Characteristic.ConfiguredName, serviceName);
89
91
  service.updateCharacteristic(Characteristic.On, power);
90
92
  }
91
93