From 2c31fd8313892690f30c3688de1df704a766902f Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Thu, 10 Jan 2019 09:54:26 -0500 Subject: [PATCH] tmc2208: Check for debugging mode before checking for a retransmit Allow the tmc2208 code to be run from regression test cases. Signed-off-by: Kevin O'Connor --- klippy/extras/tmc2208.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/klippy/extras/tmc2208.py b/klippy/extras/tmc2208.py index 3058f291..96d42a42 100644 --- a/klippy/extras/tmc2208.py +++ b/klippy/extras/tmc2208.py @@ -209,6 +209,8 @@ class TMC2208: "Unable to read tmc2208 '%s' register %s" % (self.name, reg_name)) def set_register(self, reg_name, val): msg = encode_tmc2208_write(0xf5, 0x00, Registers[reg_name] | 0x80, val) + if self.printer.get_start_args().get('debugoutput') is not None: + return for retry in range(5): ifcnt = self.ifcnt if ifcnt is None: