How to modify the 00-tegra.conf or 01-tegra-rt565x.conf to save the mixer setting to emmc flash?

Dear sir:

The mixer setting are as the following, so i modify the 01-tegra-rt565x.conf as the attachment. But after flashing the whole root file system, the mixer setting is not ok after power on.00-tegra.conf (6.0 KB)
01-tegra-rt565x.conf (3.8 KB)

amixer -c1 cset name=“I2S5 Mux” “ADMAIF1”
amixer -c1 cset name=‘x DAC MIXL INF1 Switch’ 1
amixer -c1 cset name=‘x DAC MIXR INF1 Switch’ 1
amixer -c1 cset name=‘x Stereo DAC MIXR DAC R1 Switch’ 1
amixer -c1 cset name=‘x Stereo DAC MIXL DAC L1 Switch’ 1

amixer -c1 cset name=‘x HP Playback Switch’ 1
amixer -c1 cset name=‘x HPO MIX DAC1 Switch’ 1
amixer -c1 cset name=‘x HPO MIX HPVOL Switch’ 1

amixer -c1 cset name=‘x OUT Playback Switch’ 1
amixer -c1 cset name=‘x LOUT MIX DAC R1 Switch’ 1
amixer -c1 cset name=‘x LOUT MIX DAC L1 Switch’ 1

Are you talking about the file didn’t change after you flash the board?

What is your method to modify this file?

Dear sir:

My ways is : Before flash, modify the file(rootfs/usr/share/alsa/init/postinit/01-tegra-rt565x.conf) as comment, then flash.

When the flash is complete, after power on, The content of 01-tegra-rt565x.conf is modified, but the mixer setting is not ok, the playback is no sound.

Does your “then flash” mean you use flash.sh directly? or something else?

Yes , mean flash.sh.

Hello, can you give some suggestion? Tks!

Hi,

If there is no rt565x codec present, then settings in the 01-tegra-rt565x.conf will not be applied. If you look at the top of that file you will see …

CTL{name}="x TDM Data Mux",PROGRAM!="__ctl_search",GOTO="Tegra RT565x Next"

The above detects the presence of the codec by seeing if the mixer control ‘x TDM Data Mux’ exists, if it does not then it skips to the next section and check if ‘y TDM Data Mux’ exists, and if not then nothing is done. Please check if these mixer controls are present.

You can dump the mixer controls by …

amixer -c tegrasndt19xmob controls

Dear sir:

Tks, after i modify the script, the playback is ok.

I have another question:
I have added “CARDINFO{driver}==“jetsonxaviernxa”, GOTO=“Tegra RT565x Init”” to 01-tegra-rt565x.conf . Then i use the command to play music, it is ok.
aplay music.wav. At the playing timing, if i use the command “arecord -D hw:jetsonxaviernxa,0 -c 2 -r 48000 -f S16_LE -d 15 out.wav” , the out.wav is ok , but if i use “arecord -c 2 -r 48000 -f S16_LE -d 15 out.wav”, the out.wav is failed. why?

Hello!

If you don’t specify ‘-D hw:jetsonxaviernxa,0’ then arecord will use the default device that is specified in /etc/asound.conf. Typically /etc/asound.conf will be a soft-link to either /etc/asound.conf.tegrasndt194ref or /etc/asound.conf.tegrahdaxaviernx. If it is a soft-link to /etc/asound.conf.tegrasndt194ref, then arecord should default to ‘hw:jetsonxaviernxa,0’. You can also use ‘-v’ for arecord to see which device it is recording from.

Regards,
Jon

Dear sir:
Tks!
The result of arecord -v is as following:
root@tegra-ubuntu:/home/ubuntu# arecord -v -c 2 -r 48000 -f S16_LE -d 15 out.wav
Recording WAVE ‘out.wav’ : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Plug PCM: Hardware PCM card 1 ‘jetson-xaviernx-ape’ device 0 subdevice 0
Its setup is:
stream : CAPTURE
access : RW_INTERLEAVED
format : S16_LE
subformat : STD
channels : 2
rate : 48000
exact rate : 48000 (48000/1)
msbits : 16
buffer_size : 8192
period_size : 2048
period_time : 42666
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 2048
period_event : 0
start_threshold : 1
stop_threshold : 8192
silence_threshold: 0
silence_size : 0
boundary : 4611686018427387904
appl_ptr : 0
hw_ptr : 0

and the result of aplay -v is as following:
Playing WAVE ‘nanerdangziqiang-16bit.wav’ : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
Plug PCM: Rate conversion PCM (48000, sformat=S16_LE)
Converter: libspeex (external)
Protocol version: 10002
Its setup is:
stream : PLAYBACK
access : RW_INTERLEAVED
format : S16_LE
subformat : STD
channels : 2
rate : 44100
exact rate : 44100 (44100/1)
msbits : 16
buffer_size : 7526
period_size : 1881
period_time : 42666
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 1881
period_event : 0
start_threshold : 7526
stop_threshold : 7526
silence_threshold: 0
silence_size : 0
boundary : 4236761349448794112
Slave: Hardware PCM card 1 ‘jetson-xaviernx-ape’ device 0 subdevice 0
Its setup is:
stream : PLAYBACK
access : MMAP_INTERLEAVED
format : S16_LE
subformat : STD
channels : 2
rate : 48000
exact rate : 48000 (48000/1)
msbits : 16
buffer_size : 8192
period_size : 2048
period_time : 42666
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 2048
period_event : 0
start_threshold : 8192
stop_threshold : 8192
silence_threshold: 0
silence_size : 0
boundary : 4611686018427387904
appl_ptr : 0
hw_ptr : 0

These devices are same. It is jetson-xaviernx-ape.

The asound.conf is linked to asound.conf.jetsonxaviernxape
asound.conf → /etc/asound.conf.jetsonxaviernxape

The content of asound.conf.jetsonxaviernxape is as the attachment.
asound.conf.jetsonxaviernxape (1.4 KB)

BTW: the record and playback are executed at the same time.

Anybody here?

Hello!

Apologies for the delay. When using arecord without specifying the “-D hw:jetsonxaviernxa,0” it will use the plughw plugin …

ubuntu@jetson:~$ arecord -v -r 48000 -c 2 -d 10 cap.wav
Recording WAVE 'cap.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Plug PCM: Hardware PCM card 1 ‘jetson-xaviernx-ape’ device 0 subdevice 0

This is the same as …

ubuntu@jetson:~$ arecord -v -D plughw:jetsonxaviernxa,0 -r 48000 -c 2 -d 10 cap.wav
Recording WAVE 'cap.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Plug PCM: Hardware PCM card 1 ‘jetson-xaviernx-ape’ device 0 subdevice 0

And if you use “-D hw:jetsonxaviernxa,0” then it will not …

ubuntu@jetson:~$ arecord -v -D hw:jetsonxaviernxa,0 -r 48000 -c 2 -d 10 cap.wav
Recording WAVE 'cap.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Hardware PCM card 1 ‘jetson-xaviernx-ape’ device 0 subdevice 0

Can you confirm that “arecord -v -D plughw:jetsonxaviernxa,0 -r 48000 -c 2 -d 10 cap.wav” does not work?

Can you try adding the following to your /etc/asound.conf?

pcm.plug0 {
  type plug
  slave {
    pcm "hw:jetsonxaviernxa,0"
  }
}

Regards,
Jon

Dear sir:

When i run the command “arecord -v -D plughw:jetsonxaviernxa,0 -r 48000 -c 2 -d 10 cap.wav”, the message is as following. The cap.wav is noise. There is no any sound in it.

root@tegra-ubuntu:/home/ubuntu# arecord -v -D plughw:jetsonxaviernxa,0 -r 48000 -c 2 -d 10 cap.wav
Recording WAVE ‘cap.wav’ : Unsigned 8 bit, Rate 48000 Hz, Stereo
Plug PCM: Linear conversion PCM (S8)
Its setup is:
stream : CAPTURE
access : RW_INTERLEAVED
format : U8
subformat : STD
channels : 2
rate : 48000
exact rate : 48000 (48000/1)
msbits : 8
buffer_size : 16384
period_size : 4096
period_time : 85333
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 4096
period_event : 0
start_threshold : 1
stop_threshold : 16384
silence_threshold: 0
silence_size : 0
boundary : 4611686018427387904
Slave: Hardware PCM card 1 ‘jetson-xaviernx-ape’ device 0 subdevice 0
Its setup is:
stream : CAPTURE
access : MMAP_INTERLEAVED
format : S8
subformat : STD
channels : 2
rate : 48000
exact rate : 48000 (48000/1)
msbits : 8
buffer_size : 16384
period_size : 4096
period_time : 85333
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 4096
period_event : 0
start_threshold : 1
stop_threshold : 16384
silence_threshold: 0
silence_size : 0
boundary : 4611686018427387904
appl_ptr : 0
hw_ptr : 0

Dear sir :

after add the following in asoud.conf, it is ok, tks!

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