The flow does this:
- Runs the pool from 1000 - 1500 in the winter and 1130 - dusk in the summer.
- If we’re in the spa, I don’t want it to automatically turn off at shutdown time, so I check to see if the spa is running and if so, keep the pool pump on.
- I wrote in an override so I can hit a button in the HA dashboard and keep the pool on or off longer for whatever reason.
I’d like to simplify the flow and run the pool pump based on pool water temperature, and also keep the override button, but not sure how to begin. This is what I’m thinking:
If the pool is <70F, pool shuts off at 1500. If the pool is >70F, pool shuts off at dusk. To read the pool temperature, the pool pump must be on, so I’m not going to modify start times.
Here’s my existing flow:
[{"id":"9a640c27f5a76bb4","type":"tab","label":"Pool","disabled":false,"info":"","env":[]},{"id":"db081c2574ca4ea6","type":"bigtimer","z":"9a640c27f5a76bb4","outtopic":"","outpayload1":"on","outpayload2":"off","name":"1130 to Dusk Apr - Oct","comment":"","lat":"12.3456","lon":"-123.45678","starttime":"690","endtime":"5001","starttime2":"0","endtime2":"0","startoff":"0","endoff":0,"startoff2":"","endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":false,"feb":false,"mar":false,"apr":true,"may":true,"jun":true,"jul":true,"aug":true,"sep":true,"oct":true,"nov":false,"dec":false,"day1":0,"month1":0,"day2":0,"month2":0,"day3":0,"month3":0,"day4":0,"month4":0,"day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":0,"xmonth1":0,"xday2":0,"xmonth2":0,"xday3":0,"xmonth3":0,"xday4":0,"xmonth4":0,"xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":"","xmonth7":"","xday8":"","xmonth8":"","xday9":"","xmonth9":"","xday10":"","xmonth10":"","xday11":"","xmonth11":"","xday12":"","xmonth12":"","xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":370,"y":280,"wires":[["37a87dce9dfbc243"],[],[]]},{"id":"37a87dce9dfbc243","type":"switch","z":"9a640c27f5a76bb4","name":"Pool pump","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"on","vt":"str"},{"t":"eq","v":"off","vt":"str"}],"checkall":"false","repair":false,"outputs":2,"x":650,"y":460,"wires":[["58229a245922ebb5"],["05c2b17efbd83a4d"]]},{"id":"58229a245922ebb5","type":"api-current-state","z":"9a640c27f5a76bb4","name":"Is pool already on? ","server":"84a8d823.e15248","version":3,"outputs":2,"halt_if":"on","halt_if_type":"str","halt_if_compare":"is","entity_id":"switch.pool_pump","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"}],"for":0,"forType":"num","forUnits":"minutes","x":830,"y":420,"wires":[[],["57f03c4f797b391c"]]},{"id":"05c2b17efbd83a4d","type":"api-current-state","z":"9a640c27f5a76bb4","name":"Is pool already off? ","server":"84a8d823.e15248","version":3,"outputs":2,"halt_if":"off","halt_if_type":"str","halt_if_compare":"is","entity_id":"switch.pool_pump","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"}],"for":0,"forType":"num","forUnits":"minutes","x":830,"y":500,"wires":[[],["137b4ec7e7c491a2"]]},{"id":"c1489b4266b9d61e","type":"api-call-service","z":"9a640c27f5a76bb4","name":"Turn off pool pump","server":"84a8d823.e15248","version":5,"debugenabled":false,"domain":"switch","service":"turn_off","areaId":[],"deviceId":[],"entityId":["switch.pool_pump"],"data":"","dataType":"json","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":1270,"y":500,"wires":[[]]},{"id":"8b0eaff0249ac9ea","type":"inject","z":"9a640c27f5a76bb4","name":"","repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"on","payloadType":"str","x":110,"y":440,"wires":[["34c5d44cfad1409b","db081c2574ca4ea6","6fb33068d0c0e888","b69cc72f263729ac","83919b42ab4d502d","8e679b789630b68d"]]},{"id":"729552bdcc8f80ed","type":"inject","z":"9a640c27f5a76bb4","name":"","repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"off","payloadType":"str","x":110,"y":480,"wires":[["34c5d44cfad1409b","db081c2574ca4ea6","6fb33068d0c0e888","b69cc72f263729ac","83919b42ab4d502d","8e679b789630b68d"]]},{"id":"41c4c2bda15e36e7","type":"inject","z":"9a640c27f5a76bb4","name":"","repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"auto","payloadType":"str","x":110,"y":520,"wires":[["34c5d44cfad1409b","8e679b789630b68d","83919b42ab4d502d","b69cc72f263729ac","6fb33068d0c0e888","db081c2574ca4ea6"]]},{"id":"34c5d44cfad1409b","type":"bigtimer","z":"9a640c27f5a76bb4","outtopic":"","outpayload1":"on","outpayload2":"off","name":"1000 to 1500 Dec - Feb","comment":"","lat":"12.3456","lon":"-123.45678","starttime":"600","endtime":"900","starttime2":"0","endtime2":"0","startoff":"0","endoff":0,"startoff2":"","endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":true,"feb":true,"mar":false,"apr":false,"may":false,"jun":false,"jul":false,"aug":false,"sep":false,"oct":false,"nov":false,"dec":true,"day1":0,"month1":0,"day2":0,"month2":0,"day3":0,"month3":0,"day4":0,"month4":0,"day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":0,"xmonth1":0,"xday2":0,"xmonth2":0,"xday3":0,"xmonth3":0,"xday4":0,"xmonth4":0,"xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":"","xmonth7":"","xday8":"","xmonth8":"","xday9":"","xmonth9":"","xday10":"","xmonth10":"","xday11":"","xmonth11":"","xday12":"","xmonth12":"","xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":370,"y":520,"wires":[["37a87dce9dfbc243"],[],[]]},{"id":"6fb33068d0c0e888","type":"bigtimer","z":"9a640c27f5a76bb4","outtopic":"","outpayload1":"on","outpayload2":"off","name":"1130 to Dusk November 1-3","comment":"","lat":"12.3456","lon":"-123.45678","starttime":"690","endtime":"5001","starttime2":"0","endtime2":"0","startoff":"0","endoff":0,"startoff2":"","endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":false,"feb":false,"mar":false,"apr":false,"may":false,"jun":false,"jul":false,"aug":false,"sep":false,"oct":false,"nov":false,"dec":false,"day1":"1","month1":"11","day2":"2","month2":"11","day3":"3","month3":"11","day4":"0","month4":"0","day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":0,"xmonth1":0,"xday2":0,"xmonth2":0,"xday3":0,"xmonth3":0,"xday4":0,"xmonth4":0,"xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":"","xmonth7":"","xday8":"","xmonth8":"","xday9":"","xmonth9":"","xday10":"","xmonth10":"","xday11":"","xmonth11":"","xday12":"","xmonth12":"","xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":380,"y":360,"wires":[["37a87dce9dfbc243"],[],[]]},{"id":"b69cc72f263729ac","type":"bigtimer","z":"9a640c27f5a76bb4","outtopic":"","outpayload1":"on","outpayload2":"off","name":"1130 to Dusk November 4-30","comment":"","lat":"12.3456","lon":"-123.45678","starttime":"600","endtime":"900","starttime2":"0","endtime2":"0","startoff":"0","endoff":0,"startoff2":"","endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":false,"feb":false,"mar":false,"apr":false,"may":false,"jun":false,"jul":false,"aug":false,"sep":false,"oct":false,"nov":true,"dec":false,"day1":"","month1":"","day2":"","month2":"","day3":"","month3":"","day4":"","month4":"","day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":"1","xmonth1":"11","xday2":"2","xmonth2":"11","xday3":"3","xmonth3":"11","xday4":"0","xmonth4":"0","xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":"","xmonth7":"","xday8":"","xmonth8":"","xday9":"","xmonth9":"","xday10":"","xmonth10":"","xday11":"","xmonth11":"","xday12":"","xmonth12":"","xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":390,"y":440,"wires":[["37a87dce9dfbc243"],[],[]]},{"id":"83919b42ab4d502d","type":"bigtimer","z":"9a640c27f5a76bb4","outtopic":"","outpayload1":"on","outpayload2":"off","name":"1000 to 1500 March 1-20","comment":"","lat":"12.3456","lon":"-123.45678","starttime":"600","endtime":"900","starttime2":"0","endtime2":"0","startoff":"0","endoff":0,"startoff2":"","endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":false,"feb":false,"mar":true,"apr":false,"may":false,"jun":false,"jul":false,"aug":false,"sep":false,"oct":false,"nov":false,"dec":false,"day1":"0","month1":"0","day2":"0","month2":"0","day3":"0","month3":"0","day4":"0","month4":"0","day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":"21","xmonth1":"3","xday2":"22","xmonth2":"3","xday3":"23","xmonth3":"3","xday4":"24","xmonth4":"3","xday5":"25","xmonth5":"3","xday6":"26","xmonth6":"3","xday7":"27","xmonth7":"3","xday8":"28","xmonth8":"3","xday9":"29","xmonth9":"3","xday10":"30","xmonth10":"3","xday11":"31","xmonth11":"3","xday12":"","xmonth12":"","xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":370,"y":600,"wires":[["37a87dce9dfbc243"],[],[]]},{"id":"8e679b789630b68d","type":"bigtimer","z":"9a640c27f5a76bb4","outtopic":"","outpayload1":"on","outpayload2":"off","name":"1130 to Dusk March 21-31","comment":"","lat":"12.3456","lon":"-123.45678","starttime":"690","endtime":"5001","starttime2":"0","endtime2":"0","startoff":"0","endoff":0,"startoff2":"","endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":1440,"sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":false,"feb":false,"mar":false,"apr":false,"may":false,"jun":false,"jul":false,"aug":false,"sep":false,"oct":false,"nov":false,"dec":false,"day1":"21","month1":"3","day2":"22","month2":"3","day3":"23","month3":"3","day4":"24","month4":"3","day5":"25","month5":"3","day6":"26","month6":"3","day7":"27","month7":"3","day8":"28","month8":"3","day9":"29","month9":"3","day10":"30","month10":"3","day11":"31","month11":"3","day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":"0","xmonth1":"0","xday2":"0","xmonth2":"0","xday3":"0","xmonth3":"0","xday4":"0","xmonth4":"0","xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":"","xmonth7":"","xday8":"","xmonth8":"","xday9":"","xmonth9":"","xday10":"","xmonth10":"","xday11":"","xmonth11":"","xday12":"","xmonth12":"","xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":380,"y":680,"wires":[["37a87dce9dfbc243"],[],[]]},{"id":"efef83e2e898641c","type":"server-state-changed","z":"9a640c27f5a76bb4","name":"Pool Override","server":"84a8d823.e15248","version":4,"outputs":1,"for":"0","forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"eventData"},{"property":"topic","propertyType":"msg","value":"","valueType":"triggerId"}],"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"input_select.pool_override","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","output_only_on_state_change":true,"x":90,"y":380,"wires":[["db081c2574ca4ea6","6fb33068d0c0e888","b69cc72f263729ac","34c5d44cfad1409b","83919b42ab4d502d","8e679b789630b68d"]]},{"id":"57f03c4f797b391c","type":"api-call-service","z":"9a640c27f5a76bb4","name":"Turn on pool pump","server":"84a8d823.e15248","version":5,"debugenabled":false,"domain":"switch","service":"turn_on","areaId":[],"deviceId":[],"entityId":["switch.pool_pump"],"data":"","dataType":"json","mergeContext":"","mustacheAltTags":false,"outputProperties":[],"queue":"none","x":1050,"y":420,"wires":[[]]},{"id":"137b4ec7e7c491a2","type":"api-current-state","z":"9a640c27f5a76bb4","name":"Are we in the spa? ","server":"84a8d823.e15248","version":3,"outputs":2,"halt_if":"on","halt_if_type":"str","halt_if_compare":"is","entity_id":"switch.spa_heater","state_type":"str","blockInputOverrides":false,"outputProperties":[{"property":"payload","propertyType":"msg","value":"","valueType":"entityState"},{"property":"data","propertyType":"msg","value":"","valueType":"entity"}],"for":"0","forType":"num","forUnits":"minutes","override_topic":false,"state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","x":1050,"y":500,"wires":[[],["c1489b4266b9d61e"]]},{"id":"84a8d823.e15248","type":"server","name":"Home Assistant","version":5,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true,"heartbeat":false,"heartbeatInterval":30,"areaSelector":"friendlyName","deviceSelector":"friendlyName","entitySelector":"friendlyName","statusSeparator":"at: ","statusYear":"hidden","statusMonth":"short","statusDay":"numeric","statusHourCycle":"h23","statusTimeFormat":"h:m","enableGlobalContextStore":true}]