Nvarguscamerasrc does not work

Hello

I am having problems getting the “gst-launch-1.0 nvarguscamerasrc” to work.

Jetson Linux 35.3.1

With v4l2-ctl I can save raw images that also look good

v4l2-ctl -d /dev/video0 --set-fmt-video=width=3856,height=2201,pixelformat=RG12 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=1 --stream-to=test.raw

but when I run gst-launch-1.0 nvarguscamerasrc, gstreamer opens for a short time but only shows a black image

gst-launch-1.0 nvarguscamerasrc ! ‘video/x-raw(memory:NVMM),width=3856,height=2202,framerate=36/1,format=NV12’ ! queue ! nv3dsink

I get two different outputs depending on whether the nvargus-deamon is listening in parallel or not

Output when the nvargus daemon is listening:

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: 3856 x 2202 FR = 36,000000 fps Duration = 27777778 ; Analog Gain range min 0,000000, max 48,000000; Exposure Range min 34000, max 550385000;

GST_ARGUS: Running with following settings:
   Camera index = 0 
   Camera mode  = 0 
   Output Stream W = 3856 H = 2202 
   seconds to Run    = 0 
   Frame Rate = 36,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
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadExecute:694 NvBufSurfaceFromFd Failed.
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadFunction:247 (propagating)
ERROR: from element /GstPipeline:pipeline0/GstNvArgusCameraSrc:nvarguscamerasrc0: DISCONNECTED
Additional debug info:
Argus Error Status
Execution ended after 0:00:00.642667584
Setting pipeline to NULL ...
(Argus) Error EndOfFile: Unexpected error in reading socket (in src/rpc/socket/client/ClientSocketManager.cpp, function recvThreadCore(), line 277)
(Argus) Error EndOfFile: Receiving thread terminated with error (in src/rpc/socket/client/ClientSocketManager.cpp, function recvThreadWrapper(), line 379)
GST_ARGUS: Cleaning up
(Argus) Error InvalidState: Receive thread is not running cannot send. (in src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 96)
(Argus) Error InvalidState:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
(Argus) Error InvalidState: Receive thread is not running cannot send. (in src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 96)
(Argus) Error InvalidState:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
(Argus) Error InvalidState: Receive thread is not running cannot send. (in src/rpc/socket/client/ClientSocketManager.cpp, function send(), line 96)
(Argus) Error InvalidState:  (propagating from src/rpc/socket/client/SocketClientDispatch.cpp, function dispatch(), line 91)
Caught SIGSEGV
Segmentation fault (core dumped)

Output when the nvargus daemon is not listening:

gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM),width=3856,height=2202,framerate=36/1,format=NV12' ! queue ! nv3dsink
(Argus) Error FileOperationFailed: Connecting to nvargus-daemon failed: Connection refused (in src/rpc/socket/client/SocketClientDispatch.cpp, function openSocketConnection(), line 204)
(Argus) Error FileOperationFailed: Cannot create camera provider (in src/rpc/socket/client/SocketClientDispatch.cpp, function createCameraProvider(), line 106)
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:746 Failed to create CameraProvider
Got EOS from element "pipeline0".
Execution ended after 0:00:00.002584672
Setting pipeline to NULL ...
Freeing pipeline ...

nvargus-daemon log

=== NVIDIA Libargus Camera Service (0.99.33)=== Listening for connections...=== gst-launch-1.0[2451]: Connection established (FFFF95980900)Thread 1 getting next capture
Thread 1 is waiting
Thread 2 getting next capture
Thread 2 is waiting
Thread 3 getting next capture
Thread 3 is waiting
Thread 4 getting next capture
Thread 4 is waiting
Thread 5 getting next capture
Thread 5 is waiting
Thread 6 getting next capture
Thread 6 is waiting
Thread 7 getting next capture
Thread 7 is waiting
Thread 8 getting next capture
Thread 8 is waiting
Thread 9 getting next capture
Thread 9 is waiting
Thread 10 getting next capture
Thread 10 is waiting
Thread 11 getting next capture
Thread 12 getting next captureThread 11 is waiting

Thread 12 is waiting
Starting services...
Worker thread IspHw frameComplete start
Worker thread CaptureScheduler checkFramePending start
Worker thread CaptureScheduler frameStart start
Worker thread V4L2CaptureScheduler checkCaptureComplete start
Worker thread V4L2CaptureScheduler issueCaptures start
Worker thread PS handleRequests start
getInstance: s_instance(0xffff90633ff0)
getInstance: s_instance(0xffff90633ff0)
subscribe: SensorType(gyroscope)
subscribe: create SensorType(gyroscope) sensor(0xffff904a5090)
subscribe: SensorType(accelerometer)
subscribe: create SensorType(accelerometer) sensor(0xffff904843b0)
AC plugin not present: dlopen "acplugin.so", acplugin.so: cannot open shared object file: No such file or directory
Services are started
NvPclSetHotplugCallback: ++++++++++++++++++++++
---- Imager: Calibration blob file handling supported in this build ----
NvPclHwGetModuleList: OFParserListModules Succeeded
NvPclModuleListInitialize: numBuiltinModules 1 11
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
NvPclHwPrintModuleDefinition -- Name: imx728_rear_liimx728
NvPclHwPrintModuleDefinition -- Position: 0
NvPclHwPrintModuleDefinition -- CalibrationData Found: 1
NvPclHwPrintCameraSubModule -- HwCamSubModule[0].Name: v4l2_sensor
NvPclHwPrintCameraSubModule -- HwCamSubModule[0].DevName: imx728 2-001a
NvPclHwGetModuleList: OFParserListModules Succeeded
NvPclModuleListInitialize: numBuiltinModules 1 22
NvPclModuleListInitialize: NvPclModule list[0]: imx728_rear_liimx728 position 0 numBuiltinModules 1
NvPclHwScanExternalCameras -- adding video0 to discover list
NvPclModuleListInitialize: numPlugableModules 1 +++
NvPclHwScanExternalCameras -- adding video0 to discover list
NvPclHwAddModules isVirtual 1 ^^^^^^^^
NvPclHwScanExternalCameras -- adding video0 to discover list
NvPclHwAddModules isVirtual 1 ^^^^^^^^
NvPclHwAddModules isVirtual 0 ^^^^^^^^
NvPclHwAddModules isVirtual 0 ^^^^^^^^
NvPclModuleListInitialize: numPlugableModules 0 ---
getHotplugMonitor: Getting hotplug monitor instance
 initializeHotplug++
 hotPlugfunc ++ 
 addWatch: Watch added wd='1'
CheckProcDTExists: INFO: accessing /proc/device-tree/tegra-virtual-camera-platform/modules; No such file or directory
OFParserGetVirtualDevice: NVIDIA Camera virtual enumerator not found in proc device-tree
setHotplugCallback: Registered new callback client
NvPclSetHotplugCallback: ----------------------
 hotPlugfunc: reading from inotify FD, Thread waiting 
numSources: numSources 1 

numSources: numSources 1 

numSources: numSources 1 

getSource: index 0 and numSources 1

numSources: numSources 1 

numSources: numSources 1 


 addSourceByIndex: index 0 and guid 0ud 

NvPclOpen: ++++++++++++++++++++++
NvPclStateControllerOpen: Found GUID 0 match at index[0]
NvPclHwInitializeModule: allocate overrides pathname @ 0xffff9056f9a0
NvPclHwInitializeModule: allocate overrides pathname @ 0xffff9062c2a0
NvPclHwInitializeModule: allocate overrides pathname @ 0xffff905df9b0
NvPclHwInitializeModule: allocate overrides pathname @ 0xffff905df8f0
NvPclHwInitializeModule: allocate overrides pathname @ 0xffff906e9500
NvPclHwInitializeModule: allocate overrides pathname @ 0xffff906b2da0
LoadOverridesFile: looking for override file [/Calib/camera_override.isp] 1/16
CheckOverridesPermissions: stat(/Calib/camera_override.isp) call failed
LoadOverridesFile: looking for override file [/data/vendor/nvcam/settings/camera_overrides.isp] 2/16
CheckOverridesPermissions: stat(/data/vendor/nvcam/settings/camera_overrides.isp) call failed
LoadOverridesFile: looking for override file [/opt/nvidia/nvcam/settings/camera_overrides.isp] 3/16
CheckOverridesPermissions: stat(/opt/nvidia/nvcam/settings/camera_overrides.isp) call failed
LoadOverridesFile: looking for override file [/var/nvidia/nvcam/settings/camera_overrides.isp] 4/16
CheckOverridesPermissions: stat(/var/nvidia/nvcam/settings/camera_overrides.isp) call failed
LoadOverridesFile: looking for override file [/data/vendor/nvcam/camera_overrides.isp] 5/16
CheckOverridesPermissions: stat(/data/vendor/nvcam/camera_overrides.isp) call failed
LoadOverridesFile: looking for override file [/data/vendor/nvcam/settings/imx728_rear_liimx728.isp] 6/16
CheckOverridesPermissions: stat(/data/vendor/nvcam/settings/imx728_rear_liimx728.isp) call failed
LoadOverridesFile: looking for override file [/opt/nvidia/nvcam/settings/imx728_rear_liimx728.isp] 7/16
CheckOverridesPermissions: stat(/opt/nvidia/nvcam/settings/imx728_rear_liimx728.isp) call failed
LoadOverridesFile: looking for override file [/var/nvidia/nvcam/settings/imx728_rear_liimx728.isp] 8/16
CheckOverridesPermissions: stat(/var/nvidia/nvcam/settings/imx728_rear_liimx728.isp) call failed
---- imager: No override file found. ----
Imager: looking for override file [/mnt/factory/camera/factory.bin] 1/16
Imager: looking for override file [/Calib/factory.bin] 2/16
Imager: looking for override file [/Calib/calibration.bin] 3/16
Imager: looking for override file [(null)] 4/16
Imager: looking for override file [(null)] 5/16
Imager: looking for override file [(null)] 6/16
Imager: looking for override file [(null)] 7/16
Imager: looking for override file [(null)] 8/16
Imager: looking for override file [(null)] 9/16
Imager: looking for override file [(null)] 10/16
Imager: looking for override file [(null)] 11/16
Imager: looking for override file [(null)] 12/16
Imager: looking for override file [(null)] 13/16
Imager: looking for override file [(null)] 14/16
Imager: looking for override file [(null)] 15/16
Imager: looking for override file [(null)] 16/16
Imager: looking for override file [/data/vendor/nvcam/settings/factory.bin] 1/16
Imager: looking for override file [/data/vendor/nvcam/settings/imx728_rear_liimx728.bin] 2/16
Imager: looking for override file [/opt/nvidia/nvcam/settings/imx728_rear_liimx728.bin] 3/16
Imager: looking for override file [/var/nvidia/nvcam/settings/imx728_rear_liimx728.bin] 4/16
Imager: looking for override file [(null)] 5/16
Imager: looking for override file [(null)] 6/16
Imager: looking for override file [(null)] 7/16
Imager: looking for override file [(null)] 8/16
Imager: looking for override file [(null)] 9/16
Imager: looking for override file [(null)] 10/16
Imager: looking for override file [(null)] 11/16
Imager: looking for override file [(null)] 12/16
Imager: looking for override file [(null)] 13/16
Imager: looking for override file [(null)] 14/16
Imager: looking for override file [(null)] 15/16
Imager: looking for override file [(null)] 16/16
NvPclCreateDriver: Found NvPcl Driver Hal dev_name match (v4l2_sensor)
NvPclCreateDriver: Found a Driver name match (v4l2_sensor)
NvPclConnectDrivers: hImager was NULL, creating new imager
NvPclInitializeDrivers: v4l2_sensor ++++++++++++++++++
OFDPropertyGetString: could not read property [devnode-bus]
OFDPropertyGetString: could not read property [use_decibel_gain]
OFDPropertyGetString: could not read property [use_sensor_mode_id]
OFDPropertyGetString: could not read property [delayed_gain]
OFDPropertyCopyToLong: could not read property [has-eeprom]
OFDPropertyGetString: could not read property [sync_sensor]
OFDPropertyGetString: could not read property [type]
loadSubType: Sensor type missing in DT, 206
OFDPropertyCopyToLong: could not read property [set_mode_delay_ms]
OFDPropertyCopyToLong: could not read property [mode0.vc_id]
OFDPropertyCopyToFloat: could not read property [mode0.gain_step_pitch]
OFDPropertyCopyToLong: could not read property [mode0.clk_settletime]
OFDPropertyCopyToLong: could not read property [mode0.embedded_metadata_width]
OFDPropertyCopyToLong: could not read property [mode0.lane_polarity]
OFDPropertyGetString: could not read property [mode0.x_start]
OFDPropertyGetString: could not read property [mode0.y_start]
OFDPropertyGetString: could not read property [mode0.x_end]
OFDPropertyGetString: could not read property [mode0.y_end]
OFDPropertyGetString: could not read property [mode0.h_scaling]
OFDPropertyGetString: could not read property [mode0.v_scaling]
initialize: Loaded Driver: 1 Modes Available--------------
NvPclInitializeDrivers: v4l2_sensor ------------------
NvPclOpen: ----------------------
LSC: LSC surface is not based on full res!
numSources: numSources 1 

=== gst-launch-1.0[2451]: CameraProvider initialized (0xffff906afd80)sourceRegistry[0] assigned

ispRegistry[0] assigned

Worker thread ViCsiHw frameComplete start
Worker thread ViCsiHw frameStart start
NvPclPowerOn: +++++++++++
NvPclPowerOn: -----------
Using ISP A
NvPHSSendThroughputHints: sensorId=0, m_usecase=4, m_type=2, m_value=4294967295, m_timeout_ms=1000

SCF: Error BadValue: NvPHSSendThroughputHints (in src/common/CameraPowerHint.cpp, function sendCameraPowerHint(), line 56)
LSC: LSC surface is not based on full res!
AC plugin not present: dlopen "acplugin.so", acplugin.so: cannot open shared object file: No such file or directory
No library found, disabling AC plugin.
Worker thread CaptureDispatcher start
setupCC: inputBuffer (nil) or inStream (nil) and mode 0

genInstructionBayerSource: useSensorCaptureStage 1 useMemoryToISPCaptureStage 1 and useSensorISPCapture 0 

No output buffers for 2
No output buffers for 1
genInstructionBayerSource: useMemoryToISPCaptureStage bayerOutMask, outBufMask and yuvOutBufMask 0, 1 1

findMatchingBufIndexes:2nd Pass: bufState size 2readAccess 0 and writeAccess 1 and effectiveGroup 0xffff540013d0

findMatchingBufIndexes:2nd Pass: bufState size 3readAccess 1 and writeAccess 0 and effectiveGroup 0xffff54000d40

routeForNextStage: ccIndex 3 adScalingBit

InstructionList:
  + GraphSettings
      | SensorMode: 3856x2202 BayerS16RGGB 36.0fps
      | output 0: 3856x2202 BL U8_V8_ER 420SP
      | inputClipRect 0: (0.00,0.00, 1.00,1.00)
      | sharedIsp

  + Instruction List
      | id: 0
      +  0: CCDataSetupStage
          | EstimatedIspOutLatencyFrames: 6
          | NumConcurrentCaptures: 1
          | UnprocessedYuvBufferMask: 0
      +  1: ACSynchronizeStage
      +  2: AeAfApplyStage
      +  3: AcPluginStage
          | operation: opApply
      +  4: AcMergeStage
          | IspIn: [3856, 2202]
          | IspOut0: [3856, 2202]
          | IspOut1: [0, 0]
          | IspOut2: [640, 366]
      +  5: TempBufferAcquireStage
          | Buffer Index: 3
          | BufferRequirements: 3856x2202 Pitch BayerS16RGGB
      +  6: TempBufferAcquireStage
          | Buffer Index: 4
          | BufferRequirements: 3856x1 Pitch NonColor8
      +  7: SensorCaptureStage
          | Master: 1
          | Source GUID: 0
          | Output Buffer: 3
          | SensorMetadata Buffer: 4
      +  8: StatsBufferAcquireStage
          | Buffer Index: 1
          | BufferRequirements: 640x366 Pitch U8_V8_ER 420SP
      +  9: TempBufferAcquireStage
          | Buffer Index: 2
          | BufferRequirements: 524288x1 Pitch NonColor8
      + 10: MemoryToISPCaptureStage
          | Master: 1
          | Input Buffer: 3
          | Output A Buffer: 0
          | Output Thumb Buffer: 1
          | Output IspStats Buffer: 2
          | Source GUID: 0
      + 11: BufferReturnStage
          | Output A Buffer: 3
      + 12: StatsUpdateStage
          | Output Meta Buffer: 4
          | Output IspStats Buffer: 2
      + 13: BufferReturnStage
          | Output A Buffer: 4
      + 14: BufferReturnStage
          | Output A Buffer: 2
      + 15: AcPluginStage
          | operation: opAnalyze
      + 16: AfAnalysisStage
      + 17: MonitorStage
      + 18: ExifStage
      + 19: MakerNoteStage
      + 20: BufferReturnStage
          | Output A Buffer: 0
      + 21: MetadataReturnStage
      + 22: PerfStatsStage

setupCC: ccId 101 done

setupCC: inputBuffer (nil) or inStream (nil) and mode 0

Created fiber 0xffff48000b60 for CC 101 globalID 101 session 0
Thread 1 is working on CC 101 session 0 globalID 101 step 0
setupCC: ccId 102 done

Created fiber 0xffff48000e10 for CC 102 globalID 102 session 0
Thread 2 is working on CC 102 session 0 globalID 102 step 0
setupCC: inputBuffer (nil) or inStream (nil) and mode 0

CC: RawReprocessEnable 0 

CC 102 session 0 stalled step 0 in fiber 0xffff48000e10
FiberScheduler: cc 102, session 0 fiber 0xffff48000e10 not ready to execute stalled on 0xffff90b08b80 stage...

Thread 2 getting next capture
Thread 2 is waiting
setupCC: ccId 103 done

Thread 3 is waiting
assignAllBuffersFromStream is done ii 0 stream 0xffff50001350 and buffer 0xffff50009900%

CC 101 session 0 completed step 0 in fiber 0xffff48000b60
Thread 4 is working on CC 102 session 0 globalID 102 step 0
cc 101(1) session 0 runCount=0 runIspOut=0, latest ccId=0
CC 101 session 0 completed step 1 in fiber 0xffff48000b60
CC: RawReprocessEnable 0 

NV AE and AfApply algorithms are active.
assignAllBuffersFromStream is done ii 0 stream 0xffff50001350 and buffer 0xffff5000b070%

CC 102 session 0 completed step 0 in fiber 0xffff48000e10
cc 102(2) session 0 runCount=1 runIspOut=0, latest ccId=0
CC 102 session 0 completed step 1 in fiber 0xffff48000e10
CC 102 session 0 stalled step 2 in fiber 0xffff48000e10
FiberScheduler: cc 102, session 0 fiber 0xffff48000e10 not ready to execute stalled on 0xffff906e91f0 stage...

Thread 4 getting next capture
Thread 4 is waiting
Thread 5 is waiting
CC 101 session 0 completed step 2 in fiber 0xffff48000b60
Thread 6 is working on CC 102 session 0 globalID 102 step 2
NV AE and AfApply algorithms are active.
CC 101 session 0 completed step 3 in fiber 0xffff48000b60
CC 102 session 0 completed step 2 in fiber 0xffff48000e10
CC 102 session 0 completed step 3 in fiber 0xffff48000e10
CC 102 session 0 stalled step 4 in fiber 0xffff48000e10
FiberScheduler: cc 102, session 0 fiber 0xffff48000e10 not ready to execute stalled on 0xffff90b08900 stage...

Thread 6 getting next capture
Thread 6 is waiting
Thread 7 is waiting
CC 101 session 0 completed step 4 in fiber 0xffff48000b60
Thread 8 is working on CC 102 session 0 globalID 102 step 4
CC 102 session 0 completed step 4 in fiber 0xffff48000e10
CC 101 session 0 completed step 5 in fiber 0xffff48000b60
CC 101 session 0 completed step 6 in fiber 0xffff48000b60
CC 101 session 0 processing step 7 in fiber 0xffff48000b60
FiberScheduler: cc 101, session 0, fiber 0xffff48000b60 in progress...

Thread 1 getting next capture
Thread 1 is waiting
Thread 9 is waiting
CC 102 session 0 completed step 5 in fiber 0xffff48000e10
CC 102 session 0 completed step 6 in fiber 0xffff48000e10
CC 102 session 0 processing step 7 in fiber 0xffff48000e10
FiberScheduler: cc 102, session 0, fiber 0xffff48000e10 in progress...

Thread 8 getting next capture
Thread 8 is waiting
Thread 10 is waiting
Sensorhw::setSensorMode 0 and TimeMs 152800 +++

NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
writeMode: Target mode Id(0): Resolution 3856x2202
writeFrameRate:	INPUT frameRate:36.000000
writeGain:	INPUT gainCtrl:0 analogGain:0.000000
updateOutputSettings:	OUTPUT frameRate:36.000000
updateOutputSettings:	OUTPUT analogGain:0.000000
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
Sensorhw::setSensorMode 0 and TimeMs 152800 ---

NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
writeGain:	INPUT gainCtrl:b analogGain:1.200000
writeExposure:	INPUT expTime:0.027778
updateOutputSettings:	OUTPUT analogGain:1.100000
updateOutputSettings:	OUTPUT expTime:0.027777
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
PowerServiceHw:addRequest: table size: before: 0, after:1
	request table for ISP 0:
	req[0]: output1 width=0, output1 height=0, output1 Bpp=0
	req[0]: output2 width=0, output2 height=0, output2 Bpp=0
	req[0]: input width=3856, input height=2202, input Bpp=12
	req[0]: output width=3856, output height=2202, output Bpp=16
	req[0]: input fps=36
	req[0]: guID=0, stage type=MemIspCapture
	req[0]: clock=0 Hz, iso bw=0 KB/s, non-iso bw=1212466 KB/s
	req[450]: timeout=8
PowerServiceHwIsp:setLaBw: m_bwVal_Iso=0 and m_bwVal_NonIso=1212466 KBpS

PowerServiceCore:setCameraBw: totalNonIsoBw=1212466
Sensorhw::setSensorMode 0 and TimeMs 152873 +++

NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
Sensorhw::setSensorMode 0 and TimeMs 152873 ---

Sensorhw::enableSensor 0 and TimeMs 152873 +++

NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
Sensorhw::enableSensor 0 and TimeMs 152873 ---

Created fiber 0xffff48000fb0 for CC 103 globalID 103 session 0
Thread 11 is working on CC 103 session 0 globalID 103 step 0
setupCC: inputBuffer (nil) or inStream (nil) and mode 0

CC: RawReprocessEnable 0 

setupCC: ccId 104 done

assignAllBuffersFromStream is done ii 0 stream 0xffff50001350 and buffer 0xffff5000c640%

CC 103 session 0 completed step 0 in fiber 0xffff48000fb0
cc 103(3) session 0 runCount=2 runIspOut=0, latest ccId=0
CC 103 session 0 completed step 1 in fiber 0xffff48000fb0
NV AE and AfApply algorithms are active.
CC 103 session 0 completed step 2 in fiber 0xffff48000fb0
CC 103 session 0 completed step 3 in fiber 0xffff48000fb0
CC 103 session 0 completed step 4 in fiber 0xffff48000fb0
CC 103 session 0 completed step 5 in fiber 0xffff48000fb0
CC 103 session 0 completed step 6 in fiber 0xffff48000fb0
CC 103 session 0 processing step 7 in fiber 0xffff48000fb0
FiberScheduler: cc 103, session 0, fiber 0xffff48000fb0 in progress...

Thread 11 getting next capture
Thread 11 is waiting
Thread 12 is waiting
NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
Created fiber 0xffff48001150 for CC 104 globalID 104 session 0Thread 2 is working on CC 104 session 0 globalID 104 step 0
NvPclSettingsUpdate: Sending Updated Settings through PCL

NvPclSettingsApply: Applying last settings through PCLCC: RawReprocessEnable 0 


apply:+++++++++++++++++++++++assignAllBuffersFromStream is done ii 0 stream 0xffff50001350 and buffer 0xffff5000dc10%


apply:-----------------------
NvPclSettingsApply: Reading PCL settings
CC 104 session 0 completed step 0 in fiber 0xffff48001150
cc 104(4) session 0 runCount=3 runIspOut=0, latest ccId=0
CC 104 session 0 completed step 1 in fiber 0xffff48001150
NV AE and AfApply algorithms are active.
CC 104 session 0 completed step 2 in fiber 0xffff48001150
CC 104 session 0 completed step 3 in fiber 0xffff48001150
CC 104 session 0 completed step 4 in fiber 0xffff48001150
CC 104 session 0 completed step 5 in fiber 0xffff48001150
CC 104 session 0 completed step 6 in fiber 0xffff48001150
CC 104 session 0 processing step 7 in fiber 0xffff48001150
FiberScheduler: cc 104, session 0, fiber 0xffff48001150 in progress...

Thread 2 getting next capture
Thread 3 is waiting
Thread 2 is waiting
NvPclSettingsUpdate: Sending Updated Settings through PCL
NvPclSettingsApply: Applying last settings through PCL
apply:+++++++++++++++++++++++
apply:-----------------------
NvPclSettingsApply: Reading PCL settings
setupCC: inputBuffer (nil) or inStream (nil) and mode 0

setupCC: ccId 105 done

Created fiber 0xffff480012f0 for CC 105 globalID 105 session 0
Thread 4 is working on CC 105 session 0 globalID 105 step 0
CC: RawReprocessEnable 0 

assignAllBuffersFromStream is done ii 0 stream 0xffff50001350 and buffer 0xffff5000f1e0%

CC 105 session 0 completed step 0 in fiber 0xffff480012f0
cc 105(5) session 0 runCount=4 runIspOut=0, latest ccId=0
CC 105 session 0 completed step 1 in fiber 0xffff480012f0
NV AE and AfApply algorithms are active.
CC 105 session 0 completed step 2 in fiber 0xffff480012f0
CC 105 session 0 completed step 3 in fiber 0xffff480012f0
CC 105 session 0 completed step 4 in fiber 0xffff480012f0
CC 105 session 0 completed step 5 in fiber 0xffff480012f0
CC 105 session 0 completed step 6 in fiber 0xffff480012f0
CC 105 session 0 processing step 7 in fiber 0xffff480012f0
FiberScheduler: cc 105, session 0, fiber 0xffff480012f0 in progress...

Thread 4 getting next capture
Thread 5 is waiting
Thread 4 is waiting
Segmentation fault (core dumped)

device tree

/ {
	tegra-capture-vi {
		num-channels = <1>;
		status = "okay";
		ports {
			#address-cells = <1>;
			#size-cells = <0>;
			status = "okay";
			port@0 {
				reg = <0>;
				status = "okay";
				liimx728_vi_in0: endpoint {
					status = "okay";
					port-index = <0>;
					bus-width = <4>;
					remote-endpoint = <&liimx728_csi_out0>;
				};
			};
		};
	};

	host1x@13e00000 {
		nvcsi@15a00000 {
			num-channels = <1>;
			#address-cells = <1>;
			#size-cells = <0>;
			status = "okay";
			channel@0 {
				reg = <0>;
				status = "okay";
				ports {
					#address-cells = <1>;
					#size-cells = <0>;
					status = "okay";
					port@0 {
						reg = <0>;
						status = "okay";
						liimx728_csi_in0: endpoint@0 {
							status = "okay";
							port-index = <0>;
							bus-width = <4>;
							remote-endpoint = <&liimx728_imx728_out0>;
						};
					};
					port@1 {
						reg = <1>;
						status = "okay";
						liimx728_csi_out0: endpoint@1 {
							status = "okay";
							remote-endpoint = <&liimx728_vi_in0>;
						};
					};
				};
			};
		};
	};

	i2c@3180000 {	
		imx728@1a {
			status = "okay";
			compatible = "sony,imx728";
			reg = <0x1a>;
			
			devnode = "video0";

			physical_w = "8.100";
			physical_h = "4.572";

			sensor_model = "imx728";
			/*
			post_crop_frame_drop = "0";
			use_decibel_gain = "true";
			delayed_gain = "true";
			use_sensor_mode_id = "true";
			limit_analog_gain = "true";
			*/

			mode0 {
				status = "okay";
				mclk_khz = "25000";
				num_lanes = "4";
				tegra_sinterface = "serial_a";
				phy_mode = "DPHY";
				discontinuous_clk = "no";
				dpcm_enable = "false";
				cil_settletime = "0";
				dynamic_pixel_bit_depth = "12";
				csi_pixel_bit_depth = "12";
				mode_type = "bayer";
				pixel_phase = "rggb";

				active_w = "3856";
				active_h = "2202";
				readout_orientation = "0";
				line_length = "3856";
				inherent_gain = "1";
				/*mclk_multiplier = "2";*/
				pix_clk_hz = "305672832";
				serdes_pix_clk_hz = "400000000";

				gain_factor = "10";
				min_gain_val = "0"; /* 0dB */
				max_gain_val = "480"; /* 48dB */
				step_gain_val = "3"; /* 0.3 */
				default_gain = "0";
				min_hdr_ratio = "1";
				max_hdr_ratio = "1";
				framerate_factor = "1000000";
				min_framerate = "30000000"; /* 1.5 */
				max_framerate = "36000000"; /* 30 */
				step_framerate = "1";
				default_framerate= "36000000";
				exposure_factor = "1000000";
				min_exp_time = "34"; /* us */
				max_exp_time = "550385"; /* us */
				step_exp_time = "1";
				default_exp_time = "33334";/* us */
				embedded_metadata_height = "0";
			};

			ports {
				#address-cells = <1>;
				#size-cells = <0>;
				status = "okay";
				port@0 {
					reg = <0>;
					status = "okay";
					liimx728_imx728_out0: endpoint {
						status = "okay";
						port-index = <0>;
						bus-width = <4>;
						remote-endpoint = <&liimx728_csi_in0>;
						
					};
				};
			};
		};
	};
};

/ {

	tegra-camera-platform {
		status = "okay";
		compatible = "nvidia, tegra-camera-platform";

		num_csi_lanes = <4>;
		max_lane_speed = <1200000>;
		min_bits_per_pixel = <12>;
		vi_peak_byte_per_pixel = <2>;
		vi_bw_margin_pct = <25>;
		isp_peak_byte_per_pixel = <5>;
		isp_bw_margin_pct = <25>;

		modules {
			status = "okay";
			module0 {
				status = "okay";
				badge = "imx728_rear_liimx728";
				position = "rear";
				orientation = "0";
				drivernode0 {
					status = "okay";
					pcl_id = "v4l2_sensor";
					devname = "imx728 2-001a";
					proc-device-tree = "/proc/device-tree/i2c@3180000/imx728@1a";
				};
			};
		};
	};
};

Do you have any idea what I am doing wrong?

Could you boost the clocks to try.

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
echo 1 > /sys/kernel/debug/bpmp/debug/clk/emc/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
cat /sys/kernel/debug/bpmp/debug/clk/emc/max_rate | tee /sys/kernel/debug/bpmp/debug/clk/emc/rate

thank you, now it works
Does this mean that I need to increase the “serdes_pix_clk_hz” value or what value could be wrong in my device tree?

I also receive these two warnings, can I ignore them?

(gst-plugin-scanner:2346): GStreamer-WARNING **: 12:00:18.613: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/libgstchromaprint.so': /lib/aarch64-linux-gnu/libgomp.so.1: cannot allocate memory in static TLS block

(gst-plugin-scanner:2346): GStreamer-WARNING **: 12:00:18.804: Failed to load plugin '/usr/lib/aarch64-linux-gnu/gstreamer-1.0/libgstlibav.so': /lib/aarch64-linux-gnu/libgomp.so.1: cannot allocate memory in static TLS block

Yes, try 499999999

perfect, it works
thank you

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