HDMI DDC as I2C?

Hi,
I’m using the TX2 with the Astro carrier board from CTI, which exposes one I2C bus. I could really use another one–is it possible to repurpose the DDC lines from HDMI as an I2C bus? I’m running in headless mode so HDMI is never used.
Thanks,
MIke

Hi,

Do you mean you want to use the DDC line as a I2C bus? Which pin is that?

Yes, I’m actually trying it with the NVIDIA dev board first since CTI’s documentation is poor. From the manual it seems like it’s I2C4 or I2C6, I’m not sure which one.

Hi,

These 2 pins are special so it may need more than just pinmux control.

Below example is for i2c6 dts configuartion.

i2c@31b0000 {
        pinctrl-names = "default";
        pinctrl-0 = <&dpaux_default>;
    };

    host1x {
        dpaux@155c0000 {
            status = "okay";
            compatible = "nvidia,tegra186-dpaux-padctl";
            dpaux_default: pinmux@0 {
                dpaux_pins {
                    pins = "dpaux-0";
                    function = "i2c";
                };
            };
            /delete-property/ power-domains;
        };

dpaux0 {
        compatible = "nvidia,tegra186-dpaux-pinctrl";
        status = "okay";
    };

*Edit: this actually doesn’t quite work–it works if you have a monitor plugged into the HDMI while the board while it’s booting, but if there’s nothing plugged in then it won’t work. I’m guessing some driver is getting loaded on boot and configuring the DPAUX1 pins, and then the the OS boots it releases control of them because of the edit to the device tree, but if you don’t have something plugged into the HDMI, then that driver doesn’t get loaded and pins don’t get configured. So we still need to configure the DPAUX1 pins.

Thanks, I was able to get it to work, it seems like the pins were already set to an acceptable configuration, but the HDMI driver was getting in the way.
I tried I2C4 (enumerated as i2c3 in the device tree, or dp_aux_ch1_i2c: i2c@3190000).
Here’s what I did:

  1. Decompiled /boot/dtb/tegra186-quill-p3310-1000-c03-00-base.dtb into a .dts using the ‘dtc’ utility described here: https://docs.nvidia.com/jetson/l4t/index.html#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide%2Fadaptation_and_bringup_tx2.html%23wwpID0E0ZM0HA
  2. Find all the ‘nvdisplay’ nodes in the .dts file and set the status to ‘disabled’ so it won’t load the HDMI driver
  3. Recompile the .dts into a .dtb using the ‘dtc’ utility and put it into the /boot/dtb directory.
  4. Edit extlinux.conf to add the FDT line:
    LABEL primary
    MENU LABEL primary kernel
    LINUX /boot/Image
    INITRD /boot/initrd
    FDT /boot/dtb/modified.dtb
    APPEND ${cbootargs} quiet root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 console=ttyS0,115200n8 console=tty0 fbcon=map:0 net.ifnames=0 isolcpus=1-2
  5. Reboot