Skip to content

Commit 79ae49e

Browse files
committed
Make colorwheel fast in older builds of circuitpython
1 parent 357d87d commit 79ae49e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

adafruit_led_animation/color.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,11 @@
4545

4646

4747
try:
48-
from _pixelbuf import colorwheel # pylint: disable=unused-import
48+
# Backwards compat for 5.3.0 and prior
49+
try:
50+
from _pixelbuf import colorwheel # pylint: disable=unused-import
51+
except ImportError:
52+
from _pixelbuf import wheel as colorwheel # pylint: disable=unused-import
4953
except ImportError:
5054
# Ensure we have a wheel if not built in
5155
def colorwheel(pos):

0 commit comments

Comments
 (0)