The imx8mp configuration i2s slave mode is abnormal

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

The imx8mp configuration i2s slave mode is abnormal

1,151 Views
yzg
Contributor I

Hello:

I encountered the following problems when recording with imx8mp:

Kernel version: Linux imx8mpevk 5.15.71

I configured sai3 as slave i2s mode. The following is a screenshot of some codes

yzg_0-1694571704027.png

yzg_1-1694571710895.pngyzg_2-1694571717380.pngyzg_3-1694571723316.png

When I execute arecord -f dat > test.wav command, theoretically should record sample rate 48000, but params_rate(params); This kernel interface always returns 44100, the sound I am recording is distorted, I suspect it is partly caused by this, please help to analyze the reason

yzg_4-1694571741041.png

 

Labels (1)
0 Kudos
Reply
2 Replies

1,090 Views
Zhiming_Liu
NXP TechSupport
NXP TechSupport

Hi @yzg 

Please check below code in your kernel :

	if (format_is_dsd(params)) {
		/* Use the maximum freq from DSD512 (512*44100 = 22579200) */
		if (!(params_rate(params) % 11025))
			mclk_freq = IMX_CARD_MCLK_22P5792MHZ;
		else
			mclk_freq = IMX_CARD_MCLK_24P576MHZ;
	}
0 Kudos
Reply

1,045 Views
yzg
Contributor I
Hi,
I didn't enter this judgment statement. I'm not in dsd mode
0 Kudos
Reply