cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H757: TDM slots and bit depth over SAI interface

Zipper
Associate

I'm working on a device that requires requires 12 audio output channels and 10 input channels. I wish to do this over 16-slot TDM. Now, I'm concerned about whether this can be done with 32 bits per sample. The reference manual states in section 54.4.6 Frame synchronization "The audio frame length can be configured to up to 256 bit clock cycles". 256/16=16. Does this mean I can only do 16-bit audio with 16-slot TDM? Or did I misread.

2 REPLIES 2
waclawek.jan
Super User

> Does this mean I can only do 16-bit audio with 16-slot TDM?

Yes (see e.g. page 9 here).

OTOH, the role of "frame" in this case is only to provide a frame-sync signal to the slave(s).  So you can ignore the "native" FS signal, and generate your own, e.g. by using one extra SAI data output with appropriately crafted data, or by linking the SAI clock to timers and generate the framing signal there (you did not tell us which 'H7, but in some of them there is an internal link from SAI_FS to ETR of some of the timers, and that perhaps can be utilized - if not, pins can be connected externally). Not something which can be easily clicked in CubeMX, though.

JW

I intend to use the STM32H747/757 or the STM32H745/755. I need the following I/O:

  • TDM 8-channel input
  • I2S stereo duplex
  • I2S stereo output (although I do have a stereo DAC that takes TDM as well)

Would it be possible to synchronize I2S SAIs with an TDM one? AFAIK to synchronize SAIs you need to match frame sync and bit clock.