iMX7 I2S playback in Slave mode

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

iMX7 I2S playback in Slave mode

1,226 Views
kwelsh
Contributor I

I would like to put the iMX7 into I2S slave mode for 2 channel playback. The codec we are developing will send BCLK & LRCLK.(We can send MCLK if needed, but I hope it is not)

I saw another post that asked about this diagram:

i.MX7_Slave.pngand it seems the answer was that the left side is valid.

My confusion is that the iMX Pin Tool seems to indicate that the sai_tx_bclk is Output only? Is that right? Am I misreading this:

The iMX7D Reference Manual says it is I/O. But that manual also says that MCLK is I/O, and I heard that it is not, so I'm not sure if the docs are accurate.

I also read in another post that the iMX7 SABRE used the iMX in I2S Slave mode, and the codec in master mode, but the schematic below doesn't seem to show that:

So, my ultimate questions are:

Can I send BCLK and LRCLK into the iMX7D and get DOUT output?

If it can, can someone point me to instruction on how to configure the iMX7 to do this? (I will be using a modern Linux kernel)

Labels (3)
Tags (3)
0 Kudos
2 Replies

879 Views
igorpadykov
NXP Employee
NXP Employee

Hi Kevin

yes iMX7D BCLK and LRCLK can be inputs, configured with bit BCD register

I2Sx_TCR2,  bit FSD register I2Sx_TCR4, detailed description is given in

sect.13.8.3.1.2 Bit clock i.MX7D Reference Manual

http://cache.nxp.com/files/32bit/doc/ref_manual/IMX7DRM.pdf

may be useful to check driver linux/sound/soc/fsl/fsl_sai.c

fsl_sai.c\fsl\soc\sound - linux-imx - i.MX Linux kernel 

sai dts examples

imx7d-sdb.dts\dts\boot\arm\arch - linux-imx - i.MX Linux kernel 

imx7d-pico.dts\dts\boot\arm\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

879 Views
gonewithwind-peter
Senior Contributor I

do you have the patch for i2s slave mode(fs and clock as input pin) for file fsl_sai.c ? or the patch for dts?

Thanks

0 Kudos