Skip to content

Commit

Permalink
Update smarterzones.py
Browse files Browse the repository at this point in the history
  • Loading branch information
dgaust authored Jul 25, 2021
1 parent 46ecbec commit a9017a9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions apps/smarterzones/smarterzones.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ def initialize(self):
self.climatedevice = self.args.get('climatedevice')
self.exterior_temperature = self.args.get('exteriortempsensor')
self.forceautofan = self.args.get('force_auto_fan', False)

self.log("Climate device is: " + self.climatedevice)

# Hook up a listener for the climate device
Expand Down Expand Up @@ -117,17 +116,17 @@ def automatically_manage_zone(self, zone):
if coolingmode == ACMODE.COOLING:
# Check if zone is above the wanted temperature and if so, open the zone to cool
if current_zone_temperature >= maxtemp:
self.log("We're cooling and " + str(current_zone_temperature) + " is above " + str(maxtemp) + ". So turning on")
self.log("We're cooling and " + str(current_zone_temperature) + " is above or equal to" + str(maxtemp) + ". So turning on")
self.switchon(zone)
elif current_zone_temperature <= mintemp:
self.log("We're cooling and " + str(current_zone_temperature) + " is below " + str(mintemp) + ". So turning off")
self.log("We're cooling and " + str(current_zone_temperature) + " is below or equal to " + str(mintemp) + ". So turning off")
self.switchoff(zone)
elif coolingmode == ACMODE.HEATING:
if current_zone_temperature <= mintemp:
self.log("We're heating and " + str(current_zone_temperature) + " is below " + str(mintemp) + ". So turning on")
self.log("We're heating and " + str(current_zone_temperature) + " is below or equal to " + str(mintemp) + ". So turning on")
self.switchon(zone)
elif current_zone_temperature >= maxtemp:
self.log("We're heating and " + str(current_zone_temperature) + " is above " + str(maxtemp) + ". So turning off")
self.log("We're heating and " + str(current_zone_temperature) + " is above or equal to " + str(maxtemp) + ". So turning off")
self.switchoff(zone)
else:
# what do we want to do with drying, I think turn all zones on
Expand Down Expand Up @@ -204,3 +203,4 @@ def heatingorcooling(self, mode, zone):
return ACMODE.COOLING
elif outside_temperature < target_temperature:
return ACMODE.HEATING

0 comments on commit a9017a9

Please sign in to comment.