导航

    • 登录
    • 搜索
    • 版块
    • 产品
    • 教程
    • 论坛
    • 淘宝
    1. 主页
    2. gnh2
    G
    • 举报资料
    • 资料
    • 关注
    • 粉丝
    • 屏蔽
    • 帖子
    • 楼层
    • 最佳
    • 群组

    gnh2

    @gnh2

    0
    声望
    5
    楼层
    287
    资料浏览
    0
    粉丝
    0
    关注
    注册时间 最后登录

    gnh2 关注

    gnh2 发布的帖子

    • RE: OSError:Assertion failed

      @kidswong999 我打开jpg文件时,提醒我“OSError:Unsupported format”,连jpg文件都打不开

      发布在 OpenMV Cam
      G
      gnh2
    • RE: OSError:Assertion failed

      @kidswong999 而且我用os.listdir函数打印出当前文件夹里的文件信息,也是有1.bmp文件的。

      发布在 OpenMV Cam
      G
      gnh2
    • RE: OSError:Assertion failed

      @kidswong999 您好!我用的SD卡,文件也放在了SD卡里边。

      0_1606300968753_捕获.JPG

      发布在 OpenMV Cam
      G
      gnh2
    • RE: OSError:Assertion failed

      问题发生在“img = image.Image("/1.bmp", copy_to_fb=True)”这一行

      发布在 OpenMV Cam
      G
      gnh2
    • OSError:Assertion failed
      # Copy image to framebuffer.
      #
      # This example shows how to load and copy an image to framebuffer for testing.
      
      import sensor, image, time
      
      # Still need to init sensor
      sensor.reset()
      # Set sensor settings
      sensor.set_contrast(1)
      sensor.set_gainceiling(16)
      
      # Set sensor pixel format
      sensor.set_framesize(sensor.QQVGA)
      sensor.set_pixformat(sensor.GRAYSCALE)
      
      # Load image
      img = image.Image("/1.bmp", copy_to_fb=True)
      
      # Add drawing code here.
      # img.draw_line(...)
      
      # Flush FB
      sensor.flush()
      
      # Add a small delay to allow the IDE to read the flushed image.
      time.sleep(100)
      
      

      0_1606295478874_捕获.JPG
      运行例程03-Drawing-image_drawing.py,提示这个错误,不知道是为什么,是不是IDE的问题

      发布在 OpenMV Cam
      G
      gnh2