Python client for GEX
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gex-client-py/examples/demo_neo2.py

17 lines
446 B

#!/bin/env python3
import gex
import time
# play a little neopixel animation as a demo
with gex.Client(gex.TrxRawUSB()) as client:
# Neopixel strip
strip = gex.Neopixel(client, 'npx')
# Load RGB to the strip
strip.load([0xFF0000, 0xFFFF00, 0x00FF00, 0x0000FF, 0xFF00FF])
for i in range(0,255):
strip.load([0xFF0000+i, 0xFFFF00, 0x00FF00, 0x0000FF, 0xFF00FF])
time.sleep(0.01)
strip.clear()