User Manual

pixels.show()
time.sleep(wait)
pixels[::2] = [YELLOW] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[1::2] = [GREEN] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[::2] = [TEAL] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[1::2] = [CYAN] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[::2] = [BLUE] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[1::2] = [PURPLE] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[::2] = [MAGENTA] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
pixels[1::2] = [WHITE] * (num_pixels // 2)
pixels.show()
time.sleep(wait)
def slice_rainbow(wait):
pixels[::6] = [RED] * (num_pixels // 6)
pixels.show()
time.sleep(wait)
pixels[1::6] = [ORANGE] * (num_pixels // 6)
pixels.show()
time.sleep(wait)
pixels[2::6] = [YELLOW] * (num_pixels // 6)
pixels.show()
time.sleep(wait)
pixels[3::6] = [GREEN] * (num_pixels // 6)
pixels.show()
time.sleep(wait)
pixels[4::6] = [BLUE] * (num_pixels // 6)
pixels.show()
time.sleep(wait)
pixels[5::6] = [PURPLE] * (num_pixels // 6)
pixels.show()
time.sleep(wait)
def rainbow_cycle(wait):
for j in range(255):
for i in range(num_pixels):
rc_index = (i * 256 // num_pixels) + j
pixels[i] = wheel(rc_index & 255)
pixels.show()
time.sleep(wait)
RED = (255, 0, 0)
YELLOW = (255, 150, 0)
© Adafruit Industries https://learn.adafruit.com/adafruit-metro-m4-express-airlift-wifi Page 141 of 187