Figure 447. Data Companding Hardware In An Audio Block In The Sai - ST STM32L4x6 Reference Manual

Table of Contents

Advertisement

Serial audio interface (SAI)
input line (expansion) as illustrated in
are the µ-Law and the A-Law log which are a part of the CCITT G.711 recommendation.
The companding standard used in the United States and Japan is the µ-Law. It supports 14
bits of dynamic range (COMP[1:0] = 10 in the SAI_xCR2 register).
The European companding standard is A-Law and supports 13 bits of dynamic range
(COMP[1:0] = 11 in the SAI_xCR2 register).
Both µ-Law or A-Law companding standard can be computed based on 1's complement or
2's complement representation depending on the CPL bit setting in the SAI_xCR2 register.
In µ-Law and A-Law standards, data are coded as 8 bits with MSB alignment. Companded
data are always 8-bit wide. For this reason, DS[2:0] bits in the SAI_xCR1 register will be
forced to 010 when the SAI audio block is enabled (bit SAIXEN = 1 in the SAI_xCR1
register) and when one of these two companding modes selected through the COMP[1:0]
bits.
If no companding processing is required, COMP[1:0] bits should be kept clear.
1. Not applicable when AC'97 or SPDIF are selected.
Expansion and compression mode are automatically selected through the SAI_xCR2:
If the SAI audio block is configured to be a transmitter, and if the COMP[1] bit is set in
the SAI_xCR2 register, the compression mode will be applied.
If the SAI audio block is declared as a receiver, the expansion algorithm will be applied.
Output data line management on an inactive slot
In transmitter mode, it is possible to choose the behavior of the SD line output when an
inactive slot is sent on the data line (via TRIS bit).
Either the SAI forces 0 on the SD output line when an inactive slot is transmitted, or
The line is released in HI-z state at the end of the last bit of data transferred, to release
the line for other transmitters connected to this node.
1338/1693

Figure 447. Data companding hardware in an audio block in the SAI

DocID024597 Rev 3
Figure
447.
The two companding modes supported
RM0351

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM32L4x6 and is the answer not in the manual?

Questions and answers

Table of Contents

Save PDF