File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -151,7 +151,7 @@ def write_then_readinto(
151
151
152
152
def __enter__ (self ) -> "I2CDevice" :
153
153
while not self .i2c .try_lock ():
154
- time .sleep (0 )
154
+ time .sleep (0.001 )
155
155
return self
156
156
157
157
def __exit__ (
@@ -170,7 +170,7 @@ def __probe_for_device(self) -> None:
170
170
or that the device does not support these means of probing
171
171
"""
172
172
while not self .i2c .try_lock ():
173
- time .sleep (0 )
173
+ time .sleep (0.001 )
174
174
try :
175
175
self .i2c .writeto (self .device_address , b"" )
176
176
except OSError :
Original file line number Diff line number Diff line change @@ -93,7 +93,7 @@ def __init__(
93
93
94
94
def __enter__ (self ) -> SPI :
95
95
while not self .spi .try_lock ():
96
- time .sleep (0 )
96
+ time .sleep (0.001 )
97
97
self .spi .configure (
98
98
baudrate = self .baudrate , polarity = self .polarity , phase = self .phase
99
99
)
You can’t perform that action at this time.
0 commit comments