rm-hull / luma.oled

Python module to drive a SSD1306 / SSD1309 / SSD1322 / SSD1325 / SSD1327 / SSD1331 / SSD1351 / SH1106 OLED
https://luma-oled.readthedocs.io
MIT License
790 stars 162 forks source link

from oled.device import ssd1306, sh1106 ModuleNotFoundError: No module named 'oled' #380

Closed StefCoders closed 9 months ago

StefCoders commented 10 months ago

Type of Raspberry Pi

RPi 4 2gb

Linux Kernel version

Linux piaware 5.15.76-v7l+ #1597 SMP Fri Nov 4 12:14:58 GMT 2022 armv7l GNU/Linux

Expected behaviour

To just run.

Actual behaviour

   from oled.device import ssd1306, sh1106 
ModuleNotFoundError: No module named 'oled'
thijstriemstra commented 10 months ago

try: from luma.oled.device import ssd1306, sh1106

StefCoders commented 10 months ago

from luma.oled.device import ssd1306, sh1106 from luma.oled.render import canvas from PIL import ImageDraw, ImageFont from time import time, sleep

Is this good?

StefCoders commented 10 months ago

The python code is https://github.com/jprochazka/adsb-receiver/blob/master/build/display/current_total-aircraft_with-positions.py

StefCoders commented 10 months ago

Traceback (most recent call last): File "/home/pi/adsb.py", line 39, in from oled.render import canvas ModuleNotFoundError: No module named 'oled'

thijstriemstra commented 10 months ago

you need to install the Pillow system dependencies, try: sudo apt-get install python3-pillow

thijstriemstra commented 9 months ago

did you manage to resolve it @StefCoders?

StefCoders commented 9 months ago

Yep.