@@ -59,17 +59,21 @@ Usage Example
5959
6060.. code-block: python
6161
62+ # SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
63+ # SPDX-License-Identifier: MIT
64+
6265 """Simple test script for 2.13" 212x104 tri-color featherwing.
6366
6467 Supported products:
6568 * Adafruit 2.13" Tri-Color FeatherWing
6669 * https://www.adafruit.com/product/4128
67- """
68-
70+ """
6971 import time
72+
7073 import board
7174 import displayio
7275 import fourwire
76+
7377 import adafruit_il0373
7478
7579 displayio.release_displays()
@@ -80,30 +84,24 @@ Usage Example
8084 display_bus = fourwire.FourWire(board.SPI(), command=epd_dc, chip_select=epd_cs, baudrate=1000000)
8185 time.sleep(1)
8286
83- display = adafruit_il0373.IL0373(display_bus, width=212, height=104, rotation=90,
84- highlight_color=0xff0000)
87+ display = adafruit_il0373.IL0373(
88+ display_bus, width=212, height=104, rotation=90, highlight_color=0xFF0000
89+ )
8590
8691 g = displayio.Group()
8792
88- f = open("/display-ruler.bmp", "rb")
89-
90- pic = displayio.OnDiskBitmap(f)
91- # CircuitPython 6 & 7 compatible
92- t = displayio.TileGrid(
93- pic, pixel_shader=getattr(pic, "pixel_shader", displayio.ColorConverter())
94- )
95- # CircuitPython 7 compatible only
96- # t = displayio.TileGrid(pic, pixel_shader=pic.pixel_shader)
93+ pic = displayio.OnDiskBitmap("/display-ruler.bmp")
94+ t = displayio.TileGrid(pic, pixel_shader=pic.pixel_shader)
9795 g.append(t)
9896
9997 display.root_group = g
10098
10199 display.refresh()
102100
103101 print("refreshed")
104-
105102 time.sleep(120)
106103
104+
107105 Documentation
108106=============
109107
0 commit comments