t=getFromInflux(temperatureSink,"select last("+tColumnName+") from "+temperatureSink["measurement"])
dp=getFromInflux(dewpointSink,"select last(\""+dpColumnName+"\") from "+dewpointSink["measurement"])
...
...
@@ -118,7 +124,7 @@ def power_off(hw, ps, args):
diff=t-dp
ifdiff<maxDiffBetweenTandDPtoTurnTheHVoff:
print("[ warn ][ps] T - DP = {:.2f}, which is smaller than {}. Cannot power off the PS in these conditions".format(diff,maxDiffBetweenTandDPtoTurnTheHVoff))
print("[ warn ][ps] (T - DP) = {:.2f}, which is smaller than {}. Cannot power off the PS in these conditions".format(diff,maxDiffBetweenTandDPtoTurnTheHVoff))
else:
ps.turnOff()
print("[ info ][ps] ps off")
...
...
@@ -264,7 +270,12 @@ if __name__ == "__main__":
action='store_true',
help="Measure and Post until the end of the universe (or until killed)",