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
Please ensure all dependencies are available on the CircuitPython filesystem.
This is easily achieved by downloading
the Adafruit library and driver bundle
or individual libraries can be installed using
circup.
Installing to a Connected CircuitPython Device with Circup
Make sure that you have circup installed in your Python environment.
Install it with the following command if necessary:
pip3 install circup
With circup installed and your CircuitPython device connected use the
following command to install:
circup install adafruit_uc8151d
Or the following command to update an existing version:
circup update
Usage Example
importtimeimportboardimportdisplayioimportfourwireimportadafruit_uc8151ddisplayio.release_displays()
# This pinout works on a Feather M4 and may need to be altered for other boards.spi=board.SPI() # Uses SCK and MOSIepd_cs=board.D9epd_dc=board.D10epd_reset=board.D5epd_busy=Nonedisplay_bus=fourwire.FourWire(
spi, command=epd_dc, chip_select=epd_cs, reset=epd_reset, baudrate=1000000
)
time.sleep(1)
display=adafruit_uc8151d.UC8151D(
display_bus, width=296, height=128, rotation=90, busy_pin=epd_busy
)
g=displayio.Group()
pic=displayio.OnDiskBitmap("/display-ruler.bmp")
t=displayio.TileGrid(pic, pixel_shader=pic.pixel_shader)
g.append(t)
# Place the display group on the screendisplay.root_group=g# Refresh the display to have it actually show the image# NOTE: Do not refresh eInk displays sooner than 180 secondsdisplay.refresh()
print("refreshed")
time.sleep(180)
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
CircuitPython `displayio` driver for UC8151D-based ePaper displays