Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update root_group and fourwire for CP 9 compatibility #14

Merged
merged 1 commit into from
Nov 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -71,13 +71,14 @@ Usage Example
import busio
import displayio
import terminalio
import fourwire
from adafruit_display_text import label
import adafruit_displayio_sh1106

displayio.release_displays()

spi = busio.SPI(board.SCK, board.MOSI)
display_bus = displayio.FourWire(
display_bus = fourwire.FourWire(
spi,
command=board.OLED_DC,
chip_select=board.OLED_CS,
Expand All @@ -92,7 +93,7 @@ Usage Example

# Make the display context
splash = displayio.Group()
display.show(splash)
display.root_group = splash

color_bitmap = displayio.Bitmap(WIDTH, HEIGHT, 1)
color_palette = displayio.Palette(1)
Expand Down
5 changes: 3 additions & 2 deletions examples/displayio_sh1106_simpletest.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,15 @@
import board
import busio
import displayio
import fourwire
import terminalio
from adafruit_display_text import label
import adafruit_displayio_sh1106

displayio.release_displays()

spi = busio.SPI(board.SCK, board.MOSI)
display_bus = displayio.FourWire(
display_bus = fourwire.FourWire(
spi,
command=board.OLED_DC,
chip_select=board.OLED_CS,
Expand All @@ -28,7 +29,7 @@

# Make the display context
splash = displayio.Group()
display.show(splash)
display.root_group = splash

color_bitmap = displayio.Bitmap(WIDTH, HEIGHT, 1)
color_palette = displayio.Palette(1)
Expand Down