I use VEYE-MIPI-IMX462 with RPI 3B+ (bullsye, 5.10.92-v7+). Kernel module veyecam2m is installed. V4l2 preview by VLC player and GStreamer works fine.
When I tried to read from Python script by OpenCV with cv.VideoCapture() no frames captured (cv.VideoCapture.isOpened() returns False). I've tried to downgrade the kernel to v5.10.17 and use previous veye327 module but this hasn't solved the problem.
import cv2 as cv
cap = cv.VideoCapture(0)
print(cap.isOpened())
while cv.waitKey(10) != 27:
ret, img = cap.read()
cv.imshow("video", img)
cap.release()
cv.destroyAllWindows()
How to capture video by OpenCV and v4l2 for IMX462? And why it works fine with VLC and doesn't work with Python + OpenCV?