You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This library will allow you to control the LEDs and read button presses on the Adafruit Trellis
Board. It will work with a single Trellis board, or
with a matrix of up to 8 Trellis boards.
Please ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloading
the Adafruit library and driver bundle.
Installing from PyPI
On supported GNU/Linux systems like the Raspberry Pi, you can install the driver locally from
PyPI. To install for current user:
pip3 install adafruit-circuitpython-trellis
To install system-wide (this may be required in some cases):
sudo pip3 install adafruit-circuitpython-trellis
To install in a virtual environment in your current project:
importtimeimportbusiofromboardimportSCL, SDAfromadafruit_trellisimportTrellis# Create the I2C interfacei2c=busio.I2C(SCL, SDA)
# Create a Trellis object for each boardtrellis=Trellis(i2c) # 0x70 when no I2C address is supplied# Turn on every LEDprint('Turning all LEDs on...')
trellis.led.fill(True)
time.sleep(2)
# Turn off every LEDprint('Turning all LEDs off...')
trellis.led.fill(False)
time.sleep(2)
Documentation
API documentation for this library can be found on Read the Docs.
For information on building library documentation, please check out this guide.
Contributing
Contributions are welcome! Please read our Code of Conduct
before contributing to help this project stay welcoming.
About
Driver for a Trellis in both single and matrix configurations