Error: No camera availabe with "nvarguscamerasrc ...."

If I try to access the camera(s) attached to the CSI port, i get the message that no camera are available.

here is my pyton code:

import cv2

width = 800
height =600

camSet_str = ('nvarguscamerasrc sensor-id={} ! ’
'video/x-raw(memory:NVMM), width=1920, height=1080, framerate=60/1, format=NV12 ! ’
'nvvidconv flip-method=2 ! ’
'video/x-raw, width={}, height={}, format=BGRx ! ’
'videoconvert ! ’
'video/x-raw, format=BGR ! ’

while True:
_, frame =
cv2.imshow(‘myCam’, frame)
if cv2.waitKey(1)==ord(‘q’):

and that is the error message I get:

Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:645 No cameras available

(python3:8932): GStreamer-CRITICAL **: 11:50:19.843: gst_mini_object_set_qdata: assertion ‘object != NULL’ failed
[ WARN:0] global /home/nvidia/host/build_opencv/nv_opencv/modules/videoio/src/cap_gstreamer.cpp (933) open OpenCV | GStreamer warning: Cannot query video position: status=0, value=-1, duration=-1
Traceback (most recent call last):
File “/home/iguelkanat/Desktop/PyPro/OpenCV/”, line 19, in
cv2.imshow(‘myCam’, frame)
cv2.error: OpenCV(4.1.1) /home/nvidia/host/build_opencv/nv_opencv/modules/highgui/src/window.cpp:352: error: (-215:Assertion failed) size.width>0 && size.height>0 in function ‘imshow’

the command: ls /dev/video* says that there is no such file or directory (only if I have attached a USB camera, I have /dev/video0 available)

Thx for the help

Did you install any of CSI like Pi V2 camera on Nano?

The camera worked fine on a Jetson Nano; but it does not work on Jetson Xavier NX.

Thus the question, if I need any driver to install? If yes, which one ?


If your are using Pi V2 imx219 you don’t need driver for it, otherwise you need integrate correct driver for it.

Thanks Shane. I have to get then new cameras with imx219 and will try it again.

I have now purchased two V2 cameras with imx219 and still no camera available

Reflashing the SD worked !! Strange !