Skip to content

Commit 242f7ab

Browse files
authored
Merge pull request #30 from adafruit/pi_bitbang_exception
catch NotImplementedError when using bitbanged pins
2 parents cd50534 + 896a76d commit 242f7ab

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

adafruit_dotstar.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,8 @@ def __init__(self, clock, data, n, *, brightness=1.0, auto_write=True, pixel_ord
8383
while not self._spi.try_lock():
8484
pass
8585
self._spi.configure(baudrate=4000000)
86-
except ValueError:
86+
87+
except (NotImplementedError, ValueError):
8788
self.dpin = digitalio.DigitalInOut(data)
8889
self.cpin = digitalio.DigitalInOut(clock)
8990
self.dpin.direction = digitalio.Direction.OUTPUT

0 commit comments

Comments
 (0)