test
This commit is contained in:
parent
c05d4127ef
commit
b404d0c888
1 changed files with 2 additions and 2 deletions
4
oled.py
4
oled.py
|
@ -1,7 +1,7 @@
|
||||||
from luma.core.interface.serial import i2c, spi, pcf8574
|
from luma.core.interface.serial import i2c, spi, pcf8574
|
||||||
from luma.core.interface.parallel import bitbang_6800
|
from luma.core.interface.parallel import bitbang_6800
|
||||||
from luma.core.render import canvas
|
from luma.core.render import canvas
|
||||||
from luma.oled.device import ssd1306, ssd1309, ssd1325, ssd1331, sh1106, sh1107, ws0010
|
from luma.oled.device import ssd1306
|
||||||
import time
|
import time
|
||||||
|
|
||||||
serial = i2c(port=1, address=0x3C)
|
serial = i2c(port=1, address=0x3C)
|
||||||
|
@ -11,4 +11,4 @@ device = ssd1306(serial)
|
||||||
with canvas(device) as draw:
|
with canvas(device) as draw:
|
||||||
#draw.rectangle(device.bounding_box, outline="white", fill="black")
|
#draw.rectangle(device.bounding_box, outline="white", fill="black")
|
||||||
draw.text((30, 0), "Hello World", fill="white")
|
draw.text((30, 0), "Hello World", fill="white")
|
||||||
time.sleep(10)
|
time.sleep(10)
|
||||||
|
|
Loading…
Reference in a new issue