Skip to content

Commit 2b3a825

Browse files
committed
lint
1 parent 6474a74 commit 2b3a825

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

adafruit_motor/stepper.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -165,8 +165,8 @@ def _update_coils(self, *, microstepping=False):
165165
duty_cycles[leading_coil] = self._curve[microstep]
166166
duty_cycles[trailing_coil] = self._curve[self._microsteps - microstep]
167167

168-
# This ensures DOUBLE steps use full torque. Without it, we'd use partial torque from the
169-
# microstepping curve (0xb504).
168+
# This ensures DOUBLE steps use full torque. Without it, we'd use
169+
# partial torque from the microstepping curve (0xb504).
170170
if not microstepping and (
171171
duty_cycles[leading_coil] == duty_cycles[trailing_coil]
172172
and duty_cycles[leading_coil] > 0
@@ -187,7 +187,7 @@ def release(self):
187187
else:
188188
coil.duty_cycle = 0
189189

190-
def onestep(self, *, direction=FORWARD, style=SINGLE):
190+
def onestep(self, *, direction=FORWARD, style=SINGLE): #pylint: disable=too-many-branches
191191
"""Performs one step of a particular style. The actual rotation amount will vary by style.
192192
`SINGLE` and `DOUBLE` will normal cause a full step rotation. `INTERLEAVE` will normally
193193
do a half step rotation. `MICROSTEP` will perform the smallest configured step.
@@ -221,12 +221,12 @@ def onestep(self, *, direction=FORWARD, style=SINGLE):
221221
else:
222222
half_step = self._microsteps // 2
223223
full_step = self._microsteps
224-
# Its possible the previous steps were MICROSTEPS so first align with the interleave
225-
# pattern.
224+
# Its possible the previous steps were MICROSTEPS so first align
225+
# with the interleave pattern.
226226
additional_microsteps = self._current_microstep % half_step
227227
if additional_microsteps != 0:
228-
# We set _current_microstep directly because our step size varies depending on the
229-
# direction.
228+
# We set _current_microstep directly because our step size varies
229+
# depending on the direction.
230230
if direction == FORWARD:
231231
self._current_microstep += half_step - additional_microsteps
232232
else:

0 commit comments

Comments
 (0)