Fix unused variables

This commit is contained in:
Craig Richardson 2018-05-15 15:35:03 +01:00
parent 81a255f0d2
commit b5424c1f89

View file

@ -38,6 +38,7 @@ def rainbow(wait):
for i in range(len(strip)): for i in range(len(strip)):
idx = int(i + j) idx = int(i + j)
strip[i] = wheel(idx & 255) strip[i] = wheel(idx & 255)
time.sleep(wait)
# Slightly different, this makes the rainbow equally distributed throughout # Slightly different, this makes the rainbow equally distributed throughout
@ -71,7 +72,7 @@ def wheel(pos):
def flash_random(wait, howmany): def flash_random(wait, howmany):
for k in range(howmany): for _ in range(howmany):
c = random.randint(0, len(colors) - 1) # Choose random color index c = random.randint(0, len(colors) - 1) # Choose random color index
j = random.randint(0, numpix - 1) # Choose random pixel j = random.randint(0, numpix - 1) # Choose random pixel