VEYE IMAGING Forum
    • Categories
    • Tags
    • Recent
    • Popular
    • Users
    • WIKI
    • veye.cc
    • Register
    • Login

    IMX307pickmode设为1

    Scheduled Pinned Locked Moved CS MIPI camera
    7 Posts 2 Posters 2.2k Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • L Offline
      lyj
      last edited by

      IMX307,pickmode设为1,使用pickone触发读取图片,每隔20s读取一张,会出现读取一段时间后无法读取,而且pickone触发后读取的图片也不实时

      veye_xummV 1 Reply Last reply Reply Quote 0
      • veye_xummV Offline
        veye_xumm @lyj
        last edited by

        @lyj
        pickone的机制就是在mipi输出的地方做了一个开关。
        你可否把你的程序发过来,我们试一下。

        Questions will be answered as soon as possible, please be patient.
        如果你使用中文,请直接用中文提问。
        May the force be with YOU. (This is the translation of the mysterious Chinese symbol above.)

        L 2 Replies Last reply Reply Quote 0
        • L Offline
          lyj @veye_xumm
          last edited by

          @veye_xumm
          import cv2
          import os
          import time

          def gstreamer_pipeline(self, video_idx, capture_width=1280, capture_height=720):
          ret1 = 'v4l2src device=/dev/video{} ! '.format(video_idx)
          ret2 = 'video/x-raw, width=(int){}, height=(int){}, '.format(capture_width, capture_height)
          ret3 = 'format=(string)UYVY ! '
          ret4 = 'nvvidconv ! '
          ret5 = 'video/x-raw(memory:NVMM), '
          ret6 = 'format=(string)I420 ! '
          ret7 = 'nvvidconv ! '
          ret8 = 'video/x-raw, '
          ret9 = 'format=(string)BGRx ! '
          ret10 = 'videoconvert ! '
          ret11 = 'video/x-raw, format=(string)BGR ! appsink'
          print(ret1 + ret2 + ret3 + ret4 + ret5 + ret6 + ret7 + ret8 + ret9 + ret10 + ret11)
          return ret1 + ret2 + ret3 + ret4 + ret5 + ret6 + ret7 + ret8 + ret9 + ret10 + ret11

          if name == 'main':
          cap = cv2.VideoCapture(gstreamer_pipeline(0), cv2.CAP_GSTREAMER)
          password = '此处为sudo密码'
          ret = os.system(
          "echo {} | sudo -S ./shell/cs_mipi_i2c.sh -w -b {} -f pickmode -p1 1".format(password, 9))
          print(ret)
          while True:
          time.sleep(10)
          ret = os.system(
          "echo {} | sudo -S ./shell/cs_mipi_i2c.sh -w -b {} -f pickone".format(password, 9))
          print('%%%', ret)
          ret_val, img = cap.read()
          print(ret_val)
          if ret_val is True:
          cv2.imshow('12', img)
          cv2.waitKey(0)

          1 Reply Last reply Reply Quote 0
          • L Offline
            lyj @veye_xumm
            last edited by

            @veye_xumm 以上是我的代码,麻烦帮忙看一下,我这边等你的回复。这个的问题也是,取到的图不是当下的,是几分钟前的

            veye_xummV 1 Reply Last reply Reply Quote 0
            • veye_xummV Offline
              veye_xumm @lyj
              last edited by

              @lyj 这个参考一下另一个问题上给你的回复。

              Questions will be answered as soon as possible, please be patient.
              如果你使用中文,请直接用中文提问。
              May the force be with YOU. (This is the translation of the mysterious Chinese symbol above.)

              L 1 Reply Last reply Reply Quote 0
              • L Offline
                lyj @veye_xumm
                last edited by

                @veye_xumm 哥,我们认真思考了一下,咱的pickmode写的是:pickmode是一个特殊的功能,一旦开启,sensor正常工作,但是模组将不输出图像,只有收到pickone指令,输出一张。如果是这种情况,就算板卡有缓存,pickone设为1的那一下才输出一张图,存下来的也应该是当下的图像啊

                veye_xummV 1 Reply Last reply Reply Quote 0
                • veye_xummV Offline
                  veye_xumm @lyj
                  last edited by

                  @lyj 我说的板卡有缓存,指的是你的主板,不是camera。

                  Questions will be answered as soon as possible, please be patient.
                  如果你使用中文,请直接用中文提问。
                  May the force be with YOU. (This is the translation of the mysterious Chinese symbol above.)

                  1 Reply Last reply Reply Quote 0

                  Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                  Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                  With your input, this post could be even better 💗

                  Register Login
                  • First post
                    Last post