Want to use I2S3 s Audio on my custom carrier board

If you designed CVB then DT and driver needs to be supported based on codec you use

Thanks for the response.
what does CVB stand for ?

could you please elaborate more on this so that I can discuss this with my hardware team.
you mean in the device tree ( dtsi ) files we need to add entries for this codec controller?
Also make sure codec drivers are loaded as part of image/kernel build itself?

If Yes, please let know clear steps how to proceed with this.

It means you are using the custom carrier board.

You have to refer to the configuration in sound { node.
It depends on your codec design and we could not comment due to the new board design.

Please also share the full result of the following command on your board

# cat /sys/kernel/debug/aso/components

pls find the audio dtsi file, I have edited to enable sound card attached FYI. Please let us know, if you something we should do to make it work for I2S3. Thanks.

tegra194-audio-p2822-0000.txt (10.3 KB)

May I know what’s the codec design on your custom carrier board different from the devkit?

Please update the dtb to your board and share the reuslt of the following command.

# cat /sys/kernel/debug/aso/components

The path for the SOC is as below:

Just one more query. I have modified the device tree file inside the SOC folder. Is it ok to modify device tree ( I have changed the status = okay for I2S3, I2s4 ) files inside the Soc folder. Please confirm. Why I am asking this question is my image is not getting booted properly - I was doubting that might be due this issue. Thanks.

One more change I made in the dtsi file ( tegra194-audio-p2822-0000.dtsi) inside PLATFORM folder for audio for I2s3 enabling is as shown below:

tegra_sound_graph: sound_graph {
** compatible = “nvidia,tegra186-audio-graph-card”;**

** /***
** * Tegra audio graph card is based on uptream generic audio**
** * graph sound card. In future there is plan to use this**
** * as default sound card.**
** /*

** /* 03-Nov-2023 - Trident modified the below code - Enabling the audio graph card by changing the status okay*/**
** /* status = “disabled”; /*
** status = “okay”;**
** /* 03-Nov-2023 End of the Trident code modification block /*

** dais = /* ADMAIF (FE) Ports /*
** <&admaif1_port>, <&admaif2_port>, <&admaif3_port>,**
** <&admaif4_port>, <&admaif5_port>, <&admaif6_port>,**
** <&admaif7_port>, <&admaif8_port>, <&admaif9_port>,**
** <&admaif10_port>, <&admaif11_port>, <&admaif12_port>,**
** <&admaif13_port>, <&admaif14_port>, <&admaif15_port>,**
** <&admaif16_port>, <&admaif17_port>, <&admaif18_port>,**
** <&admaif19_port>, <&admaif20_port>,**

** /* ADSP (FE) Ports /*
** <&adsp_pcm1_port>, <&adsp_pcm2_port>,**
** <&adsp_compr1_port>, <&adsp_compr2_port>,**

It should be fine if you modify the base dtsi.

Please just check the serial console log for boot issue.

You could decompile the final dtb in use from your board (/boot/dtb/kernel_XXX.dtb) to check if the configuration has been applied correctly.

I assume this problem started appearing after I executed flash command to flash only my. DTB file passing it as parameter.

sudo ./flash.sh -d ./kernel/dtb/tegra194-p2888-0008-p2822-0000.dtb jetson-agx-xavier-industrial mmcblk0p1


I executed flash pre requisite command once before flashing ( which I was not doing before )

sudo ./tools/l4t_flash_prerequisites.sh

Any idea about this.

Since the board only is not coming up how can we retrieve the final /boot/dtb/kernel_XXX.dtb from my board?

We have used SGTL5000 codec amplifier for I2S interface from SOM module. By using this codec amplifier we are interfacing mic, headphone, line-in, line-out.

Please find the datasheet attached for this codec for more details,
SGTL5000.pdf (2.0 MB)

we have some queries like:

  1. Should we install some drivers to make the audio work?
  2. or just enabling the status to “okay” in device tree file, should be fine.
  3. or any other things to be done apart from this.


Do you mean that your board can’t boot up now?

The corresponding node should be enabled with the necessary configurations in device tree.
We don’t have this module to be verified locally and give you the detailed steps.
It seems you should ask for the porting guide from your vendor (NXP!?)

As the comment in another post, I think the board is able to boot up again.

Yes. Boot is up and booting properly after I loaded old image. Now I took old code backup and started making changes for my I2S3/4 audio to make it work.

I am making changes with respect codec SGTL5000 added on our customized carrier board.

Board is up now, will put the retrieved dts file soon.

I have made some changes in my audio related .dtsi file as per the documentation in the nvidia website for Audio.

I have one query related to the same as shown below:

I need to add widgets routing for me codec card installed on my carrier board, but I have one widget details already in my SOUND structure , how to go about this.

By default we already had "CVB-RT"related in the existing code.
I have newly added widgets for my SGTL5000 codec “H40-SGTL”.

Is it fine to add two different set of widgets in one sound structure?

tegra_sound: sound {
status = “okay”;
compatible = “nvidia,tegra186-ape”;
nvidia-audio-card,name = “NVIDIA Jetson AGX Xavier APE”;
clocks = <&bpmp_clks TEGRA194_CLK_PLLA>,
<&bpmp_clks TEGRA194_CLK_PLLA_OUT0>,
<&bpmp_clks TEGRA194_CLK_AUD_MCLK>;
clock-names = “pll_a”, “pll_a_out0”, “extern1”;
assigned-clocks = <&bpmp_clks TEGRA194_CLK_AUD_MCLK>;
assigned-clock-parents = <&bpmp_clks TEGRA194_CLK_PLLA_OUT0>;

  nvidia-audio-card,widgets =
  	"Headphone",	"CVB-RT Headphone Jack",
  	"Microphone",	"CVB-RT Mic Jack",
  	"Speaker",	"CVB-RT Int Spk",
  	"Microphone",	"CVB-RT Int Mic";

  nvidia-audio-card,routing =
  	"CVB-RT Headphone Jack",     "CVB-RT HPO L Playback",
  	"CVB-RT Headphone Jack",     "CVB-RT HPO R Playback",
  	"CVB-RT IN1P",               "CVB-RT Mic Jack",
  	"CVB-RT IN2P",               "CVB-RT Mic Jack",
  	"CVB-RT Int Spk",            "CVB-RT SPO Playback",
  	"CVB-RT DMIC L1",            "CVB-RT Int Mic",
  	"CVB-RT DMIC L2",            "CVB-RT Int Mic",
  	"CVB-RT DMIC R1",            "CVB-RT Int Mic",
  	"CVB-RT DMIC R2",            "CVB-RT Int Mic";

  nvidia-audio-card,mclk-fs = <256>;
  //Nagesh - Trident - 10-Nov - Adding nvidia-Audio card - widgets, routing
  nvidia-audio-card,widgets =
      "Headphone",    "H40-SGTL Headphone",
          "Microphone",   "H40-SGTL Mic",
      "Line",         "H40-SGTL Line In",
      "Line",         "H40-SGTL Line Out";

     nvidia-audio-card,routing =
     "H40-SGTL Headphone",   "H40-SGTL HP_OUT",
     "H40-SGTL MIC_IN",      "H40-SGTL Mic",
     "H40-SGTL ADC",         "H40-SGTL Mic Bias",
     "H40-SGTL LINE_IN",     "H40-SGTL Line In",
     "H40-SGTL Line Out",    "H40-SGTL LINE_OUT";

	       /* Trident end changes */


We have mailed NXP vendor to provide porting guide for codec SGTL

I am getting some parse tree errors( as shown below) after I updated the audio dtsi file for SGTL codec driver as per the documentation in the Nvidia website. I am attaching the dtsi for reference. Please let me know is there any thing wrong in this. I suspect it is not able to parse the node “stgl5000”.
tegra194-audio-p2822-0000.txt (11.2 KB)

home/trident/Downloads/r35_4_1/Linux_for_Tegra/source/public/kernel/kernel-5.10/arch/arm64/boot/dts/…/…/…/…/…/…/hardware/nvidia/platform/t19x/galen-industrial/kernel-dts/…/…/galen/kernel-dts/common/tegra194-audio-p2822-0000.dtsi:66.28-77.17: ERROR (phandle_references): /i2s@2901300/sgtl5000@0a: Reference to non-existent node or label “vdd_3v3”

ERROR: Input tree has errors, aborting (use -f to force output)
make[2]: *** [/home/trident/Downloads/r35_4_1/Linux_for_Tegra/source/public/kernel/kernel-5.10/arch/arm64/boot/dts/Makefile:80: arch/arm64/boot/dts/ddot/ddot/ddot/ddot/ddot/ddot/hardware/nvidia/platform/t19x/galen-industrial/kernel-dts/tegra194-p2888-0008-e3366-1199.dtb] Error 2
make[2]: *** Waiting for unfinished jobs…
DTC arch/arm64/boot/dts/ddot/ddot/ddot/ddot/ddot/ddot/hardware/nvidia/platform/t23x/p3768/kernel-dts/tegra234-p3767-0004-p3768-0000-a0.dtb
DTC arch/arm64/boot/dts/ddot/ddot/ddot/ddot/ddot/ddot/hardware/nvidia/platform/t19x/galen-industrial/kernel-dts/tegra194-p2888-0008-p2822-0000.dtb
/home/trident/Downloads/r35_4_1/Linux_for_Tegra/source/public/kernel/kernel-5.10/arch/arm64/boot/dts/…/…/…/…/…/…/hardware/nvidia/platform/t19x/galen-industrial/kernel-dts/…/…/galen/kernel-dts/common/tegra194-audio-p2822-0000.dtsi:66.28-77.17: ERROR (phandle_references): /i2s@2901300/sgtl5000@0a: Reference to non-existent node or label “sgtl5000_mclk”

/home/trident/Downloads/r35_4_1/Linux_for_Tegra/source/public/kernel/kernel-5.10/arch/arm64/boot/dts/…/…/…/…/…/…/hardware/nvidia/platform/t19x/galen-industrial/kernel-dts/…/…/galen/kernel-dts/common/tegra194-audio-p2822-0000.dtsi:66.28-77.17: ERROR (phandle_references): /i2s@2901300/sgtl5000@0a: Reference to non-existent node or label “vdd_3v3”

/home/trident/Downloads/r35_4_1/Linux_for_Tegra/source/public/kernel/kernel-5.10/arch/arm64/boot/dts/…/…/…/…/…/…/hardware/nvidia/platform/t19x/galen-industrial/kernel-dts/…/…/galen/kernel-dts/common/tegra194-audio-p2822-0000.dtsi:66.28-77.17: ERROR (phandle_references): /i2s@2901300/sgtl5000@0a: Reference to non-existent node or label “vdd_3v3”

ERROR: Input tree has errors, aborting (use -f to force output)

Do you hit these errors during compiling the dtb?

Do you add this dts by your self?

I would suggest you starting from a clean build w/o any modification and port them one-by-one to debug how you get build issue.

yes. If you see the error log from the build process, you can notice, this error is from the “tegra194-audio-p2822-0000.dtsi” file.