IMX8QM ESAI0 EXTAL MCLK

cancel
Showing results for 
Search instead for 
Did you mean: 

IMX8QM ESAI0 EXTAL MCLK

214 Views
dhty2015
Contributor II

我现在使用imx8qmCPU,当前使用ESAI0主模式tdm模式驱动8声道声卡。我的dts中:

&esai0 {
compatible = "fsl,imx8qm-esai";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_esai0>;
assigned-clocks = <&clk IMX8QM_ACM_ESAI0_MCLK_SEL>,
<&clk IMX8QM_AUD_PLL0_DIV>,
<&clk IMX8QM_AUD_ACM_AUD_PLL_CLK0_DIV>,
<&clk IMX8QM_AUD_ACM_AUD_REC_CLK0_DIV>,
<&clk IMX8QM_AUD_ESAI_0_EXTAL_IPG>;
assigned-clock-parents = <&clk IMX8QM_AUD_ACM_AUD_PLL_CLK0_CLK>;
assigned-clock-rates = <0>, <786432000>, <49152000>, <12288000>, <49152000>;
fsl,txm-rxs;
status = "okay";
};

我音频为48K采样率,32位深,8声道。所以我需要24576000的MCLK输出。

现在问题是:

当前EXTAL频率为49152000,需要进行2分频作为输出。但是

NOTE: Do not use the combination TPSR = 1 and TPM7-RPM0 = 0x00, which causes synchronization

problems when using the internal core clock as source (THCKD = 1 or TCKD = 1).

TPSR无法和TPM=0且MCLK为输出时共存,导致无法对EXTAL二分频。

请问:

如何使用EXTAL二分频作为MCLK;

如何修改EXTAL为其他频率比如24576000或者98304000

多谢!

0 Kudos
1 Reply

176 Views
igorpadykov
NXP TechSupport
NXP TechSupport

Hi dhty2015

for esai mclk clock change one can look at

ESAI peripheral generating incorrect I2S frequencies 

pay attention to esai clocks:

assigned-clock-rates = <0>, <786432000>, <49152000>, <12288000>, <49152000>;

fsl-imx8qm-mek.dtsi\freescale\dts\boot\arm64\arch - linux-imx - i.MX Linux kernel 

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos