Jetpack 5.1.1 GST_ARGUS does not see max fps like v412-ctl does

Hello,

This worked in Jetpack 4.x, not sure why now it does not in 5.1.1… camera is detected successfully, v4l2-ctl reports the max fps of 90 at 2k, but when running inside gstreamer, nvarguscamera does not see the same modes available and cannot start streaming.

Any idea why or what should be the next step to debug this?

Thank you!
R

$ v4l2-ctl --list-formats-ext -d /dev/video1
ioctl: VIDIOC_ENUM_FMT
	Type: Video Capture

	[0]: 'RG10' (10-bit Bayer RGRG/GBGB)
		Size: Discrete 2712x1538
			Interval: Discrete 0.011s (90.000 fps)
		Size: Discrete 1920x1080
			Interval: Discrete 0.008s (124.000 fps)
	[1]: 'RG12' (12-bit Bayer RGRG/GBGB)
		Size: Discrete 2712x1538
			Interval: Discrete 0.011s (90.000 fps)
		Size: Discrete 1920x1080
			Interval: Discrete 0.008s (124.000 fps)
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 2712 x 1538 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 3981.070801; Exposure Range min 20000, max 660000000;

GST_ARGUS: 1920 x 1080 FR = 41.000000 fps Duration = 24390244 ; Analog Gain range min 1.000000, max 3981.070801; Exposure Range min 20000, max 660000000;

GST_ARGUS: 2712 x 1538 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 3981.070801; Exposure Range min 20000, max 660000000;

GST_ARGUS: 1920 x 1080 FR = 41.000000 fps Duration = 24390244 ; Analog Gain range min 1.000000, max 3981.070801; Exposure Range min 20000, max 660000000;

CONSUMER: Waiting until producer is connected...
GST_ARGUS: Running with following settings:
   Camera index = 1
   Camera mode  = 2
   Output Stream W = 2712 H = 1538
   seconds to Run    = 0
   Frame Rate = 29.999999
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.

hello razvan.grigore,

could you please execute v4l pipeline to fetch the sensor frames, and examine the fps.
for example,
2712x1538@90-fps
$ v4l2-ctl -d /dev/video0 --set-fmt-video=width=2712,height=1538,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=300
1920x1080@124-fps
$ v4l2-ctl -d /dev/video0 --set-fmt-video=width=1920,height=1080,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=300

Hello,

Unfortunately those commands just hang…

After doing (also note that the parameter value is ignored):

$ v4l2-ctl -d /dev/video1 -p 30
Frame rate set to 90.000 fps
$ v4l2-ctl -d /dev/video1 --set-fmt-video=width=2712,height=1538,pixelformat=RG10 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=300
<<<<< 1.50 fps
< 1.50 fps
<< 1.50 fps
< 1.50 fps
<^C

So very bad performance… Already tried jetson_clocks and mode 0.

Also, when trying this command:

$ gst-launch-1.0 -vv nvarguscamerasrc sensor_id=0 '!' 'video/x-raw(memory:NVMM),width=2712,height=1538,format=NV12,framerate=30/1' '!' nvvidconv '!' nvv4l2h264enc '!' h264parse '!' qtmux '!' filesink location=test_fps.mp4 -e

it works, but with:

gst-launch-1.0 -vv nvarguscamerasrc sensor_id=0 '!' 'video/x-raw(memory:NVMM),width=2712,height=1538,format=NV12,framerate=90/1' '!' nvvidconv '!' nvv4l2h264enc '!' h264parse '!' qtmux '!' filesink location=test_fps.mp4 -e
....
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 2712 x 1538 FR = 29,999999 fps Duration = 33333334 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 20000, max 660000000;

GST_ARGUS: 1920 x 1080 FR = 41,000000 fps Duration = 24390244 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 20000, max 660000000;

GST_ARGUS: 2712 x 1538 FR = 29,999999 fps Duration = 33333334 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 20000, max 660000000;

GST_ARGUS: 1920 x 1080 FR = 41,000000 fps Duration = 24390244 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 20000, max 660000000;

ARGUS_ERROR: Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute: 903 Frame Rate specified is greater than supported
GST_ARGUS: Running with following settings:
   Camera index = 0
   Camera mode  = 0
   Output Stream W = 2712 H = 1538
   seconds to Run    = 0
   Frame Rate = 29,999999
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.
ARGUS_ERROR: Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute: 1139 InvalidState.
GST_ARGUS: Cleaning up
nvbuf_utils: dmabuf_fd -1 mapped entry NOT found
...

Any other idea where/what to check? Thank you!

hello razvan.grigore,

let’s focus on v4l2 pipeline at the moment.

it’s V4L2 IOCTL to verify basic camera functionality,
so, there should be something wrong from low-level driver side.
could you please also execute $ dmesg --follow along with v4l commands, is there any suspicious error while testing the camera stream?

[  125.661190] tegra-camrtc-capture-vi tegra-capture-vi: uncorr_err: request timed out after 2500 ms
[  125.661465] tegra-camrtc-capture-vi tegra-capture-vi: err_rec: attempting to reset the capture channel
[  125.668363] (NULL device *): vi_capture_control_message: NULL VI channel received
[  125.668575] t194-nvcsi 13e10000.host1x:nvcsi@15a00000: csi5_stream_close: Error in closing stream_id=0, csi_port=0
[  125.668882] (NULL device *): vi_capture_control_message: NULL VI channel received
[  125.669087] t194-nvcsi 13e10000.host1x:nvcsi@15a00000: csi5_stream_open: VI channel not found for stream- 0 vc- 1
[  125.671949] tegra-camrtc-capture-vi tegra-capture-vi: err_rec: successfully reset the capture channel
[  128.221180] tegra-camrtc-capture-vi tegra-capture-vi: uncorr_err: request timed out after 2500 ms
[  128.221442] tegra-camrtc-capture-vi tegra-capture-vi: err_rec: attempting to reset the capture channel
[  128.226061] (NULL device *): vi_capture_control_message: NULL VI channel received
[  128.226245] t194-nvcsi 13e10000.host1x:nvcsi@15a00000: csi5_stream_close: Error in closing stream_id=0, csi_port=0
[  128.226462] (NULL device *): vi_capture_control_message: NULL VI channel received
[  128.226615] t194-nvcsi 13e10000.host1x:nvcsi@15a00000: csi5_stream_open: VI channel not found for stream- 0 vc- 1
[  128.228042] tegra-camrtc-capture-vi tegra-capture-vi: err_rec: successfully reset the capture channel

hello razvan.grigore,

according to the logs… there’s failure to fetch the stream, and it’s restore by VI.

please examine the sensor driver,
did you To run a v4l2-compliance test for sanity check?
you may also refer to Camera Driver Porting since you’re moving from JP-4.x to JP-5.1.1

Ok, thanks for the help, I checked the compliance test and only this fails:

...
Buffer ioctls (Input 0):
		fail: v4l2-test-buffers.cpp(715): q.create_bufs(node, 1, &fmt) != EINVAL
	test VIDIOC_REQBUFS/CREATE_BUFS/QUERYBUF: FAIL
	test VIDIOC_EXPBUF: OK
	test Requests: OK (Not Supported)

Total for tegra-video device /dev/video0: 45, Succeeded: 44, Failed: 1, Warnings: 0

I will check with the driver provider to further debug this.

it looks fatal, VI driver needs these operations to fetch camera buffers.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.