neopixel_crawl.py 385 B

12345678910111213141516
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. # Copyright (c) 2017-18 Richard Hull and contributors
  4. # See LICENSE.rst for details.
  5. import time
  6. from luma.led_matrix.device import neopixel
  7. from luma.core.render import canvas
  8. device = neopixel(cascaded=32)
  9. for i in range(device.cascaded):
  10. with canvas(device) as draw:
  11. draw.point((i, 0), fill="green")
  12. time.sleep(0.5)