RAW-MIPI-AR0234M配置为4lane模式
-
@lizi
我测了一下orin nano上面,实际采集数据的帧率是没有问题的。 你可以延长你的代码的统计时间到10秒,100秒,可以发现帧率会趋近于接近60fps。那么为何出现你只统计1秒的时候,帧率只有20帧的结果呢? 我进行了一下简单的时间分析,发现是第一次调用cap.read()函数的时候,耗时大约半秒左右。(估计是底层进行buffer的初始化之类的操作。)
可以参考我贴上来这个代码:
import cv2 import argparse import subprocess import time def main(): # Set up command-line argument parser parser = argparse.ArgumentParser(description='Real-time display of GREY image from /dev/video0') parser.add_argument('--roix', type=int, default=0, help='roi start x (default: 0)') parser.add_argument('--roiy', type=int, default=0, help='roi start y (default: 0)') parser.add_argument('--width', type=int, default=1920, help='image width (default: 640)') parser.add_argument('--height', type=int, default=1200, help='image height (default: 480)') parser.add_argument('--fps', type=int, default=60, help='frame rate (default: 30)') args = parser.parse_args() v4l2_cmd = f"v4l2-ctl --set-ctrl roi_x={args.roix}" subprocess.run(v4l2_cmd, shell=True) v4l2_cmd = f"v4l2-ctl --set-ctrl roi_y={args.roiy}" subprocess.run(v4l2_cmd, shell=True) v4l2_cmd = f"v4l2-ctl --set-fmt-video=width={args.width},height={args.height}" subprocess.run(v4l2_cmd, shell=True) v4l2_cmd = f"v4l2-ctl --set-ctrl frame_rate={args.fps}" subprocess.run(v4l2_cmd, shell=True) # Open the /dev/video0 device cap = cv2.VideoCapture('/dev/video0') if not cap.isOpened(): print("Failed to open video device") return # Set the image size cap.set(cv2.CAP_PROP_FRAME_WIDTH, args.width) cap.set(cv2.CAP_PROP_FRAME_HEIGHT, args.height) frame_num = 0 # Loop over frames and display them while True: # Read a frame ret, frame = cap.read() # Check if reading was successful if ret: if frame_num == 0: time_start = time.perf_counter() frame_num += 1 # Display the frame # cv2.imshow('VEYE MV camera GREY image preview', frame) print(f"Success save , {frame_num}") else: print("Failed to read frame") #break time_end = time.perf_counter() time_ms = (time_end - time_start)*1000 print(time_ms) if time_ms > 1000: print(frame_num) break # Exit if 'q' key is pressed if cv2.waitKey(1) & 0xFF == ord('q'): break # Release resources cap.release() cv2.destroyAllWindows() if __name__ == '__main__': main() -
@veye_xumm 好的
-
@veye_xumm 想问一下这里的曝光时间只有读取,没有写入的吗?设置曝光时间的命令是在哪里呢?在i2c.sh里
已经找到了 -
-
This post is deleted! -
@veye_xumm

安装驱动出现这个错是为什么。板子是orin-nano 8gb ,然后mipi是ar0234 -
@lizi i2c不通,你查查硬件连接,比如fpc排线方向。
-
@veye_xumm

这是两边的插线方向。这个是对的吗orin-nano的有数据的线朝外侧,mipi有数据的线朝下方

我参考这个来安装的 -
@veye_xumm 还是有这个问题,这个是说明驱动式成功安装了是吗?只是硬件上的传输有问题吗
-
@lizi 看起来是正确的。 这套硬件上面,你试过我们标准的2lane模式的驱动吗?
-
@veye_xumm 目前是没改dts的。就是默认的dts。之前在树莓派上安装了驱动测试是没问题的。
-
@lizi 你用的orin板子上是多少pin的fpc座子啊?
-
@veye_xumm 22pin的
-
@veye_xumm https://wiki.veye.cc/index.php/VEYE_CS_Camera_for_Jetson_TX2/zh#.E6.9B.B4.E6.96.B0Jetson_Nano.2C_Jetson_TX2.EF.BC.8CTX2_NX.2C_AGX_Xavier.E5.92.8CXavier_NX.E7.B3.BB.E7.BB.9F。 驱动的安装我是按照这里的3.5.5 安装modules(适用于Jetpack5.x)来安装的
-
@lizi said in RAW-MIPI-AR0234M配置为4lane模式:
安装驱动出现这个错是为什么。板子是orin-nano 8gb ,然后mipi是ar0234

按照你这个提示,驱动安装没问题。但是硬件不通。所以我让找硬件问题。
-
@veye_xumm 刚刚我又把mipi放到树莓派上了。树莓派是正常的。但是在jetson上就还是出现那个问题。那如果不是排线方向的问题,还可能是什么硬件上的问题吗?

-
@lizi 可能是你的板子坏了,也有可能是你板子上的i2c不是9 和 10。你最好问问你板子的供应商这个i2c扩展功能是不是跟官方的开发板一致。
-
@veye_xumm said in RAW-MIPI-AR0234M配置为4lane模式:
i2c不是9 和 10
我使用的英伟达是创乐博的,然后他这里写的CSI摄像头是有,2个MIPI CSI-2 D-PHY 通道。这个是支持的吗
-
@veye_xumm 是和官方的一致的,还有什么可能的原因吗?
-
@veye_xumm 有没有可能是驱动的问题。因为这个自带的摄像头是可以的。
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