Some problems of tx2nx's I2S number

I want to use the I2S0 and I2S1 of the module. I am using jp4.6.2
My hardware is connected to module I2S1.
1.sudo /opt/nvidia/jetson-io/jetson-io.py and turn on aud_mclk i2s1.
2.sudo amixer -c tegrasndt186ref cset name="I2S1 Mux" "ADMAIF1"
3.aplay -D hw:1,0 a.wav But no voice.
4.sudo amixer -c tegrasndt186ref cset name="I2S3 Mux" "ADMAIF3"
5.aplay -D hw:1,2 a.wav Works well.

I see the pins descriptor on the excel.
I use module I2S1 that means it’s soc I2S3.
I sudo dtc -I fs -O dts -o extracted_proc.dts /proc/device-tree and see the dts

hdr40-pin40 {
          nvidia,lpdr = <0x0>;
          nvidia,enable-input = <0x0>;
          nvidia,tristate = <0x0>;
          nvidia,pull = <0x0>;
          nvidia,function = "i2s1";
          nvidia,pins = "dap1_dout_pj1";
  };

It’s I2S1 but the nvidia,pins = "dap1_dout_pj1". dap1_dout_pj1 is module I2S0

I don’t know the relationship of module i2s and soc i2s and dts name.

Suppose you can just check the device tree pin name to map to correct i2s bus.

But I don’t know how to match the module i2s and soc i2s and dts i2s.
I am using module i2s1 but moule i2s0 not work.
Can you tell me what the module i2s0 match to dts pin name?

Find the device tree pin name and map to below and minus 1 to get the i2s bus. i2s1 is HW naming and start from 1 and software naming from 0 so minus 1 get the software bus name.

Like below is the i2s@0 for this pin.

nvidia,function = “i2s1”

It’s wrong. My codec connect to moudle i2s1, and nvidia,function = “i2s1”. It works well. So I ask you module i2s@0 vs nvidia,function = “i2s?” and what’s the dts descriptor pin? So confuse~_~

Looks like i2s didn’t like others have aliases bus name.
For that I would suggest to confirm by the memory address like i2s@2901200 for i2s1

        aliases {
                sdhci0 = "/sdhci@3400000";
                sdhci1 = "/sdhci@3420000";
                sdhci2 = "/sdhci@3440000";
                sdhci3 = "/sdhci@3460000";
                i2c0 = "/i2c@3160000";
                i2c1 = "/i2c@c240000";
                i2c2 = "/i2c@3180000";
                i2c3 = "/i2c@3190000";
                i2c4 = "/bpmp_i2c";
                i2c5 = "/i2c@31b0000";
                i2c6 = "/i2c@31c0000";
                i2c7 = "/i2c@c250000";
                i2c8 = "/i2c@31e0000";
                spi0 = "/spi@3210000";
                spi1 = "/spi@c260000";
                spi2 = "/spi@3230000";
                spi3 = "/spi@3240000";
                spi4 = "/aon_spi@c260000";
                spi6 = "/spi@3270000";
                tegra-camera-rtcpu = "/rtcpu@b000000";
                serial0 = "/serial@3100000";
                serial1 = "/serial@3110000";
                serial2 = "/serial@c280000";
                serial3 = "/serial@3130000";
                serial4 = "/serial@3140000";
                serial5 = "/serial@3150000";
                serial6 = "/serial@c290000";
                rtc1 = "/rtc@c2a0000";
                rtc0 = "/bpmp_i2c/spmic@3c";
        };

```.

                    i2s@2901000 {
                            compatible = "nvidia,tegra186-i2s";
                            reg = <0x0 0x2901000 0x0 0x100>;
                            nvidia,ahub-i2s-id = <0x0>;
                            clocks = <0x10 0x4f 0x10 0xf6 0x10 0x269 0x10 0xf7 0x10 0x269>;
                            clock-names = "i2s1", "pll_a_out0", "ext_audio_sync", "audio_sync", "clk_sync_input";
                            pinctrl-names = "dap_active", "dap_inactive";
                            pinctrl-0 = <0x60>;
                            pinctrl-1;
                            fsync-width = <0x1f>;
                            status = "okay";
                            nvidia,is-pinctrl = <0x1>;
                            linux,phandle = <0xbe>;
                            phandle = <0xbe>;
                    };

                    i2s@2901100 {
                            compatible = "nvidia,tegra186-i2s";
                            reg = <0x0 0x2901100 0x0 0x100>;
                            nvidia,ahub-i2s-id = <0x1>;
                            clocks = <0x10 0x2a 0x10 0xf6 0x10 0x26a 0x10 0xf8 0x10 0x26a>;
                            clock-names = "i2s2", "pll_a_out0", "ext_audio_sync", "audio_sync", "clk_sync_input";
                            pinctrl-names = "dap_active", "dap_inactive";
                            pinctrl-0 = <0x61>;
                            pinctrl-1;
                            fsync-width = <0x0>;
                            status = "okay";
                            nvidia,is-pinctrl = <0x1>;
                            linux,phandle = <0xc0>;
                            phandle = <0xc0>;
                    };

                    i2s@2901200 {
                            compatible = "nvidia,tegra186-i2s";
                            reg = <0x0 0x2901200 0x0 0x100>;
                            nvidia,ahub-i2s-id = <0x2>;
                            clocks = <0x10 0x2b 0x10 0xf6 0x10 0x26b 0x10 0xf9 0x10 0x26b>;
                            clock-names = "i2s3", "pll_a_out0", "ext_audio_sync", "audio_sync", "clk_sync_input";
                            pinctrl-names = "dap_active", "dap_inactive";
                            pinctrl-0 = <0x62>;
                            pinctrl-1;
                            fsync-width = <0x1f>;
                            status = "okay";
                            nvidia,is-pinctrl = <0x1>;
                            linux,phandle = <0xc2>;
                            phandle = <0xc2>;
                    };

                    i2s@2901300 {
                            compatible = "nvidia,tegra186-i2s";
                            reg = <0x0 0x2901300 0x0 0x100>;
                            nvidia,ahub-i2s-id = <0x3>;
                            clocks = <0x10 0x54 0x10 0xf6 0x10 0x26c 0x10 0xfa 0x10 0x26c>;
                            clock-names = "i2s4", "pll_a_out0", "ext_audio_sync", "audio_sync", "clk_sync_input";
                            pinctrl-names = "dap_active", "dap_inactive";
                            pinctrl-0;
                            pinctrl-1;
                            fsync-width = <0x1f>;
                            status = "okay";
                            linux,phandle = <0xc4>;
                            phandle = <0xc4>;
                    };

aliases is the same of you.
But i2s@ is different.

i2s@2901000 {
        compatible = "nvidia,tegra210-i2s";
        reg = <0x0 0x2901000 0x0 0x100>;
        nvidia,ahub-i2s-id = <0x0>;
        clocks = <0x10 0x4f 0x10 0xf6 0x10 0x269 0x10 0xf7 0x10 0x269>;
        clock-names = "i2s", "i2s_clk_parent", "ext_audio_sync", "audio_sync", "clk_sync_input";
        assigned-clocks = <0x10 0x4f>;
        assigned-clock-parents = <0x10 0xf6>;
        assigned-clock-rates = <0x177000>;
        pinctrl-names = "dap_active", "dap_inactive";
        pinctrl-0;
        pinctrl-1;
        fsync-width = <0x1f>;
        status = "okay";
        linux,phandle = <0x88>;
        phandle = <0x88>;
};
i2s@2901100 {
        compatible = "nvidia,tegra210-i2s";
        reg = <0x0 0x2901100 0x0 0x100>;
        nvidia,ahub-i2s-id = <0x1>;
        clocks = <0x10 0x2a 0x10 0xf6 0x10 0x26a 0x10 0xf8 0x10 0x26a>;
        clock-names = "i2s", "i2s_clk_parent", "ext_audio_sync", "audio_sync", "clk_sync_input";
        assigned-clocks = <0x10 0x2a>;
        assigned-clock-parents = <0x10 0xf6>;
        assigned-clock-rates = <0x177000>;
        pinctrl-names = "dap_active", "dap_inactive";
        pinctrl-0;
        pinctrl-1;
        fsync-width = <0x0>;
        status = "okay";
        linux,phandle = <0x8a>;
        phandle = <0x8a>;
};
i2s@2901200 {
        compatible = "nvidia,tegra210-i2s";
        reg = <0x0 0x2901200 0x0 0x100>;
        nvidia,ahub-i2s-id = <0x2>;
        clocks = <0x10 0x2b 0x10 0xf6 0x10 0x26b 0x10 0xf9 0x10 0x26b>;
        clock-names = "i2s", "i2s_clk_parent", "ext_audio_sync", "audio_sync", "clk_sync_input";
        assigned-clocks = <0x10 0x2b>;
        assigned-clock-parents = <0x10 0xf6>;
        assigned-clock-rates = <0x177000>;
        pinctrl-names = "dap_active", "dap_inactive";
        pinctrl-0;
        pinctrl-1;
        fsync-width = <0x1f>;
        status = "okay";
        linux,phandle = <0x8c>;
        phandle = <0x8c>;
};

i2s@2901300 {
        compatible = "nvidia,tegra210-i2s";
        reg = <0x0 0x2901300 0x0 0x100>;
        nvidia,ahub-i2s-id = <0x3>;
        clocks = <0x10 0x54 0x10 0xf6 0x10 0x26c 0x10 0xfa 0x10 0x26c>;
        clock-names = "i2s", "i2s_clk_parent", "ext_audio_sync", "audio_sync", "clk_sync_input";
        assigned-clocks = <0x10 0x54>;
        assigned-clock-parents = <0x10 0xf6>;
        assigned-clock-rates = <0x177000>;
        pinctrl-names = "dap_active", "dap_inactive";
        pinctrl-0;
        pinctrl-1;
        fsync-width = <0x1f>;
        status = "okay";
        linux,phandle = <0x8e>;
        phandle = <0x8e>;
};

What deos it mean?

Have a check the TRM to know the address map.

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