V4l2-ctl works, however, nvarguscamerasrc fails

Hello,

We have an FPGA which streams MIPI video. It is connected to Jetson TX2 development board using a custom board. Took ov5693 as a reference driver. We initially had some issue in getting the video stream, however, we were able to resolve it by disabling CRC checks in csi4_fops.c. Custom MIPI Camera:- Gstremaer error: streaming stopped, reason not-negotiated (-4) - #34 by JerryChang. We are now able to receive the video stream using v4l2-ctl, however nvarguscamerasrc doesnot work. We get the following error:

vte-developer@vtedeveloper-desktop:~$ DISPLAY=:0.0 gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3280, height=2464, format=(string)NV12, framerate=(fraction)7/1' ! nvoverlaysink -e
Invalid MIT-MAGIC-COOKIE-1 keynvbuf_utils: Could not get EGL display connection
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
GST_ARGUS: Creating output stream
Invalid MIT-MAGIC-COOKIE-1 keyCONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 3264 x 2464 FR = 21.000000 fps Duration = 47619048 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: Running with following settings:
   Camera index = 0 
   Camera mode  = 0 
   Output Stream W = 3264 H = 2464 
   seconds to Run    = 0 
   Frame Rate = 21.000000 
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.
nvbuf_utils: dmabuf_fd -1 mapped entry NOT found
nvbuf_utils: Can not get HW buffer from FD... Exiting...
CONSUMER: Done Success
Got EOS from element "pipeline0".
Execution ended after 0:00:04.002826698
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
GST_ARGUS: Cleaning up
^C
vte-developer@vtedeveloper-desktop:~$ 

nvargus-daemon output:

vte-developer@vtedeveloper-desktop:~$ sudo nvargus-daemon &
[1] 10687
vte-developer@vtedeveloper-desktop:~$ === NVIDIA Libargus Camera Service (0.98.3)=== Listening for connections...=== gst-launch-1.0[10690]: Connection established (7F946C71D0)OFParserListModules: module list: /proc/device-tree/tegra-camera-platform/modules/module0
NvPclHwGetModuleList: WARNING: Could not map module to ISP config string
NvPclHwGetModuleList: No module data found
OFParserGetVirtualDevice: NVIDIA Camera virtual enumerator not found in proc device-tree
---- imager: No override file found. ----
LSC: LSC surface is not based on full res!
=== gst-launch-1.0[10690]: CameraProvider initialized (0x7f8c8d41b0)LSC: LSC surface is not based on full res!
NvViErrorDecode Stream 0.0 failed: ts 3930408996096 frame 25 error 2 data 0x00400060
NvViErrorDecode CaptureError: CsimuxFrameError (2)
NvViErrorDecode See https://wiki.nvidia.com/wmpwiki/index.php/Camera_Debugging/CaptureError_debugging for more information and links to documents.
CsimuxFrameError_Regular : 0x00400060
    Stream ID                [ 2: 0]: 0
        
    VPR state from fuse block    [ 3]: 0
        
    Frame end (FE)              [ 5]: 1
        A frame end has been found on a regular mode stream.
    CSI_FAULT                   [ 6]: 1
        An FE packet was found and marked with a CSI Error
    CSI_CODE                 [25:20]: 0x4
        Check the CSI specification for the meaning. See https://wiki.nvidia.com/wmpwiki/index.php/Camera_Debugging/CaptureError_debugging#CSI_CODE
captureErrorCallback Stream 0.0 capture 1 failed: ts 3930408996096 frame 25 error 2 data 0x00400060

Error: waitCsiFrameStart timeout guid 0
VI Stream Id = 0 Virtual Channel = 0
************VI Debug Registers**********
VI_CSIMUX_STAT_FRAME_0	 = 0x00000019
VI_CSIMUX_FRAME_STATUS_0	 = 0x00000000
VI_CFG_INTERRUPT_STATUS_0	 = 0x3f000000
VI_ISPBUFA_ERROR_0	 = 0x00000000
VI_FMLITE_ERROR_0	 = 0x00000000
VI_NOTIFY_ERROR_0	 = 0x00000000
*****************************************
CSI Stream Id = 0 Brick Id = 0
************CSI Debug Registers**********
CILA_INTR_STATUS_CILA[0x10400]	 = 0x00000089
CILB_INTR_STATUS_CILB[0x10c00]	 = 0x00000000
INTR_STATUS[0x100a4]	 = 0x00000004
INTR_STATUS[0x100a4]	 = 0x00000004
ERR_INTR_STATUS[0x100ac]	 = 0x00000004
ERROR_STATUS2VI_VC0[0x10094]	 = 0x00000004
ERROR_STATUS2VI_VC1[0x10098]	 = 0x00000000
ERROR_STATUS2VI_VC2[0x1009c]	 = 0x00000000
ERROR_STATUS2VI_VC3[0x100a0]	 = 0x00000000
*****************************************
SCF: Error Timeout:  (propagating from src/common/Utils.cpp, function workerThread(), line 116)
SCF: Error Timeout: Worker thread ViCsiHw frameStart failed (in src/common/Utils.cpp, function workerThread(), line 133)
SCF: Error Timeout: ISP port 0 timed out! (in src/services/capture/NvIspHw.cpp, function waitIspFrameEnd(), line 492)
waitForIdleLocked remaining request 104 
waitForIdleLocked remaining request 103 
waitForIdleLocked remaining request 102 
waitForIdleLocked remaining request 101 
SCF: Error Timeout: waitForIdle() timed out (in src/api/Session.cpp, function waitForIdleLocked(), line 928)
SCF: Error Timeout:  (propagating from src/api/Session.cpp, function abortCaptures(), line 894)
SCF: Error Timeout: ISP Stats timed out! (in src/services/capture/NvIspHw.cpp, function waitIspStatsFinished(), line 608)
PowerServiceCore:handleRequests: timePassed = 10257
=== gst-launch-1.0[10690]: Connection closed (7F946C71D0)=== gst-launch-1.0[10690]: There were pending client requests in the server at the time of CameraProvider destruction, and they failed to complete within a reasonable time (1500 ms). This may be due to a hardware or libargus error. Forced destruction will now proceed, which may leave the libargus server in a bad state.=== gst-launch-1.0[10690]: WARNING: CameraProvider was not destroyed before client connection terminated.=== gst-launch-1.0[10690]:          The client may have abnormally terminated. Destroying CameraProvider...=== gst-launch-1.0[10690]: CameraProvider destroyed (0x7f8c8d41b0)=== gst-launch-1.0[10690]: WARNING: Cleaning up 1 outstanding requests...=== gst-launch-1.0[10690]: WARNING: Cleaning up 1 outstanding stream settings...=== gst-launch-1.0[10690]: WARNING: Cleaning up 1 outstanding queues...=== gst-launch-1.0[10690]: WARNING: Cleaning up 1 outstanding sessions...waitForIdleLocked remaining request 103 
SCF: Error Timeout: waitForIdle() timed out (in src/api/Session.cpp, function waitForIdleLocked(), line 928)
(Argus) Error Timeout:  (propagating from src/api/CaptureSessionImpl.cpp, function destroy(), line 169)
SCF: Error InvalidState: 1 buffers still pending during EGLStreamProducer destruction (propagating from src/services/gl/EGLStreamProducer.cpp, function freeBuffers(), line 309)
SCF: Error InvalidState:  (propagating from src/services/gl/EGLStreamProducer.cpp, function ~EGLStreamProducer(), line 50)
waitForIdleLocked remaining request 103 
SCF: Error Timeout: waitForIdle() timed out (in src/api/Session.cpp, function waitForIdleLocked(), line 928)
SCF: Error Timeout:  (propagating from src/api/Session.cpp, function abortCaptures(), line 894)
SCF: Error Timeout:  (propagating from src/api/Session.cpp, function shutdown(), line 406)
PowerServiceCore:handleRequests: timePassed = 27350
SCF: Error Timeout:  (propagating from src/api/Session.cpp, function shutdown(), line 506)
SCF: Error Timeout:  (propagating from src/api/CameraDriver.cpp, function deleteSession(), line 635)
(Argus) Error Timeout:  (propagating from src/api/CaptureSessionImpl.cpp, function destroy(), line 194)
=== gst-launch-1.0[10690]: WARNING: Cleaning up 1 outstanding streams...=== gst-launch-1.0[10690]: NOTE: Destroy all libargus objects before destroying the CameraProvider to avoid th.
ese warnings.^C
vte-developer@vtedeveloper-desktop:~$ 

Further, after using nvarguscamerasrc for acquiring data, we cannot get any output from v4l2-ctl --set-fmt-video=width=3280,height=2464,pixelformat=RG10 --stream-mmap --stream-count=300 -d /dev/video0 however when we use v4l2-ctl --stream-mmap -c bypass_mode=0 it starts working again and subsequently v4l2-ctl --set-fmt-video=width=3280,height=2464,pixelformat=RG10 --stream-mmap --stream-count=300 -d /dev/video0 also starts working again. I guess bypass_mode=0 resets something?

Further, while using nvarguscamerasrc I can see I am getting CRC checks error, however, I have already disabled it. How do I proceed from here?

Environment details:
MIPI Ouput from FPGA: RAW10
SOM: Jetson TX2i
L4T: R32.7.3
Interface: Connected to Jetson TX2 development board using a custom board

BTW,
you cannot have different apps access to the same camera stream.
and… there’s race condition with bypass_mode property setting. you may include below to address such failure.

diff --git a/drivers/media/platform/tegra/camera/vi/channel.c b/drivers/media/platform/tegra/camera/vi/channel.c

@@ -1249,6 +1254,11 @@ int tegra_channel_s_ctrl(struct v4l2_ctrl *ctrl)
                                struct tegra_channel, ctrl_handler);
        int err = 0;

+       /* Check device is busy or not, While setting bypass mode*/
+       if (vb2_is_busy(&chan->queue) && (TEGRA_CAMERA_CID_VI_BYPASS_MODE == ctrl->id)) {
+               return -EBUSY;
+       }
+

Understood.Any update on how to move forward on nvarguscamerasrc with this? I found one thread from @ShaneCCC JetPack 4.4: XGS12M driver 4176x2168@30fps resolution issue - #6 by ShaneCCC does this apply to me then?

Please confirm the output size is 3280x2464 or 3264x2464?
What’s the v4l2-ctl --list-formats-ext?

Yes, looks like the crc error show in nvargus-daemon log.

CSI_CODE [25:20]: 0x4

Hi @ShaneCCC,

v4l2-ctl --list-formats-ext

vte-developer@vtedeveloper-desktop:~$ v4l2-ctl --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
	Index       : 0
	Type        : Video Capture
	Pixel Format: 'RG10'
	Name        : 10-bit Bayer RGRG/GBGB
		Size: Discrete 3264x2464
			Interval: Discrete 0.048s (21.000 fps)

3264 pixels with ‘2’ embedded meta data and 2464 lines

I tried changing the format to 3264 and 3266 pixels in the piepline, however, met with same error.

I would also like to inform you that although dump shows 21 FPS, my board is outputting video at 7 FPS currently, as running at high FPS was causing some signal integrity issues and as a result unstable FPS was being reported by v4l2-ctl so i reduced the FPS. As I understand v4l2-ctl --list-formats-ext just dumps the data which was in the driver, it should not have any effect on acquisition, right? As the MIPI video stream has FS and FE, the Jetson MIPI receiver will acquire the data at whatever FPS the video is being sent, right?

I just confuse why you set 3280 by v4l2-ctl command.
Please double check your device tree and get trace log for nvarguscamerasrc to check.

https://elinux.org/Jetson/l4t/Camera_BringUp

v4l2-ctl --set-fmt-video=width=3280,height=2464,pixelformat=RG10 --stream-mmap --stream-count=300 -d /dev/video0

I was following this project CSI-2 Image Simulator Lattice CrosslinkFPGA to Jetson Nano - Hackster.io and the OP used the pipeline with 3280 and got it working on Jetson nano.

Anyways, in the device tree I have mentioned active_pixel_width as 3264 and metadata height as 2. I am attaching device tree for your reference, I believe it to be correct.

	host1x {
		vi@15700000 {
			num-channels = <1>;
			ports {
				#address-cells = <1>;
				#size-cells = <0>;
				port@0 {
					status = "okay";
					reg = <0>;
					e3326_vi_in0: endpoint {
						status = "okay";
						port-index = <0>;
						bus-width = <2>;
						remote-endpoint = <&e3326_csi_out0>;
					};
				};
			};
		};
 
		nvcsi@150c0000 {
			num-channels = <1>;
			#address-cells = <1>;
			#size-cells = <0>;
			channel@0 {
				status = "okay";
				reg = <0>;
				ports {
					#address-cells = <1>;
					#size-cells = <0>;
					port@0 {
						status = "okay";
						reg = <0>;
						e3326_csi_in0: endpoint@0 {
							status = "okay"; 
							port-index = <0>;
							bus-width = <2>;
							remote-endpoint = <&e3326_ov5693_out0>;
						};
					};
					port@1 {
						status = "okay";
						reg = <1>;
						e3326_csi_out0: endpoint@1 {
							status = "okay"; 
							remote-endpoint = <&e3326_vi_in0>;
						};
					};
				};
			};
		};
	};
 
 
	i2c@3180000 {
		ov5693_c@36 {
			status = "okay"; 
			compatible = "nvidia,ov5693";
			/* I2C device address */
			reg = <0x36>;
 
			/* V4L2 device node location */
			devnode = "video0";
 
			/* Physical dimensions of sensor */
			physical_w = "3.674";
			physical_h = "2.738";
 
			/* Define any required hw resources needed by driver */
			/* ie. clocks, io pins, power sources */
			/* avdd-reg = "vana";
			iovdd-reg = "vif"; */
 
			/* Sensor output flip settings */
			vertical-flip = "true";
 
			/* Enable EEPROM support */
			has-eeprom = "0";  /* changed it to 0, as our camera doesnot have EEPROM */
			/**
			* A modeX node is required to support v4l2 driver
			* implementation with NVIDIA camera software stack
			*
			* mclk_khz = "";
			* Standard MIPI driving clock, typically 24MHz
			*
			* num_lanes = "";
			* Number of lane channels s1x {
                status="okay";
                vi@15c10000  {ensor is programmed to output
			*
			* tegra_sinterface = "";
			* The base tegra serial interface lanes are connected to
			* Incase of virtual HW devices, use virtual
			* For SW emulated devices, use host
			*
			* phy_mode = "";
			* PHY mode used by the MIPI lanes for this device
			*
			* discontinuous_clk = "";
			* The sensor is programmed to use a discontinuous clock on MIPI lanes
			*
			* dpcm_enable = "true";
			* The sensor is programmed to use a DPCM modes
			*
			* cil_settletime = "";
			* MIPI lane settle time value.
			* A "0" value attempts to autocalibrate based on mclk_multiplier
			*
			*
			*
			*
			* active_w = "";
			* Pixel active region width
			*
			* active_h = "";
			* Pixel active region height
			*
			* pixel_t = "";
			* The sensor readout pixel pattern
			*
			* readout_orientation = "0";
			* Based on camera module orientation.
			* Only change readout_orientation if you specifically
			* Program a different readout order for this mode
			*
			* line_length = "";
			* Pixel line length (width) for sensor mode.
			* This is used to calibrate features in our camera stack.
			*
			* mclk_multiplier = "";
			* Multiplier to MCLK to help time hardware capture sequence
			* TODO: Assign to PLL_Multiplier as well until fixed in core
			*
			* pix_clk_hz = "";
			* Sensor pixel clock used for calculations like exposure and framerate
			*
			*
			*
			*
			* inherent_gain = "";
			* Gain obtained inherently from mode (ie. pixel binning)
			*
			* == Source Control Settings ==
			*
			* Gain factor used to convert fixed point integer to float
			* Gain range [min_gain/gain_factor, max_gain/gain_factor]
			* Gain step [step_gain/gain_factor is the smallest step that can be configured]
			* Default gain [Default gain to be initialized for the control.
			*     use min_gain_val as default for optimal results]
			* Framerate factor used to convert fixed point integer to float
			* Framerate range [min_framerate/framerate_factor, max_framerate/framerate_factor]
			* Framerate step [step_framerate/framerate_factor is the smallest step that can be configured]
			* Default Framerate [Default framerate to be initialized for the control.
			*     use max_framerate to get required performance]
			* Exposure factor used to convert fixed point integer to float
			* For convenience use 1 sec = 1000000us as conversion factor
			* Exposure range [min_exp_time/exposure_factor, max_exp_time/exposure_factor]
			* Exposure step [step_exp_time/exposure_factor is the smallest step that can be configured]
			* Default Exposure Time [Default exposure to be initialized for the control.
			*     Set default exposure based on the default_framerate for optimal exposure settings]
			*
			* gain_factor = ""; (integer factor used for floating to fixed point conversion)
			* min_gain_val = ""; (ceil to integer)
			* max_gain_val = ""; (ceil to integer)
			* step_gain_val = ""; (ceil to integer)
			* default_gain = ""; (ceil to integer)
			* Gain limits for mode
			*
			* exposure_factor = ""; (integer factor used for floating to fixed point conversion)
			* min_exp_time = ""; (ceil to integer)
			* max_exp_time = ""; (ceil to integer)
			* step_exp_time = ""; (ceil to integer)
			* default_exp_time = ""; (ceil to integer)
			* Exposure Time limits for mode (us)
			*
			*
			* min_hdr_ratio = "";
			* max_hdr_ratio = "";
			* HDR Ratio limits for mode
			*
			* framerate_factor = ""; (integer factor used for floating to fixed point conversion)
			* min_framerate = "";
			* max_framerate = "";
			* step_framerate = ""; (ceil to integer)
			* default_framerate = ""; (ceil to integer)
			* Framerate limits for mode (fps)
			*/
			mode0 { // OV5693_MODE_2592X1944
				mclk_khz = "24000";
				num_lanes = "2";
				tegra_sinterface = "serial_a";
				phy_mode = "DPHY";
				discontinuous_clk = "yes";
				dpcm_enable = "false";
				cil_settletime = "0";
 
				active_w = "3264"; /* changed original value*/
				active_h = "2464"; /* changed original value*/
				/*mode_type = "bayer";
				pixel_phase = "bggr"; */ /*imx219 doesnot have it*/
				pixel_t = "bayer_rggb";
				/* csi_pixel_bit_depth = "10"; */
				readout_orientation = "90";
				line_length = "3448"; /*2688 replaced with imx219*/
				inherent_gain = "1";
				/* mclk_multiplier = "9.33"; 6.67 replaced with imx219 value */
				pix_clk_hz = "182400000"; /* 160000000 replaced with imx219 value*/
 
				gain_factor = "16"; /* 10 replaced with imx219 value*/
				min_gain_val = "16";/* 1DB*/ /*10 replaced with imx219*/
				max_gain_val = "170";/* 16DB*/ /* 160 replaced with imx219 value*/
				step_gain_val = "1";
				default_gain = "16"; /* 10 replaced with imx219 value*/
				min_hdr_ratio = "1";
				max_hdr_ratio = "1";
				framerate_factor = "1000000";
				min_framerate = "2000000";/*1.816577 */ /* 1816577 replaced with imx219 value i.e 2fps*/ 
				max_framerate = "21000000";/*30*/ /* 30000000 replaced with imx219 value i.e 21 fps*/
				step_framerate = "1";
				default_framerate = "21000000"; /* 30000000 replaced with imx219 value i.e. 21 fps */
				exposure_factor = "1000000";
				min_exp_time = "13";/* us */ /* 34 replaced with imx219 value*/
				max_exp_time = "683709";/* us */ /* 550385 replaced with imx219 value*/
				step_exp_time = "1";
				default_exp_time = "2495";/* us */ /* 33334 replaced with imx219 value */
				embedded_metadata_height = "2"; /* 0 replaced with imx219 value*/
			};
 
			/* Removed two modules, we need only one and our custom MIPI doesnot have multiple modes */
 
			ports {
				status = "okay";
				#address-cells = <1>;
				#size-cells = <0>;
				port@0 {
					status = "okay";
					reg = <0>;
					e3326_ov5693_out0: endpoint {
						status = "okay";
						port-index = <0>;
						bus-width = <2>;
						remote-endpoint = <&e3326_csi_in0>;
					};
				};
			};
		};
	};
 
/* Removed lens */
 
	tegra-camera-platform {
		compatible = "nvidia, tegra-camera-platform";
		/**
		* Physical settings to calculate max ISO BW
		*
		* num_csi_lanes = <>;
		* Total number of CSI lanes when all cameras are active
		*
		* max_lane_speed = <>;
		* Max lane speed in Kbit/s
		*
		* min_bits_per_pixel = <>;
		* Min bits per pixel
		*
		* vi_peak_byte_per_pixel = <>;
		* Max byte per pixel for the VI ISO case
		*
		* vi_bw_margin_pct = <>;
		* Vi bandwidth margin in percentage
		*
		* max_pixel_rate = <>;
		* Max pixel rate in Kpixel/s for the ISP ISO case
		*
		* isp_peak_byte_per_pixel = <>;
		* Max byte per pixel for the ISP ISO case
		*
		* isp_bw_margin_pct = <>;
		* Isp bandwidth margin in percentage
		*/
		num_csi_lanes = <2>;
		max_lane_speed = <1500000>;
		min_bits_per_pixel = <10>;
		vi_peak_byte_per_pixel = <2>;
		vi_bw_margin_pct = <25>;
		max_pixel_rate = <160000>;
		isp_peak_byte_per_pixel = <5>;
		isp_bw_margin_pct = <25>;
		/**
		* The general guideline for naming 1x {
                status="okay";
                vi@15c10000  {badge_info contains 3 parts, and is as follows,
		* The first part is the camera_board_id for the module; if the module is in a FFD
		* platform, then use the platform name for this part.
		* The second part contains the position of the module, ex. “rear” or “front”.
		* The third part contains the last 6 characters of a part number which is found
		* in the module's specsheet from the vender.
		*/
		modules {
			module0 {
				status = "okay";
				badge = "e3326_front_P5V27C";
				position = "rear";
				orientation = "1";
				drivernode0 {
					status = "okay";
					/* Declare PCL support driver (classically known as guid)  */
					pcl_id = "v4l2_sensor";
					/* Driver v4l2 device name */
					devname = "ov5693 2-0036";
					/* Declare the device-tree hierarchy to driver instance */
					proc-device-tree = "/proc/device-tree/i2c@3180000/ov5693_c@36";
				};
				drivernode1 {
					/* Declare PCL support driver (classically known as guid)  */
					status = "disabled";
					pcl_id = "v4l2_lens";
					proc-device-tree = "/proc/device-tree/e3326_lens_ov5693@P5V27C/";
				};
			};
		};
	};
};

I used this pipeline DISPLAY=:1.0 gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3264, height=2464, format=(string)NV12, framerate=(fraction)7/1' ! nvoverlaysink -eand nvarguscamerasrc tracelog also shows CRC error. nvarguscamerasrc_traces.txt (110.5 KB)

In the camera bring up link, which you shared, I have killed nvargus-daemon, exported those two variables, however, I could not find nvargus-daemon/argus_daemon/nvcamera-daemon inside sbin directory. Can you guide me what to do here?

Also you want output of this pipeline? Here is the trace log for v4l2-ctl pipeline traces.txt (12.3 KB)

vte-developer@vtedeveloper-desktop:~$ v4l2-ctl --set-fmt-video=width=3280,height=2464,pixelformat=RG10 --stream-mmap --stream-count=300 -d /dev/video0
<<<<<<<<< 7.14 fps
<<<<<<< 7.14 fps
<<<<<<< 7.11 fps
<<<<<<< 7.12 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<^C

Hi @ShaneCCC,

Apart from CRC error do you see something else? what can I do next?

Hi @ShaneCCC @JerryChang,

Any update?

Looks like didn’t receive any validate data from the trace log get from v4l2-ctl .

Hi @kayccc,

Please ignore the trace log v4l2-ctl log from, It seems I did not log it properly, I will update you with latest log once I have access to the system. The v4l2-ctl for me usually looks like this.
tracelog.txt (407.1 KB)
V4l2-ctl pipeline work for me, I have resolved this here: Custom MIPI Camera:- Gstremaer error: streaming stopped, reason not-negotiated (-4) - #35 by jetuser

Please try infinite timeout configure.

sudo service nvargus-daemon stop
sudo enableCamInfiniteTimeout=1 nvargus-daemon

Hi @ShaneCCC,

I have tried setting infinite time out to 1. Still cannot acquire the stream. However, if I use v4l2-ctl pipeline I can see it is working. PFB the logs

vte-developer@vtedeveloper-desktop:~$ DISPLAY=:1.0 gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3264, height=2464, format=(string)NV12, framerate=(fraction)7/1' ! nvoverlaysink -e
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 3264 x 2464 FR = 21.000000 fps Duration = 47619048 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;

GST_ARGUS: Running with following settings:
   Camera index = 0 
   Camera mode  = 0 
   Output Stream W = 3264 H = 2464 
   seconds to Run    = 0 
   Frame Rate = 21.000000 
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 137)
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
nvbuf_utils: dmabuf_fd -1 mapped entry NOT found
nvbuf_utils: Can not get HW buffer from FD... Exiting...
CONSUMER: Done Success
Got EOS from element "pipeline0".
Execution ended after 0:01:01.013250272
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
GST_ARGUS: Cleaning up
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 137)
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 137)
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
GST_ARGUS: Done Success
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 137)
(Argus) Error Timeout:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
Setting pipeline to NULL ...
Freeing pipeline ...
^C
vte-developer@vtedeveloper-desktop:~$ 
vte-developer@vtedeveloper-desktop:~$ sudo enableCamInfiniteTimeout=1 nvargus-daemon
=== NVIDIA Libargus Camera Service (0.98.3)=== Listening for connections...=== gst-launch-1.0[10060]: Connection established (7F9CB911D0)OFParserListModules: module list: /proc/device-tree/tegra-camera-platform/modules/module0
NvPclHwGetModuleList: WARNING: Could not map module to ISP config string
NvPclHwGetModuleList: No module data found
OFParserGetVirtualDevice: NVIDIA Camera virtual enumerator not found in proc device-tree
---- imager: No override file found. ----
LSC: LSC surface is not based on full res!
=== gst-launch-1.0[10060]: CameraProvider initialized (0x7f988d47e0)LSC: LSC surface is not based on full res!
SCF: Error InvalidState: 2 buffers still pending during EGLStreamProducer destruction (propagating from src/services/gl/EGLStreamProducer.cpp, function freeBuffers(), line 309)
SCF: Error InvalidState:  (propagating from src/services/gl/EGLStreamProducer.cpp, function ~EGLStreamProducer(), line 50)
^C
vte-developer@vtedeveloper-desktop:~$ 

traces: tracelog.txt (2.3 MB)
By looking at the tracelog, it looks like a jetson cannot acquire video stream at all.

Subsequent to this, I tried v4l2-ctl

vte-developer@vtedeveloper-desktop:~$ v4l2-ctl --stream-mmap -c bypass_mode=0
<<<<<<<<< 7.14 fps
<<<<<<< 7.14 fps
<<<<<<< 7.11 fps
<<<<<<< 7.12 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.10 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.11 fps
<<<<<<< 7.10 fps
<<<<<^C
vte-developer@vtedeveloper-desktop:~$ 

tracelog:
tracelog.txt (237.1 KB)

So you have modify the csi4_fops.c to ignore the CRC error than the v4l2-ctl able to worked?
I would like to tell for your case due to we don’t have public source release for argus to disable the CRC I would suggest don’t use nvarguscamerasrc. Maybe use v4l2 APP with software debayer for it.

Thank You @ShaneCCC for all the help.

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