mirror of
https://github.com/PiBrewing/craftbeerpi4.git
synced 2024-11-09 17:07:43 +01:00
update
This commit is contained in:
parent
9257b95e37
commit
a8ec65b3e4
3 changed files with 4 additions and 4 deletions
|
@ -1,3 +1,3 @@
|
||||||
__version__ = "4.1.7.a8"
|
__version__ = "4.1.7.a9"
|
||||||
__codename__ = "Groundhog Day"
|
__codename__ = "Groundhog Day"
|
||||||
|
|
||||||
|
|
|
@ -34,10 +34,9 @@ class MQTTSensor(CBPiSensor):
|
||||||
self.lastlog=0
|
self.lastlog=0
|
||||||
self.sensor=self.get_sensor(self.id)
|
self.sensor=self.get_sensor(self.id)
|
||||||
self.reducedfrequency=int(self.props.get("ReducedLogging", 60))
|
self.reducedfrequency=int(self.props.get("ReducedLogging", 60))
|
||||||
|
|
||||||
self.kettleid=self.props.get("Kettle", None)
|
self.kettleid=self.props.get("Kettle", None)
|
||||||
self.reducedlogging=True
|
|
||||||
self.fermenterid=self.props.get("Fermenter", None)
|
self.fermenterid=self.props.get("Fermenter", None)
|
||||||
|
self.reducedlogging=True if self.kettleid or self.fermenterid else False
|
||||||
|
|
||||||
if self.kettleid is not None and self.fermenterid is not None:
|
if self.kettleid is not None and self.fermenterid is not None:
|
||||||
self.reducedlogging=False
|
self.reducedlogging=False
|
||||||
|
|
|
@ -72,8 +72,8 @@ class OneWire(CBPiSensor):
|
||||||
self.reducedfrequency=int(self.props.get("ReducedLogging", 60))
|
self.reducedfrequency=int(self.props.get("ReducedLogging", 60))
|
||||||
|
|
||||||
self.kettleid=self.props.get("Kettle", None)
|
self.kettleid=self.props.get("Kettle", None)
|
||||||
self.reducedlogging=True
|
|
||||||
self.fermenterid=self.props.get("Fermenter", None)
|
self.fermenterid=self.props.get("Fermenter", None)
|
||||||
|
self.reducedlogging=True if self.kettleid or self.fermenterid else False
|
||||||
|
|
||||||
if self.kettleid is not None and self.fermenterid is not None:
|
if self.kettleid is not None and self.fermenterid is not None:
|
||||||
self.reducedlogging=False
|
self.reducedlogging=False
|
||||||
|
@ -115,6 +115,7 @@ class OneWire(CBPiSensor):
|
||||||
if self.reducedlogging:
|
if self.reducedlogging:
|
||||||
await self.logvalue()
|
await self.logvalue()
|
||||||
else:
|
else:
|
||||||
|
logging.info("OneWire {} regular logging".format(self.sensor.name))
|
||||||
self.log_data(self.value)
|
self.log_data(self.value)
|
||||||
self.lastlog = time.time()
|
self.lastlog = time.time()
|
||||||
await asyncio.sleep(self.interval)
|
await asyncio.sleep(self.interval)
|
||||||
|
|
Loading…
Reference in a new issue