From 910be985b1ac163934b6fc0e0d0d89792ee8c354 Mon Sep 17 00:00:00 2001 From: Wolfgang Hottgenroth Date: Sun, 30 Aug 2020 21:18:48 +0100 Subject: [PATCH] disable debugging --- snippets/snippet1.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/snippets/snippet1.py b/snippets/snippet1.py index d4767e3..fb7d731 100644 --- a/snippets/snippet1.py +++ b/snippets/snippet1.py @@ -121,7 +121,7 @@ class MeterbusSerial(object): def shortFrameRequest(self, cmd, addr): chksum = (cmd + addr) & 0x00ff msg = bytearray([0x10, cmd, addr, chksum, 0x16]) - print(a2h(msg)) + # print(a2h(msg)) frontendSample() @@ -148,14 +148,14 @@ class MeterbusSerial(object): expectedUserDataOctets = 0 state = MeterbusResponseStates.START1 while (state not in [MeterbusResponseStates.DONE, MeterbusResponseStates.ERROR, MeterbusResponseStates.TIMEOUT]): - print("Waiting for input ... ") + # print("Waiting for input ... ") c = self.port.read(1) if len(c) == 0: state = MeterbusResponseStates.TIMEOUT continue c = ord(c) - print("State {}, Octet 0x{:02X}".format(state, c)) + # print("State {}, Octet 0x{:02X}".format(state, c)) if state == MeterbusResponseStates.START1: if c == 0x68: