Skip to content

Commit ba7a3f8

Browse files
committed
displayio api updates
1 parent 9aeacea commit ba7a3f8

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

examples/buttons_example.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
import board
1111
import displayio
12+
import fourwire
1213
import terminalio
1314
from adafruit_button import Button
1415
from adafruit_hx8357 import HX8357
@@ -25,7 +26,7 @@
2526
tft_cs = board.D9
2627
tft_dc = board.D10
2728

28-
display_bus = displayio.FourWire(spi, command=tft_dc, chip_select=tft_cs)
29+
display_bus = fourwire.FourWire(spi, command=tft_dc, chip_select=tft_cs)
2930
display = HX8357(display_bus, width=480, height=320, rotation=0)
3031

3132
i2c = board.I2C() # uses board.SCL and board.SDA

examples/touchpaint_example.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77

88
import board
99
import displayio
10+
import fourwire
1011
from adafruit_hx8357 import HX8357
1112

1213
import adafruit_ft5336
@@ -21,7 +22,7 @@
2122
tft_cs = board.D9
2223
tft_dc = board.D10
2324

24-
display_bus = displayio.FourWire(spi, command=tft_dc, chip_select=tft_cs)
25+
display_bus = fourwire.FourWire(spi, command=tft_dc, chip_select=tft_cs)
2526
# display is rotated to align x, y with touch screen x, y
2627
display = HX8357(display_bus, width=320, height=480, rotation=90)
2728

0 commit comments

Comments
 (0)