Error i2c read probe

Hello,

( Please, can someone answer these questions bold type written ? )

I am trying to make camera d457 work with orin nano (manually flashed with JP6). Realsense mipi drivers are adapted to orin agx. First i’ve tried, is modify this:

-    cp $SRCS/nvidia-oot/device-tree/platform/generic-dts/dtbs/tegra234-p3737-0000+p3701-0000-nv.dtb $TEGRA_KERNEL_OUT/rootfs/boot/dtb/
+    cp $SRCS/nvidia-oot/device-tree/platform/generic-dts/dtbs/tegra234-p3768-0000+p3767-0005-nv.dtb $TEGRA_KERNEL_OUT/rootfs/boot/dtb/

More info here

Why did I use p3767-0000+p3767-0005 ? . Because:

vmasip@nano:~$ cat /sys/firmware/devicetree/base/compatible
nvidia,p3768-0000+p3767-0005nvidia,p3767-0005nvidia,tegra234

(Which is rare by the way because I’ve got a second Orin Nano flashed with sdk manager JP5 which output is:
nvidia,p3768-0000+p3767-0003nvidia,p3768-0000+p3767-0005nvidia,p3767-0003nvidia,p3767-0005nvidia,tegra234nvidia,tegra23x).

So, am I choosing the right orin nano dtb?

I have no idea how to adapt realsense mipi driver to orin nano. I don’t know where to start from. I’ve modified these lines too:

diff --git a/hardware/realsense/tegra234-camera-d4xx-overlay.dts b/hardware/realsense/tegra234-camera-d4xx-overlay.dts
index 42b2cef..aee4eff 100644
--- a/hardware/realsense/tegra234-camera-d4xx-overlay.dts
+++ b/hardware/realsense/tegra234-camera-d4xx-overlay.dts
@@ -6,7 +6,7 @@
 
 #include <dt-bindings/clock/tegra234-clock.h>
 #include <dt-bindings/gpio/tegra234-gpio.h>
-#include <dt-bindings/tegra234-p3737-0000+p3701-0000.h>
+#include <dt-bindings/tegra234-p3767-0000-common.h>

is this right?

What’s the result of finishing all compilation / installation process of dtb&kernel&driver of real sense mipi repository with my adaptation to orin nano?

sudo dmesg | grep i2c
[sudo] password for vmasip: 
[    0.253464] i2c_dev: i2c /dev entries driver
[    4.102931] tegra-i2c 3160000.i2c: Adding to iommu group 1
[    4.106675] tegra-i2c 3180000.i2c: Adding to iommu group 1
[    4.109401] tegra-i2c 31b0000.i2c: Adding to iommu group 1
[    4.114809] tegra-i2c c240000.i2c: Adding to iommu group 1
[    4.119839] i2c 1-0025: Fixing up cyclic dependency with 3520000.padctl
[    4.120643] tegra-i2c c250000.i2c: Adding to iommu group 1
[    4.126627] i2c i2c-2: Added multiplexed i2c bus 9
[    4.128382] i2c i2c-2: Added multiplexed i2c bus 10
[    4.128402] i2c-mux-gpio bus@0:cam_i2cmux: 2 port mux on 3180000.i2c adapter
**[   14.229907] imx219 9-0010: imx219_board_setup: error during i2c read probe (-121)**
**[   14.258674] imx219 10-0010: imx219_board_setup: error during i2c read probe (-121)**

Are these two last lines an error by default? To find out , I’ve checked my JP5 Orin Nano, and these two lines appear too. Is this normal behaviour?

[    4.592960] i2c /dev entries driver
[    4.596699] tegra-i2c 3160000.i2c: Adding to iommu group 2
[    4.602505] tegra-i2c c240000.i2c: Adding to iommu group 2
[    4.608205] tegra-i2c 3180000.i2c: Adding to iommu group 2
[    4.613908] tegra-i2c 3190000.i2c: Adding to iommu group 2
[    4.619594] tegra-i2c 31b0000.i2c: Adding to iommu group 2
[    4.625277] tegra-i2c 31c0000.i2c: Adding to iommu group 2
[    4.630960] tegra-i2c c250000.i2c: Adding to iommu group 2
[    4.636650] tegra-i2c 31e0000.i2c: Adding to iommu group 2
[    8.781618] i2c i2c-2: Added multiplexed i2c bus 9
[    8.787310] i2c i2c-2: Added multiplexed i2c bus 10
[    8.792334] i2c-mux-gpio cam_i2cmux: 2 port mux on 3180000.i2c adapter
**[   15.404324] imx219 9-0010: imx219_board_setup: error during i2c read probe (-121)**
**[   15.471386] imx219 10-0010: imx219_board_setup: error during i2c read probe (-121)**

The default device tree include the imx219 and the status is “okay” but your Orin Nano didn’t connect the imx219 that’s why the i2c error message shows up.
You can check below document to the sensor driver implementation.

https://docs.nvidia.com/jetson/archives/r35.6.0/DeveloperGuide/SD/CameraDevelopment/SensorSoftwareDriverProgramming.html

So, when you say is not connecting imx219 sensor, what are you meaning? That it’s a normal message because it haven’t found an imx219 sensor connected? Or do you mean that that something is not “loaded” properly?

I mean, does every orin nano user has this message when they don’t connect anything?

Devicetree, overlays… it’s a huge field. I don’t know even where to start looking at to adapt dts overlay of realsense mipi driver.

Yes, it’s normal message if does not connect the imx219.
However, you can remove the device tree of imx219 if have concern about this message.

No, no concerns. I wanted to know if that was part of the error. Reading the documentation, my conclusion is: dts files are not easy . I’ve wondered what can change from one jetson to other one.

Is the port mapping and the lines of csi switch?

Could you give me step hints in order to adapt from orin agx to orin nano?

Please review the programing guide to know the detail.

Thanks

https://docs.nvidia.com/jetson/archives/r36.3/DeveloperGuide/SD/CameraDevelopment/SensorSoftwareDriverProgramming.html?highlight=port%20index#sensor-software-driver-programming

The capture I’ve pasted, comes from that website. So I’ve read it. After checking all the points, this port binding issue is the one I guess that need to be modified for porting this driver to orin nano. Is that it? PLEASE, any hint from this point? I don’t even found the diagram for orin nano. And csi switch what should I do with it?

The i2c problem doesn’t matter with port binding.
For the port binding you can reference to imx21/imx477 for the configuration.

Thanks

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