I have question with tx2 sound setting .
but i have some of problems.
speaker is not work
amixer -c 1 sset ‘I2S1 Mux’ ‘ADMAI1’
is works well .
but My goal is GPIO → i2s2 → TX2 → I2S1 → codec → speaker.
amixer -c 1 sset ‘I2S1 Mux’ ‘I2S2’
i setted like this and data is coming and check by scope. but speaker is not work.
but I2S_SIN data is work and pass to audio codec but I2S LRCLK freq 67,20 khz… but i tried setting 48khz
i think that i need more setting but i cant find what is.
but recording is works
dear kayccc
i have another question … can i force to enable I2S1?
because I2S2 record is works but speaker sound doesnt work.
i testing sound command and it is can hear something.
Please confirm if I2S1 and I2S2 are working fine individually before trying I2S2->I2S1 usecase
i.e
1)If recorded data is clean in I2S2->ADMAIF2 usecase
amixer -c 1 sset “ADMAIF2 Mux” “I2S2”
arecord -D hw:1,1 -f S16_LE -t wav -r 48000 test.wav
BCLK, LRCK should be ~1536000 and ~48000 respectively for the given usecase
2)If playback data with appropriate codec mixer settings in addition to below path setup is working fine
amixer -c 1 sset ‘I2S1 Mux’ ‘ADMAIF1’
aplay -D hw:1,0 some_48k_16LE_stereo.wav
NOTE: MCLK for ALC5633 should be 256fs or 384fs i.e 12.28 MHz or 18.432MHZ as per datasheet.
Individual playback would have failed if MCLK is not set as per datasheet guideline. Please correct this and see if it helps.
BCLK, AUD_MCLK, LRCK should be ~1536000, ~12288000 and ~48000 respectively for the given usecase
3)If both are working fine individually, I2S2->I2S1 usecase can be attempted. Ensure that both i2s are configured for similar audio parameters in DT.
Apart from providing status of each of the above usecase, provide the clock summary (cat /sys/kernel/debug/clk/clk_summary)
and rates observed @ BCLK, LRCK and AUD_MCLK during 1) playback alone and 2) capture alone and 3) during I2S2->I2S1 usecase to check this further
i checked I2S1 and I2S2 indiviually
and 'arecord -D hw:1,1 -f S16_LE -t wav -r 48000 test.wav ’ have same problem. sound is same as I2S1 waves.
BCLK, LRCK is 1536000 and 48k
knocking door sound and it likes noisy
MCLK setted 256, and both have same values.
and i checked clocks and BCLK, AUD_MCLK, LRCK is good .
/sys/kernel/debug/clk/clk_summary is i2s1, i2s2 is same and 1536000.
I think 1 is problem and i checked and changed pinctrl too but not changed.
From above comment clocks look good. The recorded wav file (test.wav) in I2S2->ADMAIF2 path is having issue i.e noisy.
Can you elaborate on the capture path connection (i.e GPIO → I2S2) i.e the source of I2S2 (BCLK, LRCK, Data IN) lines to understand this further.
Also, play some clean file on I2S1 and confirm if its playing fine on ALC5633 codec. From previous comment, its not clear if I2S1 is working fine individually.
I2S1 is good and we used that before and tested a lot. And checking 44.1 khz and 48 khz too.
GPIO line is external devices issues and they are solved now.
I checked lines of I2S2 BCLK, LRCK, Data IN signals
(R1001, R1002[not use] , R1003, R1004)
i want to makes I2S2 Data in and I2S1 Out signals same.
noise is not problem now.
Thanks for confirming playback path has no issues. Suspecting that I2S2 is set in master mode (i.e cbs-cfs) where Jetson I2S2 would be generating the bitclock and might be causing misallignment.
We suggest to try capture with below setting. This will set I2S2 in slave mode so that it receives bit clock and frame clock from external device and may avoid noise in recorded audio. Ensure external blck and lrck is getting generated during the below capture
amixer -c 1 cset name==“I2S2 codec master mode” “cbm-cfm”
amixer -c 1 sset ‘ADMAIF2 Mux’ ‘I2S2’
arecord -D hw:1,1 -f S16_LE -t wav -r 48000 test.wav
Hi nkw3000,
Above observation confirms that external LRCK/BCLK are not functional. So, let the Jetson I2S operate in master mode (cbs-cfs).
Before we send data from I2S2 to I2S1 via gst, We ned to ensure I2S2 capture is clean. In the earlier comments, you have provided circuitry for I2S2 DIN connection.
It seems to be connected to other pin. But source for this pin is not clear. What device is connected to these GPIO lines that are connected to I2S2.
Is there any datasheet for this device that records data and passes to I2S2 via the GPIO lines. Please share the detail as external configuration might be causing issue.
Hi atalambedu
I sorry to confuse that.
GPIOs are External devices’s pin and they can be multi purpose and External device I2S signals are pass through to I2S2 pins. I already compared I2S2 SDIN signals and that is first screenshot.
i got something wrong with I2S2 capture.
I2S2’s input signal is different with normal I2S1’s signal when 48k wav is play.
so I asked hw and waiting answer.
Thanks!
From your comments I inferred that I2S2 DIN is receiving fine but I2S2 FS and I2S2 SCLK are not getting fed by external device. Tell me if my understanding is correct with yes/no
Above are the correct pinmux settings for I2S2 to receive clock from external device.
No need to override them with 0
b) Ensure that Jetson I2S2 is set as slave i.e external device as master with below setting
amixer -c 1 cset name==“I2S2 codec master mode” “cbm-cfm”
This is because external device is supplying clock
and let us know if captured data with script below on I2S2 is clean with yes/no
amixer -c 1 sset ‘ADMAIF2 Mux’ ‘I2S2’
arecord -D hw:1,1 -f S16_LE -t wav -r 48000 test.wav
“Only if I2S2 captured data is clean”, try I2S2 to I2S1
Share observations if this fails
Please answer each question separately and number the answers for us to understand better