cancel
Showing results for 
Search instead for 
Did you mean: 

Sources which generate SAI_CK_A on STM32F7?

disp1_st
Associate
Posted on September 12, 2016 at 04:31

The problem is that I have an *external* 24.576 MHz MCLK.  In master mode, how do I get that from outside the chip onto the SAI_CK_A or SAI_CK_B clock?

I was going through section 36.3.1 ''SAI block diagram'' and figuring out how to wire everything up.

If the STM32F7 is a slave, things mostly make sense: SCK maps to BCLK, FS maps to FCLK or LRCLK, SD maps to data.  Presumably, MCLK is ignored--that's a little scary but I guess it could work given that the audio block has FIFOs.

If the STM32F7 is a master *AND* generates the clock, then things are perfectly straightforward: MCLK is generated and maps to MCLK, SCK maps to BCLK, FS maps to FCLK or LRCLK, SD maps to data. 

The reference manual mumbles in section 36.3.7:

The clock source for the clock generator comes from the product clock controller. 

Okaaaay.  I don't see anything in the manual about an SAI product clock controller.  Nothing is listed which directly drives SAI_CK_x in Figure 429.

Any help would be appreciated.

Thanks.

#sai-mclk-m7-stm32f7
2 REPLIES 2
Posted on September 12, 2016 at 12:05

> The problem is that I have an *external* 24.576 MHz MCLK.  In master mode, how do I get that from outside the chip onto the SAI_CK_A or SAI_CK_B clock?

You don't need to. The high-frequency ''master'' clocks in codecs drive the oversampled sampler and filters; they are not needed to transfer data.

> The reference manual mumbles in section 36.3.7:

> The clock source for the clock generator comes from the product clock controller. 

It's a bad way to say ''clock comes from RCC''.

JW

PS. When referring to RM, post number of RM and revision - note that there are several different RMs for various groups of STM32F7.

disp1_st
Associate
Posted on September 12, 2016 at 22:38

Oh, thanks for the reference.

But, crud, the only pin to run an external MCLK seems to be I2S_CKIN and that is attached to exactly one and only one pin on the TQFP144.  And that's being used by my sdcard interface (Figure 12-page 150).  Erm.  Guess I'm going to be trying to run the STM32F7 in slave mode then.

Thanks for the pointers though.

Relevant Reference manual ID:

DocID028270 Rev 2