From 4b3bce832cd985c53df577315033c5b1759b31bf Mon Sep 17 00:00:00 2001 From: ltadeu6 Date: Sun, 17 May 2026 20:01:21 -0300 Subject: [PATCH] Stop cooling early in laundry drying --- hosts/Nixos/configuration.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/hosts/Nixos/configuration.nix b/hosts/Nixos/configuration.nix index b74baa5..5dd6ea2 100644 --- a/hosts/Nixos/configuration.nix +++ b/hosts/Nixos/configuration.nix @@ -48,6 +48,12 @@ let inherit timeout; continue_on_timeout = true; }; + haWaitForMinTemperatureOrToggleOff = temperature: timeout: { + wait_template = + "{{ is_state('${haLaundryDryingToggle}', 'off') or (state_attr('${haAirConditioner}', 'current_temperature') | float(0)) < ${toString temperature} }}"; + inherit timeout; + continue_on_timeout = true; + }; haHoldHeatIfStillUseful = cutoffTemperature: holdTimeout: { choose = [{ conditions = [{ @@ -463,7 +469,7 @@ in { ''; }]; sequence = haCoolPulse ++ [ - (haWaitForDryingToggleOff "00:15:00") + (haWaitForMinTemperatureOrToggleOff 21 "00:15:00") { choose = [{ conditions = [{