Skip to content

Commit 24fd6c1

Browse files
authored
Merge pull request #85 from makermelissa/master
Added text specifying Pillow Examples don't run in CircuitPython
2 parents 246f724 + ed34d54 commit 24fd6c1

6 files changed

+44
-2
lines changed

README.rst

+6-2
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,11 @@ Please ensure all dependencies are available on the CircuitPython filesystem.
3030
This is easily achieved by downloading
3131
`the Adafruit library and driver bundle <https://github.com/adafruit/Adafruit_CircuitPython_Bundle>`_.
3232

33-
For improved performance consider installing numpy.
33+
For the Pillow Examples, you will need to be running CPython. This means using a Single Board Computer
34+
such as a Raspberry Pi or using a chip such as an FT232H on Linux, Window, or Mac. CircuitPython does
35+
not support PIL/pillow (python imaging library)!
36+
37+
For improved performance consider installing NumPy.
3438

3539
Installing from PyPI
3640
====================
@@ -149,7 +153,7 @@ With 1.14" `wiring <https://learn.adafruit.com/adafruit-1-14-240x135-color-tft-b
149153
display.fill(color565(0, 0, 255))
150154
# Pause 2 seconds.
151155
time.sleep(2)
152-
156+
153157
154158
Contributing
155159
============

adafruit_rgb_display/ssd1331.py

+2
Original file line numberDiff line numberDiff line change
@@ -156,5 +156,7 @@ def write(self, command=None, data=None):
156156
with self.spi_device as spi:
157157
if command is not None:
158158
spi.write(bytearray([command]))
159+
print(bytearray([command]))
159160
if data is not None:
160161
spi.write(data)
162+
print(data)

examples/rgb_display_pillow_bonnet_buttons.py

+5
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@
2323
# This example is for use on (Linux) computers that are using CPython with
2424
# Adafruit Blinka to support CircuitPython libraries. CircuitPython does
2525
# not support PIL/pillow (python imaging library)!
26+
"""
27+
This example is for use on (Linux) computers that are using CPython with
28+
Adafruit Blinka to support CircuitPython libraries. CircuitPython does
29+
not support PIL/pillow (python imaging library)!
30+
"""
2631

2732
import time
2833
import random

examples/rgb_display_pillow_demo.py

+11
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
"""
2+
This demo will draw a few rectangles onto the screen along with some text
3+
on top of that.
4+
5+
This example is for use on (Linux) computers that are using CPython with
6+
Adafruit Blinka to support CircuitPython libraries. CircuitPython does
7+
not support PIL/pillow (python imaging library)!
8+
9+
Author(s): Melissa LeBlanc-Williams for Adafruit Industries
10+
"""
11+
112
import digitalio
213
import board
314
from PIL import Image, ImageDraw, ImageFont

examples/rgb_display_pillow_image.py

+10
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
1+
"""
2+
Be sure to check the learn guides for more usage information.
3+
4+
This example is for use on (Linux) computers that are using CPython with
5+
Adafruit Blinka to support CircuitPython libraries. CircuitPython does
6+
not support PIL/pillow (python imaging library)!
7+
8+
Author(s): Melissa LeBlanc-Williams for Adafruit Industries
9+
"""
10+
111
import digitalio
212
import board
313
from PIL import Image, ImageDraw

examples/rgb_display_pillow_stats.py

+10
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
1+
"""
2+
This will show some Linux Statistics on the attached display. Be sure to adjust
3+
to the display you have connected. Be sure to check the learn guides for more
4+
usage information.
5+
6+
This example is for use on (Linux) computers that are using CPython with
7+
Adafruit Blinka to support CircuitPython libraries. CircuitPython does
8+
not support PIL/pillow (python imaging library)!
9+
"""
10+
111
import time
212
import subprocess
313
import digitalio

0 commit comments

Comments
 (0)