Nano with audio codec(NAU88C22) with MIC can't record any sound?

Hi NV_Team,

We design an audio codec(nau88c22) with speaker and mono mic on Nano, now speak works fine, but the mic doesn’t work. Can you give some advice about the audio routing and debug of mic for Nano?


tegra_sound: sound {
	status = "okay";
	compatible = "nvidia,tegra-audio-t210ref-mobile-rt565x";
	nvidia,model = "tegra-snd-t210ref-mobile-nau8822";

	clocks = <&tegra_car TEGRA210_CLK_PLL_A>,
		 <&tegra_car TEGRA210_CLK_PLL_A_OUT0>,
		 <&tegra_car TEGRA210_CLK_EXTERN1>;
	clock-names = "pll_a", "pll_a_out0", "extern1";
	assigned-clocks = <&tegra_car TEGRA210_CLK_EXTERN1>;
	assigned-clock-parents = <&tegra_car TEGRA210_CLK_PLL_A_OUT0>;

	nvidia,num-codec-link = <4>;

	nvidia,audio-routing =
		"x Headphone", "x LHP",
		"x Headphone", "x RHP",  
		"x Int Spk",   "x LSPK",  
		"x Int Spk",  "x RSPK",  
		
		"y Headphone",	"y OUT",
			"x LMICN",	"x Mic",
					"x LMICP",	"x Mic",
					"x RMICN",	"x Mic",
					"x RMICP",	"x Mic",
					"x Capture",	"x Mic";

	nvidia,xbar = <&tegra_axbar>;
	mclk-fs = <256>;

	hdr40_snd_link_i2s: i2s_dai_link1: nvidia,dai-link-1 {
		link-name = "nau8822-playback";
		cpu-dai = <&tegra_i2s4>;
		codec-dai = <&nau8822_a00>;
		cpu-dai-name = "I2S4";
		codec-dai-name = "nau8822-hifi";
		format = "i2s";
		bitclock-slave;
		frame-slave;
		bitclock-noninversion;
		frame-noninversion;
		bit-format = "s16_le";
		srate = <48000>;
		num-channel = <2>;
		ignore_suspend;
		name-prefix = "x";
		status = "okay";
	};
	nvidia,dai-link-2 {
		link-name = "spdif-dit-1";
		cpu-dai = <&tegra_i2s3>;
		codec-dai = <&spdif_dit1>;
		cpu-dai-name = "I2S3";
		codec-dai-name = "dit-hifi";
		format = "i2s";
		bitclock-slave;
		frame-slave;
		bitclock-noninversion;
		frame-noninversion;
		bit-format = "s16_le";
		srate = <48000>;
		num-channel = <2>;
		ignore_suspend;
		name-prefix = "y";
		status = "okay";
	};
	nvidia,dai-link-3 {
		link-name = "spdif-dit-2";
		cpu-dai = <&tegra_dmic1>;
		codec-dai = <&spdif_dit2>;
		cpu-dai-name = "DMIC1";
		codec-dai-name = "dit-hifi";
		format = "i2s";
		bit-format = "s16_le";
		srate = <48000>;
		ignore_suspend;
		num-channel = <2>;
		name-prefix = "a";
		status = "okay";
	};
	nvidia,dai-link-4 {
		link-name = "spdif-dit-3";
		cpu-dai = <&tegra_dmic2>;
		codec-dai = <&spdif_dit3>;
		cpu-dai-name = "DMIC2";
		codec-dai-name = "dit-hifi";
		format = "i2s";
		bit-format = "s16_le";
		srate = <48000>;
		ignore_suspend;
		num-channel = <2>;
		name-prefix = "b";
		status = "okay";
	};
};
root@nano:/sys/kernel/debug/asoc/tegra-snd-t210ref-mobile-nau8822/codec:nau8822.2-001a/dapm# ls -l
-r--r--r-- 1 root root 0 1月   1  1970  bias_level
-r--r--r-- 1 root root 0 1月   1  1970 'x AUX1 Out'
-r--r--r-- 1 root root 0 1月   1  1970 'x AUX1 Output Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x AUX2 Out'
-r--r--r-- 1 root root 0 1月   1  1970 'x AUX2 Output Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x AUXOUT1'
-r--r--r-- 1 root root 0 1月   1  1970 'x AUXOUT2'
-r--r--r-- 1 root root 0 1月   1  1970 'x Capture'
-r--r--r-- 1 root root 0 1月   1  1970 'x L2'
-r--r--r-- 1 root root 0 1月   1  1970 'x LAUX'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left ADC'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left Boost Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left Capture PGA'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left DAC'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left Headphone Out'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left Input Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left Output Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x Left Speaker Out'
-r--r--r-- 1 root root 0 1月   1  1970 'x LHP'
-r--r--r-- 1 root root 0 1月   1  1970 'x LMICN'
-r--r--r-- 1 root root 0 1月   1  1970 'x LMICP'
-r--r--r-- 1 root root 0 1月   1  1970 'x LSPK'
-r--r--r-- 1 root root 0 1月   1  1970 'x Mic Bias'
-r--r--r-- 1 root root 0 1月   1  1970 'x Playback'
-r--r--r-- 1 root root 0 1月   1  1970 'x PLL'
-r--r--r-- 1 root root 0 1月   1  1970 'x R2'
-r--r--r-- 1 root root 0 1月   1  1970 'x RAUX'
-r--r--r-- 1 root root 0 1月   1  1970 'x RHP'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right ADC'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right Boost Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right Capture PGA'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right DAC'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right Headphone Out'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right Input Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right Output Mixer'
-r--r--r-- 1 root root 0 1月   1  1970 'x Right Speaker Out'
-r--r--r-- 1 root root 0 1月   1  1970 'x RMICN'
-r--r--r-- 1 root root 0 1月   1  1970 'x RMICP'
-r--r--r-- 1 root root 0 1月   1  1970 'x RSPK'

nvidia@nano:~$ amixer -c tegrasndt210ref | grep "'x "
Simple mixer control 'x ADC',0
Simple mixer control 'x ADC 128x Oversampling',0
Simple mixer control 'x ADC Companding',0
Simple mixer control 'x ADC Inversion',0
Simple mixer control 'x ALC Capture Attack',0
Simple mixer control 'x ALC Capture Decay',0
Simple mixer control 'x ALC Capture Hold',0
Simple mixer control 'x ALC Capture Max Gain',0
Simple mixer control 'x ALC Capture Min Gain',0
Simple mixer control 'x ALC Capture Mode',0
Simple mixer control 'x ALC Capture Noise Gate',0
Simple mixer control 'x ALC Capture Noise Gate Threshold',0
Simple mixer control 'x ALC Capture Target',0
Simple mixer control 'x ALC Enable',0
Simple mixer control 'x AUX1 Output Mixer LDAC',0
Simple mixer control 'x AUX1 Output Mixer LMIX',0
Simple mixer control 'x AUX1 Output Mixer RDAC',0
Simple mixer control 'x AUX1 Output Mixer RINMIX',0
Simple mixer control 'x AUX1 Output Mixer RMIX',0
Simple mixer control 'x AUX2 Output Mixer AUX1MIX Output',0
Simple mixer control 'x AUX2 Output Mixer LDAC',0
Simple mixer control 'x AUX2 Output Mixer LINMIX',0
Simple mixer control 'x AUX2 Output Mixer LMIX',0
Simple mixer control 'x Aux Boost',0
Simple mixer control 'x Capture PGA ZC',0
Simple mixer control 'x DAC 128x Oversampling',0
Simple mixer control 'x DAC Companding',0
Simple mixer control 'x DAC Inversion',0
Simple mixer control 'x DAC Playback Limiter',0
Simple mixer control 'x DAC Playback Limiter Attack',0
Simple mixer control 'x DAC Playback Limiter Decay',0
Simple mixer control 'x DAC Playback Limiter Threshold',0
Simple mixer control 'x Digital Loopback',0
Simple mixer control 'x EQ1',0
Simple mixer control 'x EQ1 Cut Off',0
Simple mixer control 'x EQ2',0
Simple mixer control 'x EQ2 Cut Off',0
Simple mixer control 'x EQ3',0
Simple mixer control 'x EQ3 Cut Off',0
Simple mixer control 'x EQ4',0
Simple mixer control 'x EQ4 Cut Off',0
Simple mixer control 'x EQ5',0
Simple mixer control 'x EQ5 Cut Off',0
Simple mixer control 'x Equaliser EQ2 Bandwidth',0
Simple mixer control 'x Equaliser EQ3 Bandwidth',0
Simple mixer control 'x Equaliser EQ4 Bandwidth',0
Simple mixer control 'x Equaliser Function',0
Simple mixer control 'x Headphone',0
Simple mixer control 'x Headphone Playback ZC',0
Simple mixer control 'x High Pass Cut Off',0
Simple mixer control 'x High Pass Filter',0
Simple mixer control 'x Input PGA',0
Simple mixer control 'x L2/R2 Boost',0
Simple mixer control 'x Left Input Mixer L2',0
Simple mixer control 'x Left Input Mixer MicN',0
Simple mixer control 'x Left Input Mixer MicP',0
Simple mixer control 'x Left Output Mixer LAUX',0
Simple mixer control 'x Left Output Mixer LDAC',0
Simple mixer control 'x Left Output Mixer LINMIX',0
Simple mixer control 'x Left Output Mixer RDAC',0
Simple mixer control 'x Line',0
Simple mixer control 'x PCM',0
Simple mixer control 'x PGA Boost (+20dB)',0
Simple mixer control 'x Right Input Mixer MicN',0
Simple mixer control 'x Right Input Mixer MicP',0
Simple mixer control 'x Right Input Mixer R2',0
Simple mixer control 'x Right Output Mixer LDAC',0
Simple mixer control 'x Right Output Mixer RAUX',0
Simple mixer control 'x Right Output Mixer RDAC',0
Simple mixer control 'x Right Output Mixer RINMIX',0
Simple mixer control 'x Speaker',0
Simple mixer control 'x Speaker Playback ZC',0
alsactl init tegrasndt210ref
amixer -c tegrasndt210ref sset "ADMAIF1 Mux" "I2S4"
echo 0 | sudo tee /sys/kernel/debug/tracing/trace
echo 0 | sudo tee /sys/kernel/debug/tracing/events/enable
echo 1 | sudo tee /sys/kernel/debug/tracing/tracing_on
echo 1 | sudo tee /sys/kernel/debug/tracing/events/asoc/snd_soc_dapm_path/enable
echo 1 | sudo tee /sys/kernel/debug/tracing/events/asoc/snd_soc_dapm_widget_power/enable
arecord -D hw:tegrasndt210ref,0 -r 48000 -f S32_LE -c 2 -d 10 test.wav
sudo cat /sys/kernel/debug/tracing/trace


nvidia@nano:~$ sudo cat /sys/kernel/debug/tracing/trace
# tracer: nop
#
# entries-in-buffer/entries-written: 164/164   #P:4
#
#                              _-----=> irqs-off
#                             / _----=> need-resched
#                            | / _---=> hardirq/softirq
#                            || / _--=> preempt-depth
#                            ||| /     delay
#           TASK-PID   CPU#  ||||    TIMESTAMP  FUNCTION
#              | |       |   ||||       |         |
         arecord-14717 [002] .... 14399.421000: snd_soc_dapm_path: *Capture 1 <- (direct) <- ADMAIF1 Transmit
         arecord-14717 [002] .... 14399.421004: snd_soc_dapm_path: *ADMAIF1 Transmit <- (direct) <- ADMAIF1 TX
         arecord-14717 [002] .... 14399.421005: snd_soc_dapm_path: *ADMAIF1 TX <- (direct) <- ADMAIF1 Mux
         arecord-14717 [002] .... 14399.421007: snd_soc_dapm_widget_power: widget=Capture 1 val=1
         arecord-14717 [002] .... 14399.421008: snd_soc_dapm_widget_power: widget=ADMAIF1 Transmit val=1
         arecord-14717 [002] .... 14399.421009: snd_soc_dapm_path: *ADMAIF1 TX -> (direct) -> ADMAIF1 Transmit
         arecord-14717 [002] .... 14399.421010: snd_soc_dapm_widget_power: widget=ADMAIF1 TX val=1
         arecord-14717 [002] .... 14399.421011: snd_soc_dapm_path: *ADMAIF1 Transmit-ADMAIF1 CIF Transmit <- (direct) <- ADMAIF1 Transmit
         arecord-14717 [002] .... 14399.421012: snd_soc_dapm_path: *ADMAIF1 Mux -> (direct) -> ADMAIF1 TX
         arecord-14717 [002] .... 14399.421012: snd_soc_dapm_widget_power: widget=ADMAIF1 Mux val=1
         arecord-14717 [002] .... 14399.421015: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX2 Mux
         arecord-14717 [002] .... 14399.421016: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX1 Mux
         arecord-14717 [002] .... 14399.421017: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-4 Mux
         arecord-14717 [002] .... 14399.421018: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-3 Mux
         arecord-14717 [002] .... 14399.421019: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-2 Mux
         arecord-14717 [002] .... 14399.421019: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-1 Mux
         arecord-14717 [002] .... 14399.421020: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-4 Mux
         arecord-14717 [002] .... 14399.421021: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-3 Mux
         arecord-14717 [002] .... 14399.421021: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-2 Mux
         arecord-14717 [002] .... 14399.421022: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-1 Mux
         arecord-14717 [002] .... 14399.421023: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC2 Mux
         arecord-14717 [002] .... 14399.421024: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC1 Mux
         arecord-14717 [002] .... 14399.421025: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SPKPROT1 Mux
         arecord-14717 [002] .... 14399.421025: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE2 Mux
         arecord-14717 [002] .... 14399.421026: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE1 Mux
         arecord-14717 [002] .... 14399.421027: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC6 Mux
         arecord-14717 [002] .... 14399.421028: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC5 Mux
         arecord-14717 [002] .... 14399.421028: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC4 Mux
         arecord-14717 [002] .... 14399.421029: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC3 Mux
         arecord-14717 [002] .... 14399.421030: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC2 Mux
         arecord-14717 [002] .... 14399.421030: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC1 Mux
         arecord-14717 [002] .... 14399.421031: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-10 Mux
         arecord-14717 [002] .... 14399.421032: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-9 Mux
         arecord-14717 [002] .... 14399.421033: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-8 Mux
         arecord-14717 [002] .... 14399.421033: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-7 Mux
         arecord-14717 [002] .... 14399.421034: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-6 Mux
         arecord-14717 [002] .... 14399.421035: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-5 Mux
         arecord-14717 [002] .... 14399.421036: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-4 Mux
         arecord-14717 [002] .... 14399.421036: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-3 Mux
         arecord-14717 [002] .... 14399.421037: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-2 Mux
         arecord-14717 [002] .... 14399.421038: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-1 Mux
         arecord-14717 [002] .... 14399.421038: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC4 Mux
         arecord-14717 [002] .... 14399.421039: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC3 Mux
         arecord-14717 [002] .... 14399.421040: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC2 Mux
         arecord-14717 [002] .... 14399.421041: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC1 Mux
         arecord-14717 [002] .... 14399.421041: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S5 Mux
         arecord-14717 [002] .... 14399.421042: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S4 Mux
         arecord-14717 [002] .... 14399.421043: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S3 Mux
         arecord-14717 [002] .... 14399.421044: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S2 Mux
         arecord-14717 [002] .... 14399.421044: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S1 Mux
         arecord-14717 [002] .... 14399.421045: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF10 Mux
         arecord-14717 [002] .... 14399.421046: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF9 Mux
         arecord-14717 [002] .... 14399.421046: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF8 Mux
         arecord-14717 [002] .... 14399.421047: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF7 Mux
         arecord-14717 [002] .... 14399.421048: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF6 Mux
         arecord-14717 [002] .... 14399.421048: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF5 Mux
         arecord-14717 [002] .... 14399.421049: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF4 Mux
         arecord-14717 [002] .... 14399.421050: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF3 Mux
         arecord-14717 [002] .... 14399.421050: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF2 Mux
         arecord-14717 [002] .... 14399.421051: snd_soc_dapm_path: *I2S4 RX -> I2S4 -> ADMAIF1 Mux
         arecord-14717 [002] .... 14399.421052: snd_soc_dapm_widget_power: widget=I2S4 RX val=1
         arecord-14717 [002] .... 14399.421053: snd_soc_dapm_path: *I2S4 Receive -> (direct) -> I2S4 RX
         arecord-14717 [002] .... 14399.421054: snd_soc_dapm_widget_power: widget=I2S4 Receive val=1
         arecord-14717 [002] .... 14399.421055: snd_soc_dapm_path: *I2S4 CIF Transmit-I2S4 Receive -> (direct) -> I2S4 Receive
         arecord-14717 [002] .... 14399.421055: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit-I2S4 Receive val=1
         arecord-14717 [002] .... 14399.421056: snd_soc_dapm_path: *I2S4 CIF Transmit -> (direct) -> I2S4 CIF Transmit-I2S4 Receive
         arecord-14717 [002] .... 14399.421058: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit val=1
         arecord-14717 [002] .... 14399.421059: snd_soc_dapm_path: *I2S4 CIF TX -> (direct) -> I2S4 CIF Transmit
         arecord-14717 [002] .... 14399.421059: snd_soc_dapm_widget_power: widget=I2S4 CIF TX val=1
         arecord-14717 [002] .... 14399.421060: snd_soc_dapm_path: *I2S4 DAP RX -> (direct) -> I2S4 CIF TX
         arecord-14717 [002] .... 14399.421061: snd_soc_dapm_widget_power: widget=I2S4 DAP RX val=1
         arecord-14717 [002] .... 14399.421062: snd_soc_dapm_path: *I2S4 DAP Receive -> (direct) -> I2S4 DAP RX
         arecord-14717 [002] .... 14399.421062: snd_soc_dapm_widget_power: widget=I2S4 DAP Receive val=1
         arecord-14717 [002] .... 14399.421064: snd_soc_dapm_path: *x Capture-I2S4 DAP Receive -> (direct) -> I2S4 DAP Receive
         arecord-14717 [002] .... 14399.421064: snd_soc_dapm_widget_power: widget=x Capture-I2S4 DAP Receive val=1
         arecord-14717 [002] .... 14399.421065: snd_soc_dapm_path: *x Capture -> (direct) -> x Capture-I2S4 DAP Receive
         arecord-14717 [002] .... 14399.421066: snd_soc_dapm_widget_power: widget=x Capture val=1
         arecord-14717 [002] .... 14399.421066: snd_soc_dapm_path: *x Mic -> (direct) -> x Capture
         arecord-14717 [002] .... 14399.421067: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICP
         arecord-14717 [002] .... 14399.421068: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICN
         arecord-14717 [002] .... 14399.421069: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICP
         arecord-14717 [002] .... 14399.421070: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICN
         arecord-14717 [002] .... 14399.421070: snd_soc_dapm_widget_power: widget=x Mic val=1
         arecord-14717 [000] .... 14409.431818: snd_soc_dapm_widget_power: widget=Capture 1 val=0
         arecord-14717 [000] .... 14409.431846: snd_soc_dapm_path: *ADMAIF1 Transmit -> (direct) -> Capture 1
         arecord-14717 [000] .... 14409.431858: snd_soc_dapm_path: *ADMAIF1 Transmit -> (direct) -> ADMAIF1 Transmit-ADMAIF1 CIF Transmit
         arecord-14717 [000] .... 14409.431869: snd_soc_dapm_widget_power: widget=ADMAIF1 Transmit val=0
         arecord-14717 [000] .... 14409.431882: snd_soc_dapm_path: *ADMAIF1 TX -> (direct) -> ADMAIF1 Transmit
         arecord-14717 [000] .... 14409.431890: snd_soc_dapm_widget_power: widget=ADMAIF1 TX val=0
         arecord-14717 [000] .... 14409.431900: snd_soc_dapm_path: *ADMAIF1 Mux -> (direct) -> ADMAIF1 TX
         arecord-14717 [000] .... 14409.431909: snd_soc_dapm_widget_power: widget=ADMAIF1 Mux val=0
         arecord-14717 [000] .... 14409.431932: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX2 Mux
         arecord-14717 [000] .... 14409.431942: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX1 Mux
         arecord-14717 [000] .... 14409.431951: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-4 Mux
         arecord-14717 [000] .... 14409.431961: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-3 Mux
         arecord-14717 [000] .... 14409.431970: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-2 Mux
         arecord-14717 [000] .... 14409.431978: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-1 Mux
         arecord-14717 [000] .... 14409.431986: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-4 Mux
         arecord-14717 [000] .... 14409.431994: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-3 Mux
         arecord-14717 [000] .... 14409.432001: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-2 Mux
         arecord-14717 [000] .... 14409.432009: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-1 Mux
         arecord-14717 [000] .... 14409.432017: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC2 Mux
         arecord-14717 [000] .... 14409.432025: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC1 Mux
         arecord-14717 [000] .... 14409.432033: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SPKPROT1 Mux
         arecord-14717 [000] .... 14409.432042: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE2 Mux
         arecord-14717 [000] .... 14409.432050: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE1 Mux
         arecord-14717 [000] .... 14409.432058: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC6 Mux
         arecord-14717 [000] .... 14409.432066: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC5 Mux
         arecord-14717 [000] .... 14409.432073: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC4 Mux
         arecord-14717 [000] .... 14409.432081: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC3 Mux
         arecord-14717 [000] .... 14409.432089: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC2 Mux
         arecord-14717 [000] .... 14409.432097: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC1 Mux
         arecord-14717 [000] .... 14409.432104: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-10 Mux
         arecord-14717 [000] .... 14409.432113: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-9 Mux
         arecord-14717 [000] .... 14409.432123: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-8 Mux
         arecord-14717 [000] .... 14409.432131: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-7 Mux
         arecord-14717 [000] .... 14409.432140: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-6 Mux
         arecord-14717 [000] .... 14409.432148: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-5 Mux
         arecord-14717 [000] .... 14409.432157: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-4 Mux
         arecord-14717 [000] .... 14409.432165: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-3 Mux
         arecord-14717 [000] .... 14409.432173: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-2 Mux
         arecord-14717 [000] .... 14409.432181: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-1 Mux
         arecord-14717 [000] .... 14409.432189: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC4 Mux
         arecord-14717 [000] .... 14409.432196: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC3 Mux
         arecord-14717 [000] .... 14409.432205: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC2 Mux
         arecord-14717 [000] .... 14409.432213: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC1 Mux
         arecord-14717 [000] .... 14409.432221: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S5 Mux
         arecord-14717 [000] .... 14409.432229: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S4 Mux
         arecord-14717 [000] .... 14409.432237: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S3 Mux
         arecord-14717 [000] .... 14409.432245: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S2 Mux
         arecord-14717 [000] .... 14409.432253: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S1 Mux
         arecord-14717 [000] .... 14409.432261: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF10 Mux
         arecord-14717 [000] .... 14409.432269: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF9 Mux
         arecord-14717 [000] .... 14409.432277: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF8 Mux
         arecord-14717 [000] .... 14409.432286: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF7 Mux
         arecord-14717 [000] .... 14409.432293: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF6 Mux
         arecord-14717 [000] .... 14409.432302: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF5 Mux
         arecord-14717 [000] .... 14409.432309: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF4 Mux
         arecord-14717 [000] .... 14409.432318: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF3 Mux
         arecord-14717 [000] .... 14409.432326: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF2 Mux
         arecord-14717 [000] .... 14409.432333: snd_soc_dapm_path: *I2S4 RX -> I2S4 -> ADMAIF1 Mux
         arecord-14717 [000] .... 14409.432341: snd_soc_dapm_widget_power: widget=I2S4 RX val=0
         arecord-14717 [000] .... 14409.432361: snd_soc_dapm_path: *I2S4 Receive -> (direct) -> I2S4 RX
         arecord-14717 [000] .... 14409.432370: snd_soc_dapm_widget_power: widget=I2S4 Receive val=0
         arecord-14717 [000] .... 14409.432382: snd_soc_dapm_path: *I2S4 CIF Transmit-I2S4 Receive -> (direct) -> I2S4 Receive
         arecord-14717 [000] .... 14409.432391: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit-I2S4 Receive val=0
         arecord-14717 [000] .... 14409.432402: snd_soc_dapm_path: *I2S4 CIF Transmit -> (direct) -> I2S4 CIF Transmit-I2S4 Receive
         arecord-14717 [000] .... 14409.432411: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit val=0
         arecord-14717 [000] .... 14409.432422: snd_soc_dapm_path: *I2S4 CIF TX -> (direct) -> I2S4 CIF Transmit
         arecord-14717 [000] .... 14409.432430: snd_soc_dapm_widget_power: widget=I2S4 CIF TX val=0
         arecord-14717 [000] .... 14409.432449: snd_soc_dapm_path: *I2S4 DAP RX -> (direct) -> I2S4 CIF TX
         arecord-14717 [000] .... 14409.432458: snd_soc_dapm_widget_power: widget=I2S4 DAP RX val=0
         arecord-14717 [000] .... 14409.432469: snd_soc_dapm_path: *I2S4 DAP Receive -> (direct) -> I2S4 DAP RX
         arecord-14717 [000] .... 14409.432478: snd_soc_dapm_widget_power: widget=I2S4 DAP Receive val=0
         arecord-14717 [000] .... 14409.432490: snd_soc_dapm_path: *x Capture-I2S4 DAP Receive -> (direct) -> I2S4 DAP Receive
         arecord-14717 [000] .... 14409.432499: snd_soc_dapm_widget_power: widget=x Capture-I2S4 DAP Receive val=0
         arecord-14717 [000] .... 14409.432509: snd_soc_dapm_path: *x Capture -> (direct) -> x Capture-I2S4 DAP Receive
         arecord-14717 [000] .... 14409.432517: snd_soc_dapm_widget_power: widget=x Capture val=0
         arecord-14717 [000] .... 14409.432528: snd_soc_dapm_path: *x Mic -> (direct) -> x Capture
         arecord-14717 [000] .... 14409.432537: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICP
         arecord-14717 [000] .... 14409.432546: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICN
         arecord-14717 [000] .... 14409.432554: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICP
         arecord-14717 [000] .... 14409.432563: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICN
         arecord-14717 [000] .... 14409.432571: snd_soc_dapm_widget_power: widget=x Mic val=0

Hi,

Routing in driver:

static const struct snd_soc_dapm_route nau8822_dapm_routes[] = {
	//{"Right DAC", NULL, "PLL", check_mclk_select_pll},
	//{"Left DAC", NULL, "PLL", check_mclk_select_pll},
	{"Left DAC", NULL, "Playback"},
	{"Right DAC", NULL, "Playback"},

	/* LMAIN and RMAIN mixer */
	{"Right Output Mixer", "LDAC Switch", "Left DAC"},
	{"Right Output Mixer", "RDAC Switch", "Right DAC"},
	{"Right Output Mixer", "RAUX Switch", "RAUX"},
	{"Right Output Mixer", "RINMIX Switch", "Right Boost Mixer"},

	{"Left Output Mixer", "LDAC Switch", "Left DAC"},
	{"Left Output Mixer", "RDAC Switch", "Right DAC"},
	{"Left Output Mixer", "LAUX Switch", "LAUX"},
	{"Left Output Mixer", "LINMIX Switch", "Left Boost Mixer"},

	/* AUX1 and AUX2 mixer */
	{"AUX1 Output Mixer", "RDAC Switch", "Right DAC"},
	{"AUX1 Output Mixer", "RMIX Switch", "Right Output Mixer"},
	{"AUX1 Output Mixer", "RINMIX Switch", "Right Boost Mixer"},
	{"AUX1 Output Mixer", "LDAC Switch", "Left DAC"},
	{"AUX1 Output Mixer", "LMIX Switch", "Left Output Mixer"},

	{"AUX2 Output Mixer", "LDAC Switch", "Left DAC"},
	{"AUX2 Output Mixer", "LMIX Switch", "Left Output Mixer"},
	{"AUX2 Output Mixer", "LINMIX Switch", "Left Boost Mixer"},
	{"AUX2 Output Mixer", "AUX1MIX Output Switch", "AUX1 Output Mixer"},

	/* Outputs */
	{"Right Headphone Out", NULL, "Right Output Mixer"},
	{"RHP", NULL, "Right Headphone Out"},

	{"Left Headphone Out", NULL, "Left Output Mixer"},
	{"LHP", NULL, "Left Headphone Out"},

	{"Right Speaker Out", NULL, "Right Output Mixer"},
	{"RSPK", NULL, "Right Speaker Out"},

	{"Left Speaker Out", NULL, "Left Output Mixer"},
	{"LSPK", NULL, "Left Speaker Out"},

	{"AUX1 Out", NULL, "AUX1 Output Mixer"},
	{"AUX2 Out", NULL, "AUX2 Output Mixer"},
	{"AUXOUT1", NULL, "AUX1 Out"},
	{"AUXOUT2", NULL, "AUX2 Out"},

	/* Boost Mixer */
	{"Right ADC", NULL, "PLL", check_mclk_select_pll},
	{"Left ADC", NULL, "PLL", check_mclk_select_pll},

	{"Right ADC", NULL, "Right Boost Mixer"},

	{"Right Boost Mixer", NULL, "RAUX"},
	{"Right Boost Mixer", NULL, "Right Capture PGA"},
	{"Right Boost Mixer", NULL, "R2"},

	{"Left ADC", NULL, "Left Boost Mixer"},

	{"Left Boost Mixer", NULL, "LAUX"},
	{"Left Boost Mixer", NULL, "Left Capture PGA"},
	{"Left Boost Mixer", NULL, "L2"},

	/* Input PGA */
	{"Right Capture PGA", NULL, "Right Input Mixer"},
	{"Left Capture PGA", NULL, "Left Input Mixer"},

	/*enable microphone power*/
	{"Right Capture PGA", NULL, "Mic Bias"},
	{"Left Capture PGA", NULL, "Mic Bias"},

	{"Right Input Mixer", "R2 Switch", "R2"},
	{"Right Input Mixer", "MicN Switch", "RMICN"},
	{"Right Input Mixer", "MicP Switch", "RMICP"},

	{"Left Input Mixer", "L2 Switch", "L2"},
	{"Left Input Mixer", "MicN Switch", "LMICN"},
	{"Left Input Mixer", "MicP Switch", "LMICP"},
};	

I use the bash to get audio information to file tegra-audio-debug.txt

#!/bin/bash

set -e
set -u

outfile="${HOME}/tegra-audio-debug.txt"

if [ -f "${outfile}" ]; then
rm "${outfile}"
fi

alsactl store -f "${outfile}"

dapm_dirs=$(sudo find /sys/kernel/debug/asoc -type d -name dapm)

for dir in ${dapm_dirs}; do
sudo find ${dir} -type f -exec echo {} \; -exec cat {} \; >> "${outfile}"
done

echo "Tegra audio debug info written to ${outfile}"

tegra-audio-debug.txt (320.9 KB)

Hello!

Is the problem that the captured audio is all zero’s? It appears that arecord is running but I assume that there is no audio in the WAV file that is created. Please confirm. If this is the case, are you able to check if the data out from the codec if actually outputting data? You will need an oscilloscope to check this.

Regards,
Jon

Hi jonathanh,

Yes, the captured audio is all zero’s. We will first check the outputting data with osc.
Thanks.

Hi jonathanh,

After enable Micbias we can record audio not zero, and we can see data on I2S, but when we play the test.wav file there is no sound heard.
Can help to check again?

alsactl init tegrasndt210ref
amixer -c tegrasndt210ref cset name="ADMAIF1 Mux" "I2S4"
echo 0 | sudo tee /sys/kernel/debug/tracing/trace
echo 0 | sudo tee /sys/kernel/debug/tracing/events/enable
echo 1 | sudo tee /sys/kernel/debug/tracing/tracing_on
echo 1 | sudo tee /sys/kernel/debug/tracing/events/asoc/snd_soc_dapm_path/enable
echo 1 | sudo tee /sys/kernel/debug/tracing/events/asoc/snd_soc_dapm_widget_power/enable
arecord -D hw:tegrasndt210ref,0 -r 48000 -f S32_LE -c 2 -d 10 test.wav
sudo cat /sys/kernel/debug/tracing/trace
Reset Tegra APE sound-card controls
numid=570,iface=MIXER,name='ADMAIF1 Mux'
  ; type=ENUMERATED,access=rw------,values=1,items=53
  ; Item #0 'None'
  ; Item #1 'ADMAIF1'
  ; Item #2 'ADMAIF2'
  ; Item #3 'ADMAIF3'
  ; Item #4 'ADMAIF4'
  ; Item #5 'ADMAIF5'
  ; Item #6 'ADMAIF6'
  ; Item #7 'ADMAIF7'
  ; Item #8 'ADMAIF8'
  ; Item #9 'ADMAIF9'
  ; Item #10 'ADMAIF10'
  ; Item #11 'I2S1'
  ; Item #12 'I2S2'
  ; Item #13 'I2S3'
  ; Item #14 'I2S4'
  ; Item #15 'I2S5'
  ; Item #16 'SFC1'
  ; Item #17 'SFC2'
  ; Item #18 'SFC3'
  ; Item #19 'SFC4'
  ; Item #20 'MIXER1-1'
  ; Item #21 'MIXER1-2'
  ; Item #22 'MIXER1-3'
  ; Item #23 'MIXER1-4'
  ; Item #24 'MIXER1-5'
  ; Item #25 'AMX1'
  ; Item #26 'AMX2'
  ; Item #27 'AFC1'
  ; Item #28 'AFC2'
  ; Item #29 'AFC3'
  ; Item #30 'AFC4'
  ; Item #31 'AFC5'
  ; Item #32 'AFC6'
  ; Item #33 'OPE1'
  ; Item #34 'OPE2'
  ; Item #35 'SPKPROT1'
  ; Item #36 'MVC1'
  ; Item #37 'MVC2'
  ; Item #38 'IQC1-1'
  ; Item #39 'IQC1-2'
  ; Item #40 'IQC2-1'
  ; Item #41 'IQC2-2'
  ; Item #42 'DMIC1'
  ; Item #43 'DMIC2'
  ; Item #44 'DMIC3'
  ; Item #45 'ADX1-1'
  ; Item #46 'ADX1-2'
  ; Item #47 'ADX1-3'
  ; Item #48 'ADX1-4'
  ; Item #49 'ADX2-1'
  ; Item #50 'ADX2-2'
  ; Item #51 'ADX2-3'
  ; Item #52 'ADX2-4'
  : values=14
0
0
1
1
1
Home directory not accessible: Permission denied
Recording WAVE 'test.wav' : Signed 32 bit Little Endian, Rate 48000 Hz, Stereo
# tracer: nop
#
# entries-in-buffer/entries-written: 164/164   #P:4
#
#                              _-----=> irqs-off
#                             / _----=> need-resched
#                            | / _---=> hardirq/softirq
#                            || / _--=> preempt-depth
#                            ||| /     delay
#           TASK-PID   CPU#  ||||    TIMESTAMP  FUNCTION
#              | |       |   ||||       |         |
         arecord-6587  [002] ....    79.056089: snd_soc_dapm_path: *Capture 1 <- (direct) <- ADMAIF1 Transmit
         arecord-6587  [002] ....    79.056092: snd_soc_dapm_path: *ADMAIF1 Transmit <- (direct) <- ADMAIF1 TX
         arecord-6587  [002] ....    79.056093: snd_soc_dapm_path: *ADMAIF1 TX <- (direct) <- ADMAIF1 Mux
         arecord-6587  [002] ....    79.056095: snd_soc_dapm_widget_power: widget=Capture 1 val=1
         arecord-6587  [002] ....    79.056096: snd_soc_dapm_widget_power: widget=ADMAIF1 Transmit val=1
         arecord-6587  [002] ....    79.056097: snd_soc_dapm_path: *ADMAIF1 TX -> (direct) -> ADMAIF1 Transmit
         arecord-6587  [002] ....    79.056098: snd_soc_dapm_widget_power: widget=ADMAIF1 TX val=1
         arecord-6587  [002] ....    79.056099: snd_soc_dapm_path: *ADMAIF1 Transmit-ADMAIF1 CIF Transmit <- (direct) <- ADMAIF1 Transmit
         arecord-6587  [002] ....    79.056100: snd_soc_dapm_path: *ADMAIF1 Mux -> (direct) -> ADMAIF1 TX
         arecord-6587  [002] ....    79.056101: snd_soc_dapm_widget_power: widget=ADMAIF1 Mux val=1
         arecord-6587  [002] ....    79.056103: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX2 Mux
         arecord-6587  [002] ....    79.056104: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX1 Mux
         arecord-6587  [002] ....    79.056105: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-4 Mux
         arecord-6587  [002] ....    79.056105: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-3 Mux
         arecord-6587  [002] ....    79.056106: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-2 Mux
         arecord-6587  [002] ....    79.056107: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-1 Mux
         arecord-6587  [002] ....    79.056107: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-4 Mux
         arecord-6587  [002] ....    79.056108: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-3 Mux
         arecord-6587  [002] ....    79.056109: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-2 Mux
         arecord-6587  [002] ....    79.056109: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-1 Mux
         arecord-6587  [002] ....    79.056110: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC2 Mux
         arecord-6587  [002] ....    79.056111: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC1 Mux
         arecord-6587  [002] ....    79.056111: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SPKPROT1 Mux
         arecord-6587  [002] ....    79.056112: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE2 Mux
         arecord-6587  [002] ....    79.056113: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE1 Mux
         arecord-6587  [002] ....    79.056113: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC6 Mux
         arecord-6587  [002] ....    79.056114: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC5 Mux
         arecord-6587  [002] ....    79.056115: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC4 Mux
         arecord-6587  [002] ....    79.056115: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC3 Mux
         arecord-6587  [002] ....    79.056116: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC2 Mux
         arecord-6587  [002] ....    79.056117: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC1 Mux
         arecord-6587  [002] ....    79.056118: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-10 Mux
         arecord-6587  [002] ....    79.056118: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-9 Mux
         arecord-6587  [002] ....    79.056119: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-8 Mux
         arecord-6587  [002] ....    79.056120: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-7 Mux
         arecord-6587  [002] ....    79.056120: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-6 Mux
         arecord-6587  [002] ....    79.056121: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-5 Mux
         arecord-6587  [002] ....    79.056122: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-4 Mux
         arecord-6587  [002] ....    79.056123: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-3 Mux
         arecord-6587  [002] ....    79.056123: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-2 Mux
         arecord-6587  [002] ....    79.056124: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-1 Mux
         arecord-6587  [002] ....    79.056125: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC4 Mux
         arecord-6587  [002] ....    79.056125: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC3 Mux
         arecord-6587  [002] ....    79.056126: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC2 Mux
         arecord-6587  [002] ....    79.056127: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC1 Mux
         arecord-6587  [002] ....    79.056127: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S5 Mux
         arecord-6587  [002] ....    79.056128: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S4 Mux
         arecord-6587  [002] ....    79.056129: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S3 Mux
         arecord-6587  [002] ....    79.056129: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S2 Mux
         arecord-6587  [002] ....    79.056130: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S1 Mux
         arecord-6587  [002] ....    79.056131: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF10 Mux
         arecord-6587  [002] ....    79.056131: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF9 Mux
         arecord-6587  [002] ....    79.056132: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF8 Mux
         arecord-6587  [002] ....    79.056133: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF7 Mux
         arecord-6587  [002] ....    79.056134: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF6 Mux
         arecord-6587  [002] ....    79.056134: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF5 Mux
         arecord-6587  [002] ....    79.056135: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF4 Mux
         arecord-6587  [002] ....    79.056136: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF3 Mux
         arecord-6587  [002] ....    79.056136: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF2 Mux
         arecord-6587  [002] ....    79.056137: snd_soc_dapm_path: *I2S4 RX -> I2S4 -> ADMAIF1 Mux
         arecord-6587  [002] ....    79.056137: snd_soc_dapm_widget_power: widget=I2S4 RX val=1
         arecord-6587  [002] ....    79.056139: snd_soc_dapm_path: *I2S4 Receive -> (direct) -> I2S4 RX
         arecord-6587  [002] ....    79.056140: snd_soc_dapm_widget_power: widget=I2S4 Receive val=1
         arecord-6587  [002] ....    79.056140: snd_soc_dapm_path: *I2S4 CIF Transmit-I2S4 Receive -> (direct) -> I2S4 Receive
         arecord-6587  [002] ....    79.056141: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit-I2S4 Receive val=1
         arecord-6587  [002] ....    79.056142: snd_soc_dapm_path: *I2S4 CIF Transmit -> (direct) -> I2S4 CIF Transmit-I2S4 Receive
         arecord-6587  [002] ....    79.056144: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit val=1
         arecord-6587  [002] ....    79.056145: snd_soc_dapm_path: *I2S4 CIF TX -> (direct) -> I2S4 CIF Transmit
         arecord-6587  [002] ....    79.056145: snd_soc_dapm_widget_power: widget=I2S4 CIF TX val=1
         arecord-6587  [002] ....    79.056146: snd_soc_dapm_path: *I2S4 DAP RX -> (direct) -> I2S4 CIF TX
         arecord-6587  [002] ....    79.056147: snd_soc_dapm_widget_power: widget=I2S4 DAP RX val=1
         arecord-6587  [002] ....    79.056148: snd_soc_dapm_path: *I2S4 DAP Receive -> (direct) -> I2S4 DAP RX
         arecord-6587  [002] ....    79.056148: snd_soc_dapm_widget_power: widget=I2S4 DAP Receive val=1
         arecord-6587  [002] ....    79.056149: snd_soc_dapm_path: *x Capture-I2S4 DAP Receive -> (direct) -> I2S4 DAP Receive
         arecord-6587  [002] ....    79.056150: snd_soc_dapm_widget_power: widget=x Capture-I2S4 DAP Receive val=1
         arecord-6587  [002] ....    79.056151: snd_soc_dapm_path: *x Capture -> (direct) -> x Capture-I2S4 DAP Receive
         arecord-6587  [002] ....    79.056151: snd_soc_dapm_widget_power: widget=x Capture val=1
         arecord-6587  [002] ....    79.056152: snd_soc_dapm_path: *x Mic -> (direct) -> x Capture
         arecord-6587  [002] ....    79.056153: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICP
         arecord-6587  [002] ....    79.056154: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICN
         arecord-6587  [002] ....    79.056155: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICP
         arecord-6587  [002] ....    79.056156: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICN
         arecord-6587  [002] ....    79.056156: snd_soc_dapm_widget_power: widget=x Mic val=1
         arecord-6587  [000] ....    89.066726: snd_soc_dapm_widget_power: widget=Capture 1 val=0
         arecord-6587  [000] ....    89.066755: snd_soc_dapm_path: *ADMAIF1 Transmit -> (direct) -> Capture 1
         arecord-6587  [000] ....    89.066768: snd_soc_dapm_path: *ADMAIF1 Transmit -> (direct) -> ADMAIF1 Transmit-ADMAIF1 CIF Transmit
         arecord-6587  [000] ....    89.066780: snd_soc_dapm_widget_power: widget=ADMAIF1 Transmit val=0
         arecord-6587  [000] ....    89.066792: snd_soc_dapm_path: *ADMAIF1 TX -> (direct) -> ADMAIF1 Transmit
         arecord-6587  [000] ....    89.066801: snd_soc_dapm_widget_power: widget=ADMAIF1 TX val=0
         arecord-6587  [000] ....    89.066811: snd_soc_dapm_path: *ADMAIF1 Mux -> (direct) -> ADMAIF1 TX
         arecord-6587  [000] ....    89.066820: snd_soc_dapm_widget_power: widget=ADMAIF1 Mux val=0
         arecord-6587  [000] ....    89.066842: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX2 Mux
         arecord-6587  [000] ....    89.066852: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADX1 Mux
         arecord-6587  [000] ....    89.066861: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-4 Mux
         arecord-6587  [000] ....    89.066870: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-3 Mux
         arecord-6587  [000] ....    89.066878: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-2 Mux
         arecord-6587  [000] ....    89.066886: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX2-1 Mux
         arecord-6587  [000] ....    89.066894: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-4 Mux
         arecord-6587  [000] ....    89.066902: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-3 Mux
         arecord-6587  [000] ....    89.066910: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-2 Mux
         arecord-6587  [000] ....    89.066918: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AMX1-1 Mux
         arecord-6587  [000] ....    89.066926: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC2 Mux
         arecord-6587  [000] ....    89.066934: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MVC1 Mux
         arecord-6587  [000] ....    89.066942: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SPKPROT1 Mux
         arecord-6587  [000] ....    89.066951: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE2 Mux
         arecord-6587  [000] ....    89.066959: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> OPE1 Mux
         arecord-6587  [000] ....    89.066967: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC6 Mux
         arecord-6587  [000] ....    89.066975: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC5 Mux
         arecord-6587  [000] ....    89.066983: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC4 Mux
         arecord-6587  [000] ....    89.066991: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC3 Mux
         arecord-6587  [000] ....    89.066998: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC2 Mux
         arecord-6587  [000] ....    89.067007: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> AFC1 Mux
         arecord-6587  [000] ....    89.067015: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-10 Mux
         arecord-6587  [000] ....    89.067024: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-9 Mux
         arecord-6587  [000] ....    89.067033: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-8 Mux
         arecord-6587  [000] ....    89.067041: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-7 Mux
         arecord-6587  [000] ....    89.067049: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-6 Mux
         arecord-6587  [000] ....    89.067057: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-5 Mux
         arecord-6587  [000] ....    89.067066: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-4 Mux
         arecord-6587  [000] ....    89.067074: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-3 Mux
         arecord-6587  [000] ....    89.067082: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-2 Mux
         arecord-6587  [000] ....    89.067090: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> MIXER1-1 Mux
         arecord-6587  [000] ....    89.067098: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC4 Mux
         arecord-6587  [000] ....    89.067106: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC3 Mux
         arecord-6587  [000] ....    89.067114: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC2 Mux
         arecord-6587  [000] ....    89.067122: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> SFC1 Mux
         arecord-6587  [000] ....    89.067130: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S5 Mux
         arecord-6587  [000] ....    89.067138: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S4 Mux
         arecord-6587  [000] ....    89.067146: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S3 Mux
         arecord-6587  [000] ....    89.067154: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S2 Mux
         arecord-6587  [000] ....    89.067162: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> I2S1 Mux
         arecord-6587  [000] ....    89.067170: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF10 Mux
         arecord-6587  [000] ....    89.067179: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF9 Mux
         arecord-6587  [000] ....    89.067187: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF8 Mux
         arecord-6587  [000] ....    89.067195: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF7 Mux
         arecord-6587  [000] ....    89.067204: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF6 Mux
         arecord-6587  [000] ....    89.067212: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF5 Mux
         arecord-6587  [000] ....    89.067220: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF4 Mux
         arecord-6587  [000] ....    89.067228: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF3 Mux
         arecord-6587  [000] ....    89.067236: snd_soc_dapm_path:  I2S4 RX -> I2S4 -> ADMAIF2 Mux
         arecord-6587  [000] ....    89.067244: snd_soc_dapm_path: *I2S4 RX -> I2S4 -> ADMAIF1 Mux
         arecord-6587  [000] ....    89.067251: snd_soc_dapm_widget_power: widget=I2S4 RX val=0
         arecord-6587  [000] ....    89.067268: snd_soc_dapm_path: *I2S4 Receive -> (direct) -> I2S4 RX
         arecord-6587  [000] ....    89.067277: snd_soc_dapm_widget_power: widget=I2S4 Receive val=0
         arecord-6587  [000] ....    89.067289: snd_soc_dapm_path: *I2S4 CIF Transmit-I2S4 Receive -> (direct) -> I2S4 Receive
         arecord-6587  [000] ....    89.067298: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit-I2S4 Receive val=0
         arecord-6587  [000] ....    89.067310: snd_soc_dapm_path: *I2S4 CIF Transmit -> (direct) -> I2S4 CIF Transmit-I2S4 Receive
         arecord-6587  [000] ....    89.067319: snd_soc_dapm_widget_power: widget=I2S4 CIF Transmit val=0
         arecord-6587  [000] ....    89.067331: snd_soc_dapm_path: *I2S4 CIF TX -> (direct) -> I2S4 CIF Transmit
         arecord-6587  [000] ....    89.067339: snd_soc_dapm_widget_power: widget=I2S4 CIF TX val=0
         arecord-6587  [000] ....    89.067359: snd_soc_dapm_path: *I2S4 DAP RX -> (direct) -> I2S4 CIF TX
         arecord-6587  [000] ....    89.067368: snd_soc_dapm_widget_power: widget=I2S4 DAP RX val=0
         arecord-6587  [000] ....    89.067380: snd_soc_dapm_path: *I2S4 DAP Receive -> (direct) -> I2S4 DAP RX
         arecord-6587  [000] ....    89.067388: snd_soc_dapm_widget_power: widget=I2S4 DAP Receive val=0
         arecord-6587  [000] ....    89.067400: snd_soc_dapm_path: *x Capture-I2S4 DAP Receive -> (direct) -> I2S4 DAP Receive
         arecord-6587  [000] ....    89.067409: snd_soc_dapm_widget_power: widget=x Capture-I2S4 DAP Receive val=0
         arecord-6587  [000] ....    89.067421: snd_soc_dapm_path: *x Capture -> (direct) -> x Capture-I2S4 DAP Receive
         arecord-6587  [000] ....    89.067429: snd_soc_dapm_widget_power: widget=x Capture val=0
         arecord-6587  [000] ....    89.067439: snd_soc_dapm_path: *x Mic -> (direct) -> x Capture
         arecord-6587  [000] ....    89.067449: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICP
         arecord-6587  [000] ....    89.067457: snd_soc_dapm_path: *x Mic -> (direct) -> x RMICN
         arecord-6587  [000] ....    89.067466: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICP
         arecord-6587  [000] ....    89.067476: snd_soc_dapm_path: *x Mic -> (direct) -> x LMICN
         arecord-6587  [000] ....    89.067484: snd_soc_dapm_widget_power: widget=x Mic val=0

Hello!

OK great. The next thing to check is the pinmux configuration. Are you using the Nano devkit or custom hardware?

What is the output from the following commands?

sudo cat /sys/kernel/debug/tegra_gpio
sudo grep dap4 /sys/kernel/debug/tegra_pinctrl_reg

Regards,
Jon

Hi jonathanh,

Sorry to reply later. I dump the test.wav file hex format.

nvidia@nano:~$ sudo grep "Name:\|J:\|BB:" /sys/kernel/debug/tegra_gpio
Name:Bank:Port CNF OE OUT IN INT_STA INT_ENB INT_LVL
 J: 2:1 00 00 00 00 00 00 000000
BB: 6:3 00 00 00 00 00 00 000000


nvidia@nano:~$ sudo grep dap4 /sys/kernel/debug/tegra_pinctrl_reg
Bank: 1 Reg: 0x70003144 Val: 0x00000048 -> dap4_fs_pj4
Bank: 1 Reg: 0x70003148 Val: 0x00000048 -> dap4_din_pj5
Bank: 1 Reg: 0x7000314c Val: 0x00000008 -> dap4_dout_pj6
Bank: 1 Reg: 0x70003150 Val: 0x00000008 -> dap4_sclk_pj7

nvidia@nano:~$ arecord -D hw:tegrasndt210ref,0 -r 16000 -f S16_LE -c 2 -d 10 test.wav 

nvidia@nano:~$ hexdump test.wav
0000000 4952 4646 c424 0009 4157 4556 6d66 2074
0000010 0010 0000 0001 0002 3e80 0000 fa00 0000
0000020 0004 0010 6164 6174 c400 0009 0002 fffe
0000030 0002 fffe 0002 fffe 0002 fffe 0002 fffe
*
009c42c

SW: JetPack4.4 (L4T-R32.4.3)

Hi,

I tried to run these commands and get i2s registers here.

amixer -c tegrasndt210ref sset "ADMAIF1 Mux" "I2S4"
arecord -D hw:tegrasndt210ref,0 -r 16000 -f S16_LE -c 2 -d 10 test.wav &
sudo grep dap4 /sys/kernel/debug/tegra_pinctrl_reg
sudo grep "Name:\|J:\|BB:" /sys/kernel/debug/tegra_gpio
sudo cat /sys/kernel/debug/regmap/tegra210-i2s.3/registers
nvidia@nano:~$ amixer -c tegrasndt210ref sset "ADMAIF1 Mux" "I2S4"
Simple mixer control 'ADMAIF1 Mux',0
  Capabilities: enum
  Items: 'None' 'ADMAIF1' 'ADMAIF2' 'ADMAIF3' 'ADMAIF4' 'ADMAIF5' 'ADMAIF6' 'ADMAIF7' 'ADMAIF8' 'ADMAIF9' 'ADMAIF10' 'I2S1' 'I2S2' 'I2S3' 'I2S4' 'I2S5' 'SFC1' 'SFC2' 'SFC3' 'SFC4' 'MIXER1-1' 'MIXER1-2' 'MIXER1-3' 'MIXER1-4' 'MIXER1-5' 'AMX1' 'AMX2' 'AFC1' 'AFC2' 'AFC3' 'AFC4' 'AFC5' 'AFC6' 'OPE1' 'OPE2' 'SPKPROT1' 'MVC1' 'MVC2' 'IQC1-1' 'IQC1-2' 'IQC2-1' 'IQC2-2' 'DMIC1' 'DMIC2' 'DMIC3' 'ADX1-1' 'ADX1-2' 'ADX1-3' 'ADX1-4' 'ADX2-1' 'ADX2-2' 'ADX2-3' 'ADX2-4'
  Item0: 'I2S4'
nvidia@nano:~$ arecord -D hw:tegrasndt210ref,0 -r 16000 -f S16_LE -c 2 -d 10 test.wav &
[1] 6421
nvidia@nano:~$ Recording WAVE 'test.wav' : Signed 16 bit Little Endian, Rate 16000 Hz, Stereo
nvidia@nano:~$ sudo grep dap4 /sys/kernel/debug/tegra_pinctrl_reg
Bank: 1 Reg: 0x70003144 Val: 0x00000048 -> dap4_fs_pj4
Bank: 1 Reg: 0x70003148 Val: 0x00000048 -> dap4_din_pj5
Bank: 1 Reg: 0x7000314c Val: 0x00000008 -> dap4_dout_pj6
Bank: 1 Reg: 0x70003150 Val: 0x00000008 -> dap4_sclk_pj7
nvidia@nano:~$ sudo grep "Name:\|J:\|BB:" /sys/kernel/debug/tegra_gpio
Name:Bank:Port CNF OE OUT IN INT_STA INT_ENB INT_LVL
 J: 2:1 00 00 00 00 00 00 000000
BB: 6:3 00 00 00 00 00 00 000000
nvidia@nano:~$ sudo cat /sys/kernel/debug/regmap/tegra210-i2s.3/registers
00: 00000000
04: 00000000
08: 00000000
0c: 00000002
10: 00000003
14: 00000003
18: 00000000
1c: 00000000
20: 03113300
24: 00000100
28: 00000000
2c: 00000000
30: 00000000
34: 00000000
38: 00000000
3c: 00000000
40: 00000001
44: 00000000
48: 00000000
4c: 00000001
50: 00000001
54: 00000003
58: 00000000
5c: 00000000
60: 00113300
64: 00000100
68: 00000000
6c: 00000000
70: 00000000
74: 00000000
78: 00000000
7c: 00000000
80: 00000001
84: 00000000
88: 00000001
8c: 00000000
90: 00000301
94: 00000000
98: 00000000
9c: 00000000
a0: 0f000403
a4: 0000000f
a8: 00000000
ac: 00000000
b0: 00000001

Hi jonathanh,

Can you help to check the information last two posts?
Thanks.

Hi ,

I have fix this problem root cause is the register setting of nau88c22, PGA is muted.

1 Like

Hello!

Apologies for the delay, but glad to hear that you were able to track this down and get it working. Thanks for letting us know.

Regards
Jon