- All features specified for Layer III in ISO/IEC
11172-3(MPEG 1 Audio)
- All features specified for Layer III in ISO/IEC
13818-3.2(MPEG 2 Audio)
- Lowersamplingfrequenciessyntaxextension,
(notspecifiedby ISO) called MPEG2.5
DECODES LAYER III STEREO CHANNELS,
DUALCHANNEL,SINGLECHANNEL
(MONO)
SUPPORTING ALL THE MPEG 1 & 2 SAMPLING FREQUENCIES AND THE EXTENSION TO MPEG 2.5:
48, 44.1, 32, 24, 22.05, 16, 12, 11. 025, 8 KHz
ACCEPTS MPEG 2.5 LAYER III ELEMENTARY COMPRESSED BITSTREAM WITH
DATA RATE FROM 8 Kbit/s UP TO 320 Kbit/s
DIGITALVOLUMECONTROL
DIGITALBASS& TREBLECONTROL
SERIALBITSTREAMINPUTINTERFACE
ANCILLARY DATA EXTRACTIONVIA I2C IN-
TERFACE.
SERIAL PCM OUTPUT INTERFACE (I
AND OTHERFORMATS)
PLL FOR INTERNAL CLOCK AND FOR OUT-
PUT PCMCLOCK GENERATION
LOW POWERCONSUMPTION:
85mW AT 2.4V
CRC CHECK AND SYNCHRONISATION ER-
ROR DETECTION WITH SOFTWARE INDICATORS
2
C CONTROLBUS
I
LOW POWER3.3V CMOSTECHNOLOGY
10 MHz, 14.31818 MHz, OR 14.7456 MHz
EXTERNAL INPUT CLOCK OR BUILT-IN INDUSTRY STANDARD XTAL OSCILLATOR
DIFFERENT FREQUENCIES MAY BE SUPPORTED UPON REQUESTTOSTM
APPLICATIONS
PC SOUNDCARDS
MULTIMEDIA PLAYERS
STA013BSTA013T
SO28
TQFP44
LFBGA64
2
S
ORDERING NUMBERS: STA013$ (SO28)
STA013T$ (TQFP44)
STA013B$ (LFBGA 8x8)
DESCRIPTION
The STA013 is a fully integrated high flexibility
MPEG Layer III Audio Decoder, capable of decoding Layer III compressedelementary streams,
as specifiedin MPEG1 and MPEG 2 ISO standards. The devicedecodes alsoelementarystreams
compressedby using low samplingrates,as specifiedbyMPEG2.5.
STA013 receives the input data through a Serial
Input Interface. The decoded signal is a stereo,
mono, or dual channel digital output that can be
sent directly to a D/A converter, by the PCM Output Interface. This interface is software programmable to adapt the STA013 digital output to the
most common DACs architectures used on the
market.
The functional STA013 chip partitioning is describedin Fig.1.
Power Supply-0.3 to 4V
Voltage on Input pins-0.3 to VDD+0.3V
Voltage on output pins-0.3 to VDD+0.3V
Storage Temperature-40 to +150°C
Operative ambient temp-20 to +85°C
129B5VDD_1Supply Voltage
230B4VSS_1Ground
331A4SDAI/Oi
432B3SCLII
534A1SDIIReceiver Serial DataCMOS Input Pad Buffer
636B2SCKRIReceiver Serial ClockCMOS Input Pad Buffer
738D4BIT_ENIBit EnableCMOSInputPad Buffer
840D1SRC_INTIInterrupt Line For S.R. ControlCMOS Input Pad Buffer
942E2SDOOTransmitter SerialData (PCM
1044F2SCKTOTransmitter Serial ClockCMOS 4mA Output Drive
112H1LRCKTOTransmitter Left/Right ClockCMOS 4mA Output Drive
123H3OCLKI/OOversampling Clock for DACCMOS Input Pad Buffer
135F3VSS_2Ground
146E4VDD_2Supply Voltage
157G4VSS_3Ground
168G5VDD_3Supply Voltage
1710F5PVDDPLL Power
1811G6PVSSPLL Ground
1912G7FILTOPLL Filter Ext. Capacitor Conn.
2013G8XTOOCrystal OutputCMOS 4mA Output Drive
2115F7XTIICrystal Input (Clock Input)Specific Level Input Pad
2219E7VSS_4Ground
2321C8VDD_4Supply Voltage
2422D7TESTENITest EnableCMOSInputPad Buffer
2524A7SCANENIScan EnableCMOS Input Pad Buffer
2625B6RESETISystem ResetCMOSInputPad Buffer
2726A5VSS_5Ground
2827C5OUT_CLK/
DATA_REQ
Note: SRC_INT signal is used by STA013 internalsoftware inBroadcast Modeonly;in Multimedia mode SRC_INT must be connected to
In functionalmodeTESTEN must be connected to VDD,SCANEN to ground.
V
DD
2
C Serial Data + AcknowledgeCMOS Input Pad Buffer
CMOS 4mA Output Drive
2
C Serial ClockCMOS Input Pad Buffer
withpull up
CMOS 4mA Output Drive
Data)
CMOS 4mA Output Drive
(see paragraph 2.1)
withpull up
withpull up
OBuffered Output Clock/
CMOS 4mA Output Drive
Data Request Signal
4/38
STA013 - STA013B - STA013T
1. ELECTRICALCHARACTERISTICS:VDD=2.4V±0.3V;T
amb
= 0 to 70°C;Rg = 50Ωunlessotherwise
specified
DC OPERATINGCONDITIONS
SymbolParameterValue
V
T
Power Supply Voltage2.7 to 3.6V
DD
Operating Junction Temperature-20 to 125°C
j
GENERAL INTERFACE ELECTRICALCHARACTERISTICS
SymbolParameterTest ConditionMin.Typ.Max.UnitNote
I
IL
Low Level Input Current
Vi= 0V-1010µA1
Without pull-up device
I
IH
High Level Input Current
Vi=VDD= 3.6V-1010
A1
µ
Without pull-up device
V
esd
Note 1: The leakage currents are generally very small, < 1nA. The value given here is a maximum thatcan occur after an electrostatic stress
on the pin.
Note 2: Human Body Model.
Electrostatic ProtectionLeakage < 1µA2000V2
DC ELECTRICAL CHARACTERISTICS
SymbolParameterTest ConditionMin.Typ.Max.UnitNote
V
IL
V
IH
V
ol
V
oh
Low Level Input Voltage0.2*V
High Level Input Voltage0.8*VDDV
Low Level Output VoltageIol= Xma0.4VV1, 2
High Level Output Voltage0.85*V
DD
V
DD
V1,2
Note 1: Takes intoaccount 200mV voltage drop in both supply lines.
Note 2: X is the source/sink current under worst case conditions and is reflected in the name of the I/O cell according to the drive capability.
The STA013 input clock is derivated from an external source or from a industry standard crystal
oscillator, generating input frequencies of 10,
14.31818 or 14.7456 MHz.
Other frequencies may be supported upon request to STMicroelectronics. Each frequency is
supported by downloading a specific configuration file, providedby STM
XTI is an input Pad with specific levels.
SymbolParameterTest ConditionMin.Typ.Max.Unit
V
IL
V
IH
Low Level Input VoltageVDD-1.8V
High Level Input VoltageVDD-0.8V
CMOS compatibility
The XTI pad low and high levels are CMOS compatible; XTI pad noise margin is better than typical
CMOS pads.
TTL compatibility
The XTI padlow levelis compatiblewith TTL while the high level is not compatible(for example if V
DD =
3V TTL min high level = 2.0V whileXTI min high level = 2.2V)
6/38
Figure 5. MPEG DecoderInterfaces.
STA013 - STA013B - STA013T
µP
DATA_REQ
SDI
DATA
SOURCE
D98AU912
SCKR
BIT_EN
Figure 6. SerialInput Interface Clocks
SDI
SCKR
SCKR
XTO
XTIFILT
PLL
MPEG
DECODER
SERIAL AUDIO INTERFACE
RXTX
IIC
SCLSDA
IIC
DATA IGNORED
SDO
SCKT
LRCKT
DAC
OCLK
SCLK_POL=0
SCLK_POL=4
BIT_EN
D98AU968A
2.2 - SerialInput Interface
STA013 receives the input data (MSB first)
thought the Serial Input Interface (Fig.5). It is a
serial communication interface connected to the
SDI (Serial Data Input) and SCKR (Receiver Serial Clock).
The interface can be configured to receive data
sampled on both rising and falling edge of the
SCKR clock.
The BIT_EN pin, when set to low, forces the bitstream input interface to ignore the incoming
N
data. For proper operation Bit-E
line shold be
toggled only when SCR is stable low (for both
SCLK_POL configuration) The possible configurations are described in Fig. 6.
DATA IGNOREDDATA VALID
2.3 - PLL& ClockGeneratorSystem
When STA013 receives the input clock, as described in Section 2.1, and a valid layer III input
bit stream, the internal PLL locks, providing to the
DSP Core the master clock (DCLK), and to the
Audio Output Interface the nominal frequenciesof
the incoming compressedbit stream.The STA013
PLLblockdiagramisdescribedinFigure7.
The audio sample rates are obtained dividing the
oversampling clock (OCLK) by software programmable factors. The operation is done by STA013
embedded software and it is transparent to the
user.
The STA013 PLL can drive directly most of the
commercial DACs families, providing an over
sampling clock, OCLK, obtained dividingthe VCO
frequencywith a softwareprogrammabledividers.
7/38
STA013 - STA013B - STA013T
Figure 7. PLL and Clocks GenerationSystem
XTI
N
PFDCP
M
FRAC
Update FR AC
Switching
Circuit
2.4 - PCM Output Interface
The decoded audio data are output in serial PCM
format. The interface consists of the followingsignals:
SDOPCM SerialData Output
SCKTPCMSerial Clock Output
LRCLKLeft/RightChannel SelectionClock
The output samples precision is selectable from
Figure 8. PCM Output Formats
16 SCLK Cycles
LRCKT
16 SCLK Cycles
R
CC
VCO
Disable PLL
OCLK
X
XTI2OCLK
DCLK
S
XTI2DSPCLK
16 to 24 bits/word, by settingthe output precision
with PCMCONF (16, 18, 20 and 24 bits mode)
register. Data can be output either with the most
significant bit first (MS) or least significant bit first
(LS), selected by writing into a flag of the
PCMCONFregister.
Figure 8 gives a description of the several
STA013PCM Output Formats.
The sample rates set decoded by STA013 is describedin Table1.
16 SCLK Cycles
16 SCLK Cycles
16 SCLK Cycles
SDO
SDO
M
S
L
S
M
L
S
S
L
M
S
S
32 SCLK Cycles
LRCKT
SDO
SDO
SDO
SDO
M
L
S
S
M
0
S
L
M
0
S
S
M
S
32 SCLK Cycles
M
S
L
S
M
0
00
S
L
MSBMSBMSBMSB
S
Table 1: MPEG SamplingRates (KHz)
MPEG 1MPEG 2MPEG 2.5
482412
44.122.0511.025
32168
L
M
S
S
L
M
S
S
32 SCLK Cycles
M
L
S
S
M
L
S
S
PCM_ORD = 0
L
S
PCM_PRECis 16 bit mode
PCM_ORD = 1
M
S
PCM_PRECis 16 bit mode
32 SCLK Cycles
32 SCLK Cycles
L
00
S
L
M
S
S
L
S
L
M
S
S
L
M
S
S
M
00
S
M
0
S
MSL
M
0
L
S
L
00
S
S
L
S
S
M
0
S
L
M
0
S
S
M
S
PCM_FORMAT = 1
0
PCM_DIFF = 1
PCM_FORMAT = 0
L
S
PCM_DIFF = 0
PCM_FORMAT = 0
PCM_DIFF = 1
PCM_FORMAT = 1
L
S
PCM_DIFF = 1
8/38
STA013 - STA013B - STA013T
2.5 - STA013Operation Mode
The STA013 can work in two different modes,
called Multimedia Mode and BroadcastMode.
In Multimedia Mode, STA013 decodes the in-
coming bitstream, acting as a master of the data
communicationfrom the source to itself.
This control is done by a specific buffer management, controlled by STA013embeddedsoftware.
The data source, by monitoring the DATA_REQ
line, send to STA013 the input data, when the
signal ishigh (default configuration).
Thecommunication isstopped whenthe
DATA_REQline is low.
In this mode the fractional part of the PLL is disabled and the audio clocks are generated at
nominal rates. Fig. 9 describes the default
DATA_REQsignalbehaviour.
Programming STA013 it is possible to invert the
polarityoftheDATA_REQline(register
REQ_POL).
Figure 9.
SOURCE STOPS TRANSMITTING DATASOURCE STOPS TRANSMITTING DATA
DATA_REQ
SOURCE SEND DATA TO STA013
D98AU913
the configuration register of the device. The DAC
connected to STA013 can be initialised during
this mode (set MUTE to 1).
PLAYMUTEClock State PCM Output
X0Not Running0
X1Running0
Init Mode
”PLAY” and ”MUTE” changes are ignored in this
mode. The internal state of the decoder will be
updated only when the decoder changes from the
state ”init” to the state ”decode”. The ”init” phase
ends when the first decoded samples are at the
output stage of the device.
Decode Mode
This mode is completely described by the following table:
PLAYMUTE Clock State
00Not Running0No
01Running0No
10RunningDecoded
11Running0Yes
PCM
Output
Samples
Decoding
Yes
In Broadcast Mode, STA013 works receiving a
bitstream with the input speed regulated by the
source. In this configuration the source has to
guarantee that the bitrate is equivalent to the
nominal bitrate of the decoded stream.
To compensate the differencebetween the nominal and the real sampling rates, the STA013 embedded software controls the fractional PLL operation. Portable or Mobile applications need
normally to operate in Broadcast Mode. In both
modes the MPEG Synchronisation is automatic
and transparent to the user. To operate in Multimedia mode, the STA013, pin nr. 8, SCR-INT
must be connected to VDD on the application
board.
2.6 - STA013Decoding States
There are three different decoder states: Idle,
Init, and Decode. Commands to change the de-
coding states are described in the STA013 I
2
C
registers description.
Idle Mode
In this mode the decoder is waiting for the RUN
command. This mode should be used to initialise
3-I2C BUS SPECIFICATION
The STA013 supports the I
2
C protocol. This protocol defines any device that sends data on to the
bus as a transmitter and any device that reads
the data as a receiver. The device that controls
the data transfer is known as the master and the
others as the slave. The master always starts the
transfer and provides the serialclock forsynchronisation. The STA013 is always a slave device in
all its communications.
3. 1 - COMMUNICATIONPROTOCOL
3.1.0 - Data transition or change
Data changes on the SDA line must only occur
when the SCL clock is low. SDA transition while
the clock is high are used to identify START or
STOP condition.
3.1.1 - Start condition
START is identified by a high to low transition of
the data bus SDA signal while the clock signal
SCL is stable in the high state.
A START condition must precede any command
fordatatransfer.
9/38
STA013 - STA013B - STA013T
3.1.2 - Stop condition
STOP is identified by low to high transition of the
data bus SDA signal while the clock signal SCL is
stable in the high state. A STOP condition terminates communications between STA013 and the
bus master.
3.1.3 - Acknowledge bit
An acknowledgebit is used toindicate a successful data transfer. The bus transmitter, either master or slave, releases the SDA bus after sending
8 bit of data.
During the 9th clock pulse the receiver pulls the
SDA bus low to acknowledgethe receipt of 8 bits
of data.
3.1.4 - Data input
During the data input the STA013 samples the
SDA signal on the rising edge of the clock SCL.
For correct device operation the SDA signal has
to be stable during the rising edge of the clock
and the data can change only when the SCL line
is low.
3.2 - DEVICEADDRESSING
To start communication between the master and
the STA013, the master must initiate with a start
condition. Following this, the master sends onto
the SDA line 8 bits (MSB first) corresponding to
the device select address and read or write
mode.
Figure 10. Write Mode Sequence
The 7 most significant bits are the device address
identifier, corresponding to the I
2
C bus definition.
For the STA013these are fixed as 1000011.
The 8th bit (LSB) is the read or write operation
RW, this bit is set to 1 in read mode and 0 for
write mode. After a STARTcondition the STA013
identifies on the bus the device address and, if a
match is found, it acknowledgesthe identification
on SDA bus during the 9th bittime. The following
byte after the device identification byte is the internal space address.
3.3 - WRITEOPERATION(see fig. 10)
Following a START condition the master sends a
deviceselectcode with the RW bit set to 0.
The STA013 acknowledges this and waits for the
byte ofinternal address.
After receiving the internal bytes address the
STA013again responds with an acknowledge.
3.3.1 - Byte write
In the bytewrite mode the mastersends one data
byte, this is acknowledged by STA013. The master then terminates the transfer by generating a
STOP condition.
3.3.2 - Multibytewrite
The multibyte write mode can start from any internal address. The transfer is terminated by the
master generatinga STOPcondition.
BYTE
WRITE
MULTIBYTE
WRITE
START
STARTRW
DEV-ADDR
DEV-ADDR
Figure 11. Read Mode Sequence
ACK
CURRENT
ADDRESS
RANDOM
ADDRESS
SEQUENTIAL
CURRENT
SEQUENTIAL
RANDOM
10/38
READ
READ
READ
READ
DEV-ADDR
START
DEV-ADDR
STARTRW
START
STARTRW
DEV-ADDR
DEV-ADDR
RW=
HIGH
DATA
RW
ACK
SUB-ADDR
ACK
DATA
ACK
SUB-ADDR
ACK
RW
ACK
NO ACK
ACK
STARTRW
ACK
ACK
STARTRW
SUB-ADDR
SUB-ADDR
STOP
DATA
DEV-ADDR
DEV-ADDR
ACK
ACK
ACK
ACK
ACK
DATA IN
DATA IN
DATA
DATA
DATA
ACK
ACK
STOP
NO ACK
NO ACK
ACK
D98AU825B
STOP
STOP
DATA
DATA IN
ACK
ACKNO ACK
D98AU826A
STOP
DATA
STOP
STA013 - STA013B - STA013T
3.4 - READOPERATION(see Fig. 11)
3.4.1 - Currentbyte addressread
The STA013 has an internal byte address
counter. Each time a byte is written or read, this
counter is incremented.
For the current byte address read mode, following a START condition the master sends the device addresswith the RW bit setto 1.
The STA013 acknowledges this and outputs the
byte addressed by the internal byte address
counter. The master does not acknowledge the
received byte, but terminates the transfer with a
STOP condition.
3.4.2 - Sequentialaddress read
This mode can be initiated with either a current
address read or a random address read. However in this case the master does acknowledge
the data byte output and the STA013 continues to
output the next byte in sequence.
To terminate the streams of bytes the master
does not acknowledgethe last received byte, but
terminatesthe transfer with a STOP condition.
The output data stream is from consecutive byte
addresses, with the internal byte address counter
automaticallyincrementedafter one byte output.
2
4-I
C REGISTERS
The following table gives a description of the
MPEGSource Decoder (STA013)register list.
The first column (HEX_COD) is the hexadecimal
code for the sub-address.
The second column (DEC_COD) is the decimal
code.
The third column (DESCRIPTION) is the description of the informationcontained in the register.
The fourth column (RESET) inidicate the reset
value if any. When no reset value is specifyed,
the default is ”undefined”.
The fifth column (R/W) is the flag to distinguish
register ”read only” and ”read and write”, and the
useful size of the register itself.
Each register is 8 bitwide. The master shall operate readingor writing on 8 bits only.
1) The HEX_COD is the hexadecimal adress that the microcontroller has togenerate to access the information.
2) RESERVED: register used forproduction test only, or for future use.
12/38
STA013 - STA013B - STA013T
4.1 - STA013REGISTERS DESCRIPTION
The STA013 device includes 128 I
2
C registers.In
this document, only the user-oriented registers
are described. The undocumented registers are
reserved. These registers must never be accessed (in Read or in Write mode). The ReadOnly registers must never be written.
The following table describes the meaning of the
abbreviations used in the I
2
C registers descrip-
tion:
SymbolComment
NANot Applicable
UNDUndefined
NCNo Charge
RORead Only
WOWrite Only
R/WRead and Write
R/WSRead, Write in specific mode
VERSION
Address: 0x00
Type:RO
MSBLSB
b7b6b5b4b3b2b1b0
V8V7V6V5V4V3V2V1
The VERSION register is read-only and it is used
to identify the IC on the application board.
IDENT
Address: 0x01
Type:RO
SoftwareReset: 0xAC
Hardware Reset:0xAC
MSBLSB
b7b6b5b4b3b2b1b0
10101100
IDENT is a read-onlyregister and is used to identify the IC on an application board. IDENT always
has the value ”0xAC”
MSBLSB
b7b6b5b4b3b2b1b0
XTO_
XTODISOCLKENSYS2O
BUF
UPD_FRAC:
when is set to 1, update FRAC in
CLK
PPLDISXTI2DS
PCLK
XTI2O
CLK
UPD_F
RAC
the switching circuit. It is set to 1 afterautoboot.
XTI2OCLK:
when is set to 1, use the XTI as input
of the divider X insteadof VCO output. It is set to
0 on HW reset.
XTI2DSPCLK:
when is to 1, set use the XTI as input of the divider S instead of VCO output. It is
set to 0 on HW reset.
PLLDIS:
when set to 1, the VCO output is dis-
abled. It is set to 0 onHW reset.
SYS2OCLK:
when is set to 1, the OCLK frequency is equal to the system frequency. It is
useful for testing. It isset to 0 on HW reset.
OCLKEN:
when is set to 1, the OCLK pad is en-
able asoutput pad. It is set to 1 on HW reset.
XTODIS:
when is set to 1, the XTO pad is dis-
able. It is set to 0 on HW reset.
XTO_BUF:
when this bit is set, the pin nr. 28
(OUT_CLOCK/DATA_REQ) is enabled. It is set
to 0 afterautoboot.
The PLAY command is handled according to the
state of the decoder, as describedin section2.5.
PLAY only becomes active when the decoder is
in DECODEmode.
MSBLSB
b7b6b5b4b3b2b1b0
XXXX0000(1)
0001(2)
0010(3)
X = don’tcare
14/38
STA013 - STA013B - STA013T
MUTE
Address: 0x14
Type:R/W
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0
XXXXXXX0
1
X = don’tcare; 0 = normal operation;1 = mute
The MUTE command is handled according to the
state ofthe decoder,as describedin section2.5.
X = don’tcare;
0 = normal operation;
1 = write into I
2
C/Ancillary Data
The INTERRUPT is used to give STA013 the
command to write into the I2C/Ancillary Data
Buffer (Registers: 0x59 ... 0x5D). Every time the
Master has to extract the new buffer content (5
bytes) it writes into this register, setting it to a
non-zerovalue.
MSBLSB
b7b6b5b4b3b2b1b0Description
XXXXX0XXbuffered output clock
XXXXX1XXrequest signal
The DATA_REQ_ENABLE register is used to
configure Pin n. 28 working as buffered output
clock or data request signal, used for multimedia
mode.
The buffered Output Clock has the same fre-
quency than the input clock (XTI)
SYNCSTATUS
Address: 0x40
Type:RO
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0Description
XXXXXXSS1SS0
00Research of sync word
01Wait for Confirmation
10Synchronised
11not used
The HEAD registers can be viewed as logically
concatenatedto storethe MPEG Layer III Header
content. The set of three registers is updated
every time the synchronisation to the new MPEG
frameis achieved
16/38
STA013 - STA013B - STA013T
The meaning of the flags are shown in the following tables:
MPEG IDs
IDexID
00MPEG 2.5
01reserved
10MPEG 2
11MPEG 1
Layer
in Layer III thesetwo flags must be set always to
”01”.
Protection_bit
It equals ”1” if no redundancy has been added
and ”0” if redundancyhas been added.
Bitrate_index
indicates the bitrate (Kbit/sec) depending on the
MPEG ID.
These bits are used in joint stereo mode. They indicates which type of joint stereo coding method
is applied. The frequency ranges, over which the
intensity_stereo and ms_stereo modes are applied, are implicit in the algorithm.
Copyright
If this bit is equal to ’0’, there is no copyright on
the bitstream, ’1’ means copyrightprotected.
Original/Copy
This bit equals ’0’ if the bitstream is a copy, ’1’ if it
is original.
Emphasis
Indicates the type of de-emphasis that shall be
used.
Sampling Frequency
indicates the sampling frequency of the encoded
audio signal (KHz) dependingon the MPEGID
DRB registeris used to re-direct the RightChannel on the Left, or to mixboth the Channels.
MFSDF_441
Address: 0x50
Default value is 0x00, corresponding at the maximum attenuationin the re-directionchannel.
The VCO output frequency, when decoding
44.1KHzbitstream,is dividedby (MFSDF_441+1)
Type:R/W
SoftwareReset: 0x00
Hardware Reset:0x00
PLLFRAC_441_L
Address:0x51
Type: R/W
MSBLSB
b7b6b5b4b3b2b1b0
X X X M4M3M2M1M0
This register contains the value for the PLL X
driver for the 44.1KHz referencefrequency.
SoftwareReset: 0x00
Hardware Reset: 0x00
MSBLSB
b7b6b5b4b3b2b1b0
PF7PF6PF5PF4PF3PF2PF1PF0
19/38
STA013 - STA013B - STA013T
PLLFRAC_441_H
Address: 0x52
Type:R/W
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0
PF15 PF14 PF13 PF12 PF11 PF10 PF9PF8
PCMDIVIDER
Address:0x54
Type: RW
SoftwareReset: 0x03
Hardware Reset: 0x03
76543210
PD7PD6PD5PD4PD3PD2PD1PD0
PCMDIVIDER is used to set the frequency ratio
The registers are considered logically concatenated and contain the fractional values for the
PLL, for 44.1KHzreference frequency.
(see also PLLFRAC_L and PLLFRAC_H regis-
between the OCLK (Oversampling Clock for
DACs), and the SCKT (Serial Audio Transmitter
Clock).
The relation is the following:
ters)
SCKT_freq=
OCLK_freq
2 (1 + PCM_DIV)
The OversamplingFactor (O_FAC)is related to OCLK and SCKTby the following expression:
1) OCLK_freq= O_FAC* LRCKT_Freq
(DAC relation)
2) OCLK_Freq = 2 * (1+PCM_DIV)* 32*
LRCKT_Freq(when 16 bit PCMmode is used)
3) OCLK_Freq = 2 * (1+PCM_DIV)* 64*
LRCKT_Freq(when 32 bit PCMmode is used)
4) PCM_DIV= (O_FAC/64)- 1in 16 bit mode
5) PCM_DIV= (O_FAC/128)- 1 in 32 bit mode
Examplefor setting:
MSBLSB
b7b6b5b4b3b2b1b0Description
PD7PD6PD5PD4PD3PD2PD1PD0
0000011116bitmode512 x Fs
0000010116bitmode384 x Fs
0000001116bitmode256 x Fs
0000001132bitmode512 x Fs
0000001032bitmode384 x Fs
0000000132bitmode256 x Fs
XORDDIFINVFORSCLPREC(1) PREC(1)
X1PCM order the LS bit is transmitted First
X0PCM order the MS bit is transmitted First
X0The word is right padded
X1The word is left padded
X1LRCKT Polarity compliant to I2S format
X0LRCKT Polarity inverted
X0I2S format
X1Different formats
X1Data are sent on the rising edge of SCKT
X0Dataare sent onthe fallingedge of SCKT
X0016 bit mode (16 slots transmitted)
X0118 bit mode (18 slots transmitted)
X1020 bit mode (20 slots transmitted)
X1124 bit mode (24 slots transmitted)
PCMCONF is used to set the PCM Output Interface configuration:
ORD: PCM order. If this bit is set to’1’, the LS Bit
is transmittedfirst, otherwise MS Bit is transmiited
first.
DIF: PCM_DIFF. It is used to select the position
of the valid data into the transmitted word. This
setting is significant only in 18/20/24 bit/word
mode.If it is set to ’0’ the word is right-padded,
otherwise it is left-padded.
INV (fig.13): It is used to select the LRCKT clock
polarity. If it is set to’1’ thepolarity is compliant to
I2S format (low -> left , high -> right), otherwise
the LRCKT is inverted.The default value is ’0’. (if
I2S have to be selected, must be set to ’1’ in the
STA013configurationphase).
Figure 13. LRCKT Polarity Selection
rising edge of SCKTand sampled on the falling. If
set to ’0’ , the data are sent on the falling edge
and sampled on the rising. This last option is the
most commonly used by the commercial DACs.
The defaultconfigurationfor this flag is’0’.
Figure 14. SCKT Polarity Selection
SCKT
SDO
INV_SCLK=0
SCKT
SDO
INV_SCLK=1
LRCKT
LRCKT
left
left
right
right
left
leftINV_LRCLK=1
INV_LRCLK=0
FOR: FORMAT is used toselect the PCM Output
Interfaceformat.
After hwand sw reset the value is set to 0 corresponding to I
2
S format.
SCL (fig.14): used to select the Transmitter Serial
Clock polarity.If set to ’1’ the data are sent on the
PREC [1:0]: PCM PRECISION
It is used to select the PCM samples precision, as
follows:
’00’: 16 bit mode (16 slotstransmitted)
’01’: 18 bit mode (32 slotstransmitted)
’10’: 20 bit mode (32 slotstransmitted)
’11’: 24 bit mode (32 slotstransmitted)
The PCM samples precision in STA013 can be
16 or 18-20-24 bits.
When STA013 operates in 16 (18-20-24) bits
mode, the number of bits transmitted during a
LRCLT period is 32 (64).
21/38
STA013 - STA013B - STA013T
PCMCROSS
Address: 0x56
Type:R/W
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0Description
XXXXXX00Left channelis mappedon the left output.
XXXXXX01Left channel is duplicated on both Output channels.
XXXXXX10Right channel is duplicated on both Output channels
XXXXXX11Right and Left channels are toggled
The default configurationfor this register is ’0x00’.
Right channel is mapped on the Right output
ANCILLARYDATA BUFFER
Address: 0x59 - 0x5D
Type:RO
SoftwareReset: 0x00
Hardware Reset:0x00
STA013 can extract max 56 bytes/MPEG frame.
To know the number of A.D. bits available every
MPEG frame, the ANCCOUNT_L and ANCCOUNT_H registers (0x41 and 0x42) have to be
read.
The buffer dimension is 5 bytes, written by
STA013 core in sequential order. The timing information to read the buffer can be obtained by
reading the FRAME_CNT registers(0x67 - 0x69).
To fill up the buffer with a new 5-bytes slot, the
STA013 waits until a CMD_INTERRUPT register
is writtenby themaster.
MFSDF (X)
Address: 0x61
Type:R/W
SoftwareReset: 0x07
Hardware Reset:0x07
MSBLSB
b7b6b5b4b3b2b1b0
X X X M4M3M2M1M0
The register contains the values for PLL X divider
(see Fig. 7).
The value is changed by the internal STA013
Core, to set the clocks frequencies, according to
the incoming bitstream. This value can be even
set by the user to select the PCM interface configuration.
The VCO output frequencyis dividedby (X+1).
This registeris a referencefor 32KHz and 48 KHz
input bitstream.
DAC_CLK_MODE
Address:0x63
Type: RW
SoftwareReset: 0x00
Hardware Reset: 0x00
MSBLSB
b7b6b5b4b3b2b1b0
XXXXXXXMODE
This register is used to select the operating mode
for OCLK clock signal.
If it is set to ’1’, the OCLK frequency is fixed, and
it is mantained to the value fixed by theuser even
if the sampling frequency of the incoming bitstream changes.
It the MODE flag is set to ’0’, the OCLK frequency
changes, and can be set to (512, 384, 256) * Fs.
The default configuration for this mode is 256 *
Fs.
When this mode is selected, the default OCLK
frequency is 12.288MHz.
The registers are considered logically concatenated and contain the fractional values for the
PLL, used to select the internal configuration.
After Reset, the values are NA, and the operational setting are done when the MPEG synchronisation is achieved.
The following formula describes the relationships
among all the STA013 fractional PLL parameters:
OCLK_Freq =
X + 1
1
MCLK_freq
⋅
N + 1
⋅
M + 1 +
FRAC
65536
where:
FRAC=256x FRAC_H + FRAC_L(decimal)
These registers are a reference for 48 / 24 / 12 /
32 / 16 / 8KHz audio.
FRAME_CNT_H
MSBLSB
b7b6b5b4b3b2b1b0
FC23 FC22 FC21 FC20 FC19 FC18 FC17 FC016
Address:0x67, 0x68, 0x69
Type: RO
SoftwareReset: 0x00
Hardware Reset: 0x00
The three registers are considered logically concatenated and compose the Global Frame
Counter as describedin the table.
It is updated at every decoded MPEG Frame.
The registers are reset on both hardware and
software reset.
AVERAGE_BITRATE
Address:0x6A
Type: RO
SoftwareReset: 0x00
Hardware Reset: 0x00
MSBLSB
b7b6b5b4b3b2b1b0
AB7AB6AB5AB4AB3AB2AB1AB0
AVERAGE_BITRATE is a read-only register and
it contains the average bitrate of the incoming bitstream. The value is rounded with an accuracy of
1 Kbit/sec.
FRAME_CNT_L
MSBLSB
b7b6b5b4b3b2b1b0
FC7FC6FC5FC4FC3FC2FC1FC0
FRAME_CNT_M
MSBLSB
b7b6b5b4b3b2b1b0
FC15 FC14 FC13 FC12 FC11 FC10 FC9FC8
SOFTVERSION
Address:0x71
Type: RO
MSBLSB
b7b6b5b4b3b2b1b0
SV7SV6SV5SV4SV3SV2SV1SV0
After the STA013 boot, this register contains the
versioncode of the embeddedsoftware.
23/38
STA013 - STA013B - STA013T
RUN
Address: 0x72
Type:RW
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0
XXXXXXXRUN
Setting this register to 1, STA013leaves the idle
state, starting the decodingprocess.
The Microcontroller is allowed to set the RUN
flag, once all the control registers have been initialized.
TREBLE_FREQUENCY_LOW
Address: 0x77
Type:RW
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0
TF7TF6TF5TF4TF3TF2TF1TF0
BASS_FREQUENCY_LOW
Address:0x79
SoftwareReset: 0x00
Hardware Reset: 0x00
MSBLSB
b7b6b5b4b3b2b1b0
BF7BF6BF5BF4BF3BF2BF1BF0
BASS_FREQUENCY_HIGH
Address:0x7A
SoftwareReset: 0x00
Hardware Reset: 0x00
MSBLSB
b7b6b5b4b3b2b1b0
BF15 BF14 BF13 BF12 BF11 BF10 BF9BF8
The registers BASS_FREQUENCY_HIGH and
BASS_FREQUENCY_LOW, logically concatenated as a 16 bit wide register,are usedto select
the frequency, in Hz, where the selected frequency is -12dB respect to the pass-band. By
setting the BASS_FREQUENCY registers, the
followingrules must be kept:
TREBLE_FREQUENCY_HIGH
Address: 0x78
Type:RW
SoftwareReset: 0x00
Hardware Reset:0x00
MSBLSB
b7b6b5b4b3b2b1b0
TF15 TF14 TF13 TF12 TF11 TF10 TF9TF8
The registers TREBLE_FREQUENCY-HIGH and
TREBLE_FREQUENCY-LOW, logically concatenated as a 16 bit wide register, are used to select
the frequency, in Hz, where the selected frequency is +12dB respectto the stop band.
By setting these registers, the followingrule must
be kept:
son, before applying Bass & Treble Control, the
user has to set the TONE_ATTEN register to the
maximum value of enhancement is going to perform.
For example, in case of a 0 dB signal (max. level)
only attenuation would be possible. If enhancement is desired, the signal has to be attenuated
accordinglybeforeinordertoreservea margin indB.
Anincrementof a decimalunitcorrespondstoa Tone
Attenuati onstepof 1.5dB.
.
.
.
5. GENERALINFORMATION
5.1. MPEG2.5 Layer III Algorithm.
DEMULTIPLEXING
ERROR CHECK
ENCODED AUDIO
BITSTREAM (8Kbit/s ... 128Kbit/s)
ANCILLARY DATA
&
HUFFMAN
DECODING
SIDE
INVERSE
QUANTISATION
DESCALING
INFORMATION
DECODING
&
IMDCT
D98AU903
INVERSE
FILTERBANK
STEREOPHONICAUDIO
SIGNAL (2*768Kbit/s)
5.2 - MPEGAncillary Data Description:
As specifyed in the ISO standard, the MPEG
Layer III frames have a variable bit lenght, and
pling frequencies.The time duration of the Layer
III frames is shown in Tab 2.
are constant in time depending on the audio sam-
Table2: MPEGLayer III Frames Time Duration
Sampling Frequency (KHz)4844.1322422.5161211.0258
MPEG Frame Lenght (ms)242936242936484872
27/38
STA013 - STA013B - STA013T
The Ancillary Data extraction on STA013 can be
described as follow:
STA013 has a specific Ancillary Data buffer,
mapped into the I2C registers:
specific register, to require the new 5 byte slot to
STA003is needed.
This registeris:
0x16CMD_INTERRUPT
The interruptregister, is sensitive to any non-zero
value written by the Microcontroller. When this
register is updated the Ancillary Data buffer is
filled up with new values and the registers
0x41ANCCOUNT_L
0x42ANCCOUNT_H
Since the content of Ancillary Data into an MPEG
are updated (decremented) accordingly.
Frame STA013 can extract is max. 56 bytes, a
5.3. I/O CELL DESCRIPTION
1) CMOSTristate Output Pad Buffer, 4mA, with Slew Rate Control / Pinnumbers 9, 10, 11, 20, 28
EN
Z
A
D98AU904
OUTPUT PINMAX LOAD
Z100pF
2) CMOSBidir Pad Buffer, 4mA, with Slew Rate Control/ Pin numbers3, 12
C_stop_cond;/*generate I2C stopcondition*/
fp++;/* update pointer to new file row*/
}
while
(!EDF)/* repeatuntilEndof File*/
}/* Endroutine*/
Note:1
STA013 isa device based onan integratedDSP core. Some ofthe I2C registers default values are loaded after an internal DSP boot operation.
The bootstrap time is 60 micro second. Only after this time lenght, the data in the register can be considered stable.
Information furnished is believed to be accurate and reliable. However, STMicroelectronics assumes no responsibility for the consequences
of use of such information nor for any infringement of patents or other rights of third parties which may result from its use. No license is
granted by implication or otherwise under any patent or patent rights of STMicroelectronics. Specification mentioned in this publication are
subject to change without notice. This publication supersedes and replaces all information previously supplied. STMicroelectronics products
are not authorized for use as critical components in life support devices or systems without express written approval of STMicroelectronics.
The ST logo is a registeredtrademark of STMicroelectronics
1999 STMicroelectronics – Printed in Italy – All Rights Reserved
STMicroelectronics GROUP OF COMPANIES
Australia - Brazil - China - Finland - France - Germany - Hong Kong - India - Italy - Japan - Malaysia - Malta - Morocco -
Singapore - Spain - Sweden - Switzerland - United Kingdom - U.S.A.
http://www.st.com
38/38
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.