Enable PCA9546 I2C-MUX

Hi, We are bringing up a carrier board for Xavier NX. We have a PCA9546 I2C MUX on the board to support 4 cameras. Following device tree examples in the L4T source code and others online, we still cannot make it work. We have the following questions:

  1. The active low reset pin on the PCA9546 needs to be high to enable the switch/mux functionality. However the reset function is not clear on. How it should be implemented? We have tried using “reset-gpio”, “mux-gpio”, and “i2c-mux-idle-disconnect” properties. But none of them works.
  2. De we need a regulator, “vcc-supply”, for this pca9546 to function?

Thank you in advance and your help is greatly appreciated.

P.S. I am attaching the two .dtsi files for your reference. Since we use IMX219 sensors for the testing, we modified the dtsi files for IMX219 in t19x/jakku directory.
tegra194-camera-jakku-lmpt-imx219.dtsi (3.3 KB)
tegra194-camera-lmpt-imx219.dtsi (50.0 KB)

hello stuart.xu,

please see-also Topic 192486 for using Camera I2C Mux for reference, thanks

We read these topics already and we followed multiple examples including the one you recommended. We are just not sure where the problems are. Could you have a look at our dtsi files and provide some help to my specific questions?

One update, we put the “vcc-supply = <&p3509_vdd__3v3_cvb>;” in the mux node. The system starts to probe the devices connected to the mux. But we still can not get the camera work.

In addition, we disabled, in one of our .dtsi file, the “cam_i2cmux” which originally supports the imx219 on the devkit board. Based on the developer’s guide we should disable it in plugin_manager. We could not find the file. What is the best way to remove or unregister the cam_i2cmux?
tegra194-camera-lmpt-imx219.dtsi (50.0 KB)
tegra194-camera-jakku-lmpt-imx219.dtsi (3.5 KB)

hello stuart.xu,

please check Device Registration chapter for the approach to disable plugin-manager.
could you please also share the initial kernel logs for camera device registration,

We checked the document. I just cannot find anything related to the cam_i2cmux. For now the cam_i2cmux is still in /sys/firmware/devicetree/base/cam_i2cmux. its status is disabled. I think this is a standard device that Nvidia supports. If you know how to de-register it, please let us know.

We also made some progress today. The i2c_mux works now and we can see three of four cameras. I upload the kernel log for your reference.
t (77.6 KB)


hello stuart.xu,

there’s i2c no ack failure with 33-0010, for example,

[    1.939129] imx219 30-0010: tegracam sensor driver:imx219_v2.0.6
[    1.965168] imx219 31-0010: tegracam sensor driver:imx219_v2.0.6
[    1.991109] imx219 32-0010: tegracam sensor driver:imx219_v2.0.6
[    2.016818] imx219 33-0010: tegracam sensor driver:imx219_v2.0.6
[    2.040456] tegra-i2c 3180000.i2c: no acknowledge from address 0x10
[    2.040631] imx219 33-0010: imx219_board_setup: error during i2c read probe (-121)
[    2.040973] imx219 33-0010: board setup failed
[    2.041135] imx219: probe of 33-0010 failed with error -121

this failure usually due to regulator settings, please review your device tree property and check you’ve assign correct settings.

We finally found that the camera select GPIO pin was set with an incorrect value. Now we can see the four cameras.

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