From 8739855ea208689fc608c0373cf263ced5a8851b Mon Sep 17 00:00:00 2001
From: David Woodhouse <dwmw@amazon.co.uk>
Date: Wed, 6 Sep 2023 12:33:19 +0100
Subject: [PATCH] Turn pump on/off at 7

---
 pool.yaml | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/pool.yaml b/pool.yaml
index 1b649ae..75ba9cd 100644
--- a/pool.yaml
+++ b/pool.yaml
@@ -113,6 +113,8 @@ time:
           - switch.turn_on: ble_switch
           - delay: 2min
           - switch.turn_off: ble_switch
+
+        # Watchdog for 1wire sensors to bounce power when they fail.
       - seconds: 0
         minutes: /1
         then:
@@ -134,6 +136,19 @@ time:
                 # Turn them off and on again.
                 script.execute: bounce_1w_power
 
+        # Turn pool pump on at 7am and off at 7pm
+      - seconds: 0
+        minutes: 0
+        hours: 7
+        then:
+          - switch.turn_on: pool_pump
+      - seconds: 0
+        minutes: 0
+        hours: 19
+        then:
+          - switch.turn_off: pool_pump
+
+
 ethernet:
   type: LAN8720
   mdc_pin: GPIO23
-- 
2.49.0