There are two different modes for frame sync: burst and TDM. The MCASP frame sync generator logic is illustrated in Figure 12-14.The I/O buffers are not part of the MCASP module, and are not shown in the figure.
Note: For more on MCASP integration, see Section 12.1.1.2, MCASP Environment, and Module Integration.
For the transmit logic, following frame-sync generator configurations can be selected:
- Internally/externally generated frame-sync via configuring MCASP_AFSXCTL[1] FSXM bit
- Frame-sync polarity: Rising edge or falling edge via configuring MCASP_AFSXCTL[0] FSXP bit
- Frame-sync width: "single bit" or "single word" via configuring MCASP_AFSXCTL[4] FXWID bit
- Frame sync mode - the appropriate frame sync generation pattern for the selected transfer mode is defined in the MCASP_AFSXCTL[15-7] XMOD bit field, as follows:
- For DIT mode (384 slots) - MCASP_AFSXCTL[15-7] XMOD = 0x180
- For I2S mode (2 TDM slots) - MCASP_AFSXCTL[15-7] XMOD = 0x2
- For TDM mode (from 3 to 32 TDM slots) - MCASP_AFSXCTL[15-7] XMOD bit field set in range 0x3 - 0x20
- Bit delay: 0, 1, or 2 cycles before the first data bit. This delay is defined in MCASP_XFMT[17-16] XDATDLY bit field
For the receive logic, following frame-sync generator configurations can be selected:
- Internally/externally generated frame-sync via configuring MCASP_AFSRCTL[1] FSRM bit
- Frame-sync polarity: Rising edge or falling edge via configuring MCASP_AFSRCTL[0] FSRP bit
- Frame-sync width: "single bit" or "single word" via configuring MCASP_AFSRCTL[4] FRWID bit
- Frame sync mode - the appropriate frame sync generation pattern for the selected transfer mode is defined in the MCASP_AFSRCTL[15-7] RMOD bit field, as follows:
- For I2S mode (2 TDM slots) - MCASP_AFSRCTL[15-7] RMOD = 0x2
- For TDM mode (from 3 to 32 TDM slots) - MCASP_AFSRCTL[15-7] RMOD set in range 0x3 - 0x20
- For the special 384-slot TDM mode - MCASP_AFSRCTL[15-7] RMOD = 0x180
- Bit delay: 0, 1, or 2 cycles before the first data bit. This delay is defined in the MCASP_RFMT[17-16] RDATDLY bit field
- Selecting the source (AFSX or AFSR) of receiver
internal frame synchronization. This is done in the same bit -
MCASP_ACLKXCTL[6] ASYNC, used to define the receiver internal
clock source. For more details, refer to Section 12.1.1.4.2.4, Synchronous and Asynchronous Transmit and Receive
Operations.
Regardless of the AFSX/AFSR being internally generated or externally sourced, the polarity of AFSX/AFSR is determined by FSXP/FSRP, respectively, to be either rising or falling edge. If FSXP/FSRP = 0, the frame sync polarity is rising edge. If FSXP/FSRP = 1, the frame sync polarity is falling edge.
Note: Certain restrictions apply to the receive and
transmit logic settings, when the MCASP_ACLKXCTL[6] ASYNC bit is set to
0b0. They are described in Section 12.1.1.4.2.4.