logo

把图像复制到framebuffer出错

2019-09-12 14:12
W
f4e2

按照官网的例程读入一张图片在framebuffer窗口显示,待读取的图片在SD卡中,彩色图像,分辨率320 * 240,运行程序有错误,不知道什么原因:

import sensor, image, time

sensor.reset()

sensor.set_contrast(1)

sensor.set_gainceiling(16)

sensor.set_framesize(sensor.QVGA)

sensor.set_pixformat(sensor.RGB565)

img = image.Image("/50.jpg", copy_to_fb = True)

sensor.flush()

time.sleep(100)

793e6bae-6d45-45a5-9aab-19839988241b.PNG