From 3c10d9dd72c58c2a7bbaaa8a0382d7f9afc47acb Mon Sep 17 00:00:00 2001 From: HonestBrothers <112437205+HonestBrothers@users.noreply.github.com> Date: Tue, 24 Dec 2024 21:47:10 -0600 Subject: [PATCH] Update tmc5160.py --- klippy/extras/tmc5160.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/klippy/extras/tmc5160.py b/klippy/extras/tmc5160.py index 866fe53f5..45fd84fca 100644 --- a/klippy/extras/tmc5160.py +++ b/klippy/extras/tmc5160.py @@ -302,7 +302,7 @@ class TMC5160CurrentHelper: def _calc_current(self, run_current, hold_current): gscaler = self._calc_globalscaler(run_current) irun = self._calc_current_bits(run_current) - ihold = int(min((hold_current/run_current)*irun), irun) + ihold = int(min((hold_current / run_current) * irun, irun)) return gscaler, irun, ihold def _calc_current_from_field(self, field_name): globalscaler = self.fields.get_field("globalscaler")