Fps is too small on imx490 camera

Hi,
I am developing the imx490 camera ( including GW5300 and Max9295 ) driver for L4T R35.1 on AGX Orin with LI-JXAV-MIIPI-ADPT-4CAM board. I have the following issue. One imx490 camera is connected with the port 1 on the LI-JXAV-MIPI board. The image from the imx490 camera is displayed, but the FPS is 3 to 5 instead of 30. Then I found the error message in the trace log as below.

CHANSEL_NOMATCH channel:0x01 frame:0 vi_tstamp:195808528576 data:0x00000000000003c9

According to Jetson/l4t/Camera BringUp, The camera(dser) outputs the data whose type is 3c9 to the channel 1. “3c9” looks like the data type is YUV422-8. I think it is correct because this camera output is set to YUV422-8 by the internal ISP.
I set the channel 0 to receive the stream data with vc-id=0 from port 1 on the MIPI board, then I set the channel 1 to receive the stream data with vc-id=1 from the port 2 on the MIPI board. So the channel 1 should not the data without connecting the camera to port 2. But the channel 1 is about to receive data. Does this mean camera or dser(max9296) outputs the stream data with vc-id=1 ?

Any help would be appreciated.
dmesg_log.txt.gz (23.1 KB)
kernel_tegra234-p3701-0000-p3737-0000-custom.dts.gz (60.8 KB)
tracelog.txt.gz (52.6 KB)

hello user27710,

please check sensor report formats, i.e. $ v4l2-ctl -d /dev/video0 --list-formats-ext
you may also try below commands to boost all the VI/CSI/ISP clocks for testing.
for example,

sudo su
echo 1 > /sys/kernel/debug/bpmp/debug/clk/vi/mrq_rate_locked
echo 1 > /sys/kernel/debug/bpmp/debug/clk/isp/mrq_rate_locked
echo 1 > /sys/kernel/debug/bpmp/debug/clk/nvcsi/mrq_rate_locked
cat /sys/kernel/debug/bpmp/debug/clk/vi/max_rate |tee /sys/kernel/debug/bpmp/debug/clk/vi/rate
cat /sys/kernel/debug/bpmp/debug/clk/isp/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/isp/rate
cat /sys/kernel/debug/bpmp/debug/clk/nvcsi/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/nvcsi/rate

Thanks, JerryChan

I followed your advice.

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

       [0]: 'UYVY' (UYVY 4:2:2)
               Size: Discrete 2880x1860
                       Interval: Discrete 0.033s (30.000 fps)
       [1]: 'NV16' (Y/CbCr 4:2:2)
               Size: Discrete 2880x1860
                       Interval: Discrete 0.033s (30.000 fps)
       [2]: 'UYVY' (UYVY 4:2:2)
               Size: Discrete 2880x1860
                       Interval: Discrete 0.033s (30.000 fps)

Though I tried boosting, nothing changed.

Thanks.

hello user27710,

may I also know what’s your commands for checking frame-rate?
for example, please share the test results with below pipeline.
$ v4l2-ctl -d /dev/video0 --set-fmt-video=width=2880,height=1860,pixelformat=UYVY --set-ctrl bypass_mode=0 --stream-mmap --stream-count=100

Hi,JerryChang

I have been using the following command since I developped the driver for this camera on AGX Xavier devkit and another ROScube.
This command works fine with 30 fps on AGX Xavier devkit and ROScube with L4T R32.5.x and R32.6.1.

gst-launch-1.0 v4l2src io-mode=0 device=/dev/video0 do-timestamp=true ! 'video/x-raw, width=2880, height=1860, framerate=30/1, format=UYVY' ! videoscale ! video/x-raw,width=1440 ,height=930 ! fpsdisplaysink video-sink=xvimagesink sync=false  

I saw your advice and thought the videocaling element might be having an effect. So I tried changing the command like below.

gst-launch-1.0 v4l2src io-mode=0 device=/dev/video0 do-timestamp=true ! 'video/x-raw, width=2880, height=1860, framerate=30/1, format=UYVY' ! fpsdisplaysink video-sink=xvimagesink sync=false 

Then fps increased to 30.

I appreciate your advice.

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