File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -123,7 +123,9 @@ def touch_point(self): # pylint: disable=too-many-locals
123
123
with AnalogIn (self ._xp_pin ) as x_p :
124
124
y_p .switch_to_output (True )
125
125
y_m .switch_to_output (False )
126
- for i in range (len (self ._xsamples )):
126
+ for i in range ( # pylint: disable=consider-using-enumerate
127
+ len (self ._xsamples )
128
+ ):
127
129
self ._xsamples [i ] = x_p .value
128
130
x = sum (self ._xsamples ) / len (self ._xsamples )
129
131
x_size = 65535
@@ -136,7 +138,9 @@ def touch_point(self): # pylint: disable=too-many-locals
136
138
with AnalogIn (self ._yp_pin ) as y_p :
137
139
x_p .switch_to_output (True )
138
140
x_m .switch_to_output (False )
139
- for i in range (len (self ._ysamples )):
141
+ for i in range ( # pylint: disable=consider-using-enumerate
142
+ len (self ._ysamples )
143
+ ):
140
144
self ._ysamples [i ] = y_p .value
141
145
y = sum (self ._ysamples ) / len (self ._ysamples )
142
146
y_size = 65535
You can’t perform that action at this time.
0 commit comments