Clarification on I2C and CSI Communication for Cameras supporting NVIDIA ISP vendors on the Jetson AGX Orin

Hello community,

I’m currently working with the MIPI CSI camera, e-CAM80_CUOAGX on the Jetson AGX Orin and am trying to better understand the interaction between I2C and CSI in the context of this camera.

From my current understanding:

  1. I2C is primarily used for sensor control tasks (like setting exposure, gain, white balance, etc.), and these settings are passed through the I2C subsystem from the device driver.
  2. CSI is responsible for high-speed data transfer of the actual video/image frames to the host processor.

I’ve been logging V4L2 IOCTL calls related to /dev/video0, but I didn’t observe any explicit I2C communication during my tests (other than CSI-related operations like frame data capture). However, I understand that control commands (e.g., for exposure, gain) must still go through I2C at some level.

Here are my specific questions:

  1. How exactly does the camera control (e.g., exposure, gain) communicate via I2C when using the V4L2 framework? Are these I2C commands triggered behind the scenes through V4L2 IOCTLs?
  2. Is it correct to assume that while CSI handles the data stream, I2C is still used for any sensor control-related operations? If so, how can I log or observe these I2C transactions?
  3. When using tools like Argus, how are the I2C commands issued to the camera sensor? Is there any specific device or node that I should be monitoring to capture these transactions?
  4. During the runtime of an argus sample binary, I never really notice an open of the file /dev/i2c-{bus_number}. This seemed weird at first, but I realised that the User-Space is barred from directly interacting with this camera via the I2C because the slave-address is reserved by the Kernel Driver (indicated by UU in the i2cdetect command). So, how and what exactly is I2C being used in this context is what I’m curious about.

I can see that there are register writes and reads done from the kernel logging of ftrace, but I am not sure where is I2C exactly used in the argus camera capture.

I want to ensure I’m correctly logging all control-related I2C traffic to better understand the interaction between the driver, V4L2, and the camera sensor.

Any insights or guidance on how I can further investigate the I2C communication while using the V4L2 framework would be greatly appreciated!

Thank you in advance for your support!

Please check this document for the detail.

https://docs.nvidia.com/jetson/archives/r36.3/DeveloperGuide/SD/CameraDevelopment/CameraSoftwareDevelopmentSolution.html

Hello ShaneCCC,

I have referred to the documentation you have linked, but it doesn’t mention in detail how the communication is flowing through, for the runtime of an argus capture. What I would like to know is where is the distinction made for the CSI and I2C, and how are the I2C calls even made if the application doesn’t even open any i2c bus? Does it not use the ioctl() system-call to do the tasks, and rather use other system-calls such as the read() and write()? I don’t see the latter making a lot of sense, since they don’t allow for specific register writes, and are generic. But, since I couldn’t intercept any calls of ioctl() relating to the I2C, I’m not sure about anything as of now.

Please look into the sensor kernel driver that tell how the i2c communicate with the sensor.
Sensor driver configurate sensor via I2C command also provide IOCTL for user space to manual configuration.

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