hoffmation-base 2.21.1 → 2.22.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.
@@ -80,23 +80,27 @@ class LightGroup extends base_group_1.BaseGroup {
80
80
  const darkOutside = services_1.TimeCallbackService.darkOutsideOrNight(time);
81
81
  let resultLampen = false;
82
82
  let resultSteckdosen = false;
83
+ let activatedGroups = 0;
83
84
  if (this.getWled().length > 0) {
85
+ activatedGroups++;
84
86
  this.log(models_1.LogLevel.Debug, `Set Wled time based for time "${models_1.TimeOfDay[time]}"`);
85
87
  this.getWled().forEach((wled) => {
86
88
  wled.setTimeBased(time);
87
89
  });
88
90
  }
89
91
  if (this.getLED().length > 0) {
92
+ activatedGroups++;
90
93
  this.log(models_1.LogLevel.Trace, `Set LEDs time based for time "${models_1.TimeOfDay[time]}"`);
91
94
  this.getLED().forEach((s) => {
92
95
  s.setTimeBased(time);
93
96
  });
94
97
  }
95
- else if (this.getOutlets().length > 0) {
98
+ if (this.getOutlets().length > 0) {
99
+ activatedGroups++;
96
100
  this.log(models_1.LogLevel.Trace, `Set outlets time based for time "${models_1.TimeOfDay[time]}"`);
97
101
  resultSteckdosen = darkOutside;
98
102
  }
99
- else {
103
+ if (activatedGroups === 0) {
100
104
  this.log(models_1.LogLevel.Trace, `Set Lamps time based for time "${models_1.TimeOfDay[time]}"`);
101
105
  resultLampen = darkOutside;
102
106
  }
@@ -124,7 +124,8 @@ class ZigbeeDimmer extends index_1.ZigbeeDevice {
124
124
  }, 1000, this);
125
125
  });
126
126
  }
127
- else {
127
+ else if (this._brightness !== brightness) {
128
+ // Only set brightness if it is different from the current one
128
129
  this.setState(this._stateIdBrightness, brightness);
129
130
  }
130
131
  }
@@ -77,7 +77,7 @@ class ZigbeeLedRGBCCT extends zigbeeDimmer_1.ZigbeeDimmer {
77
77
  if (pValue && brightness === -1 && this.brightness < 10) {
78
78
  brightness = 10;
79
79
  }
80
- this.log(models_1.LogLevel.Debug, `LED Schalten An: ${pValue}\tHelligkeit: ${brightness}%\tFarbe: "${color}"\tColorTemperatur: ${colorTemp}`);
80
+ this.log(models_1.LogLevel.Debug, `LED Schalten An: ${pValue}\tHelligkeit: ${brightness}%\tFarbe: "${color}"\tColorTemperatur: ${colorTemp}\tTransition Time: ${transitionTime}`);
81
81
  const formattedColor = services_1.Utils.formatHex(color);
82
82
  if (formattedColor !== null) {
83
83
  this.ioConn.setState(this._stateIdColor, color, (err) => {
@@ -15,7 +15,6 @@ class GooveeService {
15
15
  log_service_1.ServerLogService.writeLog(models_1.LogLevel.Debug, `Initializing Goovee-Service`);
16
16
  this.all = [];
17
17
  this.goveeApi = new theimo1221_govee_lan_control_1.default({
18
- discoverInterval: 10 * 60 * 1000, // 10 minutes is enough
19
18
  logger: (message) => {
20
19
  log_service_1.ServerLogService.writeLog(models_1.LogLevel.Debug, `Govee: ${message}`);
21
20
  },