Mercurial > templog
comparison py/fridge.py @ 178:77c2a9caca3d
a few fixes
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Thu, 30 Jan 2014 22:55:27 +0800 |
parents | a0ea542256ba |
children | 3f187baa3439 |
comparison
equal
deleted
inserted
replaced
177:a0ea542256ba | 178:77c2a9caca3d |
---|---|
102 overshoot = params.overshoot_factor \ | 102 overshoot = params.overshoot_factor \ |
103 * min(self.OVERSHOOT_MAX_DIV, on_time) \ | 103 * min(self.OVERSHOOT_MAX_DIV, on_time) \ |
104 / self.OVERSHOOT_MAX_DIV | 104 / self.OVERSHOOT_MAX_DIV |
105 D("on_time %(on_time)f, overshoot %(overshoot)f" % locals()) | 105 D("on_time %(on_time)f, overshoot %(overshoot)f" % locals()) |
106 | 106 |
107 if not params.nowort \ | 107 if not params.nowort and wort is not None: |
108 and wort is not None \ | 108 if wort - overshoot < params.fridge_setpoint: |
109 and (wort - overshoot) < params.fridge_setpoint: | |
110 L("wort has cooled enough, %(wort)f" % locals() ) | 109 L("wort has cooled enough, %(wort)f" % locals() ) |
111 turn_off = True | 110 turn_off = True |
112 elif fridge is not None and fridge < fridge_min: | 111 elif fridge is not None and fridge < fridge_min: |
113 W("fridge off fallback, fridge %(fridge)f, min %(fridge_min)f" % locals()) | 112 W("fridge off fallback, fridge %(fridge)f, min %(fridge_min)f" % locals()) |
114 if wort is None: | 113 if wort is None: |