掌控板OLED显示
OLED显示文本内容
需要先将显示清空,然后将想要显示的内容放在里面,最后放入oled显示生效。
源代码如下:
from mpython import *
oled.fill(0)
oled.DispChar('Hello, world!', 0, 0, 1)
oled.show()
OLED显示心形
下面是对应的源码:
from mpython import *
import time
image_picture = Image()
while True:
oled.fill(0)
oled.blit(image_picture.load('face/1.pbm', 0), 32, 0)
oled.show()
time.sleep(0.5)
oled.blit(image_picture.load('face/2.pbm', 0), 32, 0)
oled.show()
time.sleep(0.5)
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)