Change the auto-regulation last calculation
Change auto-window detection to 30 sec of delay
This commit is contained in:
@@ -12,7 +12,7 @@ from datetime import datetime
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# To filter bad values
|
||||
MIN_DELTA_T_SEC = 10 # two temp mesure should be > 10 sec
|
||||
MIN_DELTA_T_SEC = 30 # two temp mesure should be > 10 sec
|
||||
MAX_SLOPE_VALUE = 2 # slope cannot be > 2 or < -2 -> else this is an aberrant point
|
||||
|
||||
|
||||
|
||||
@@ -130,6 +130,7 @@ class ThermostatOverClimate(BaseThermostat):
|
||||
self._regulated_target_temp = self.target_temperature
|
||||
|
||||
_LOGGER.info("%s - regulation calculation will be done", self)
|
||||
self._last_regulation_change = now
|
||||
|
||||
new_regulated_temp = round_to_nearest(
|
||||
self._regulation_algo.calculate_regulated_temperature(
|
||||
@@ -154,7 +155,6 @@ class ThermostatOverClimate(BaseThermostat):
|
||||
self,
|
||||
new_regulated_temp,
|
||||
)
|
||||
self._last_regulation_change = now
|
||||
|
||||
for under in self._underlyings:
|
||||
await under.set_temperature(
|
||||
|
||||
Reference in New Issue
Block a user