File tree Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Expand file tree Collapse file tree 1 file changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -113,15 +113,13 @@ def __init__(
113113 # set a safe pwm freq for each output
114114 self ._coil = (ain2 , bin1 , ain1 , bin2 )
115115 for i in range (4 ):
116- if (
117- self ._coil [i ].frequency < 1500
118- and not self ._coil [i ].variable_frequency
119- ):
120- raise ValueError (
121- "PWMOut outputs must either be set to at least "
122- "1500 Hz or allow variable frequency."
123- )
124- self ._coil [i ].frequency = 2000
116+ if self ._coil [i ].frequency < 1500 :
117+ if not self ._coil [i ].variable_frequency :
118+ raise ValueError (
119+ "PWMOut outputs must either be set to at least "
120+ "1500 Hz or allow variable frequency."
121+ )
122+ self ._coil [i ].frequency = 2000
125123 if microsteps < 2 :
126124 raise ValueError ("Microsteps must be at least 2" )
127125 if microsteps % 2 == 1 :
You can’t perform that action at this time.
0 commit comments