The schematics of my MP3 decoder board.

So, here is the beast. After some initial fiddling with the software I managed to get it working. The sound is decent, one can not expect more out of a MP3 player.

Some description of the components: the U1 buffer is used to shift the 3.3v LVTTL levels from the TINI board and the MP3 decoder to the DAC. The DAC is a 5V device, so a buffer is required.

This module was designed as an experimental board. Each individual stage is isolated with jumpers and can be replaced by externally connected device. For example one can take the outputs from the MP3 decoder from the jumpers J5 and connect an external DAC. The same way the outputs from the DAC can be connected to an external low pass filter via JP1.

There are two options for the analog 5V power supply. One can use the digital 5V supply filtered by L1, C24 and C25, or provide separate regulated 5V via AVdd In and select JP2 to position 1-2.

Clock options: you can use internal clock generated by the Y1 crystal. In this case DO NOT populate R8 and R9. If you opt for external clock, DO NOT populate Y1, C10, C11, R7, R10, populate R8 and R9 to provide 50 ohms load for impedance matching if required by the clock source.

TINI interface description (J2):

PinDirectionDescription
SDAI/OThis is the I2C data signal - used to configure the MP3 decoder.
SCLI/OThis is the I2C clock signal.
SDIIThis is the serial data feed to the MP3 decoder chip.
SCKRIThis is the serial data clock signal.
BIT_ENIThis signal is connected to the corresponding pin of the MP3 decoder. If set to low, the MP3 data is ignored. If not connected to the TINI board you can force the pin to always high via J3.
DATA_REQOThe MP3 decoder signals if it can accept more data.
MD3vIThis is the DAC configuration data signal. You may leave unconnected.
MC3vIThis is the DAC configuration clock signal. You may leave unconnected.
ML3vIThis is the DAC configuration latch signal. You may leave unconnected.
RESETIThis is the reset signal from the TINI board. Used to reset the DAC ant the MP3 decoder chip.

The decoder chip interface:

The interface to the decoder chip is via two busses: The first is a slow i2c bus, used for sending commands and configuration. The second is a high speed, SPI bus used to send MP3 data. The SPI bus is unidirectional, meaning the data flows only from the CPU to the decoder chip.

The output of the MP3 decoder is routed to the DAC via J5. The interface is common for the majority of the audio DACs. One can connect an external DAC or digital over sampling filter like PMD-100 or PMD-200. The MP3 decoder supports several data formats and the user should carefully examine the datasheet of the DAC and properly configure the MP3 decoder.

The PCM1720 also supports several input data formats, which can be configured via the Mx3v data lines. I have not experimented doing this and instead opted for using the default 16bit/44kHz data format, which is configured automatically after reset.

Initialization

Both the DAC and the MP3 decoder require a RESET signal. Examine both datasheets for the minimal timing requirements.

After the reset sequence, the MP3 decoder needs to be initialized via the i2c bus. There is special initialization sequence for both STA013 and STA015 decoder chips. The sequence is designed to patch the internal DSP program to fix a couple of decoding issues. Unfortunately without these patches the STA013 decoder is not very functional. Since both STA013 and STA015 use different internal DSP firmware, the initialization sequence is different. If you try to download the incorrect sequence the DSP will lock and the decoder will stop responding to commands until it is reset. All the patches are done in the internal decoder RAM and are lost once the power is removed.

The initialization involves downloading a series of commands via the i2c bus. It is a good practice to add the configuration commands for the MP3 decoder at the end of this sequence. This way at the end of the initialization your MP3 decoder will be fully configured and you can start sending MP3 data.

Go Back