Change some info messages to debug
This commit is contained in:
parent
432430e78d
commit
ac3af2b567
|
@ -83,7 +83,7 @@ class DoorControl:
|
||||||
self.nfc_fifo = self._open_nfc_fifo(config)
|
self.nfc_fifo = self._open_nfc_fifo(config)
|
||||||
self.control_socket, self.comm_channels = self._open_control_socket(config)
|
self.control_socket, self.comm_channels = self._open_control_socket(config)
|
||||||
|
|
||||||
self.mqttc.on_connect = lambda client, userdata, flags, rc: self.logger.info(f"Connected to mqtt host with result {rc}")
|
self.mqttc.on_connect = lambda client, userdata, flags, rc: self.logger.debug(f"Connected to mqtt host ({rc})")
|
||||||
self.mqttc.connect_async(config.mqtt_host, keepalive=60)
|
self.mqttc.connect_async(config.mqtt_host, keepalive=60)
|
||||||
self.mqttc.loop_start()
|
self.mqttc.loop_start()
|
||||||
|
|
||||||
|
@ -463,13 +463,13 @@ def main():
|
||||||
elif c == dc.nfc_fifo:
|
elif c == dc.nfc_fifo:
|
||||||
dc.handle_nfc_token()
|
dc.handle_nfc_token()
|
||||||
elif c == dc.control_socket:
|
elif c == dc.control_socket:
|
||||||
dc.logger.info("Got connection")
|
dc.logger.debug("Got connection")
|
||||||
sock = dc.control_socket.accept()[0]
|
sock = dc.control_socket.accept()[0]
|
||||||
buffers[sock] = dc.LineBuffer(sock, dc.handle_cmd)
|
buffers[sock] = dc.LineBuffer(sock, dc.handle_cmd)
|
||||||
dc.comm_channels += [sock]
|
dc.comm_channels += [sock]
|
||||||
else:
|
else:
|
||||||
if not buffers[c].update():
|
if not buffers[c].update():
|
||||||
dc.logger.info("Lost connection")
|
dc.logger.debug("Lost connection")
|
||||||
del buffers[c]
|
del buffers[c]
|
||||||
dc.comm_channels.remove(c)
|
dc.comm_channels.remove(c)
|
||||||
dc.handle_door_state()
|
dc.handle_door_state()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user