Design of MP3 Player Based on VS1003 Decoder

Abstract: With MSP430F149 as the core controller and VS1003 audio decoder, an MP3 player with SD card is designed, and the hardware and software design of MP3 playback system is given. In the hardware design, the decoder is separated from the memory, which increases the storage capacity. In the software design, the item menu mode is used for management, and the hardware or software can be easily upgraded. After testing, the MP3 player plays better.
Keywords: MP3 player; SPI bus; MSP430F149; VS1003

Introduction Although there are more and more MP3 styles on the market, the functions are more and more abundant, and the design is more and more personalized and user-friendly. However, most of the existing MP3 players integrate the decoder and the memory. This design plays a key role in the portability of MP3 players, but at the same time it also brings some problems: on the one hand, the storage capacity is not easy to expand, on the other hand, it is not conducive to the application of MP3 players in other fields. The system separates the memory from the decoder, and can utilize redundant I/O interfaces. As long as a small amount of hardware overhead is added and the corresponding code is added, the functions of voltage measurement, frequency measurement, temperature measurement, etc. can be conveniently added on the basis of the system. Do a multi-purpose machine.

1 system design MP3 player system block diagram shown in Figure 1. The system mainly includes MSP430F149 single-chip minimum system, audio decoding module, SD card reading and writing module, liquid crystal display module and flash memory for storing self-made fonts.
a.JPG

MSP430F149 is a MSP430 series of single-chip microcomputers from TI, USA, which has a 16-bit structure suitable for various applications. The "von Neumann" structure is used, so its RAM, ROM and all peripheral modules are located in the same address space. And with ultra-low power performance, the MSP430 series can significantly extend battery life compared to other microcontrollers, which is important for handheld devices and some low-power electronics. In addition, it has the flexibility, powerful processing power, rich memory, peripherals and so on.

2 specific implementation of the hardware module
2.1 MSP430F149 single-chip minimum system MSP430F149 minimum system is the core part of the overall design, controlling the coordinated operation between the various sub-modules of the system. The success of its design is directly related to the normal operation of the entire design. As shown in Figure 2, the minimum system of MSP430F149 is mainly composed of voltage regulator module, crystal oscillator circuit, reset circuit and human-machine interactive button input. The SPX1117M3-3.3 is a system regulator chip that provides a stable 3.3 V supply to the system. The SP708S is a system management chip that, together with the manual reset switch, acts primarily as a reliable reset. Considering the human-computer interaction of the MP3 player, a total of six buttons (KEY1 to KEY6) are designed. Their button functions are: OK, Down, Up, Exit, Volume Plus, Volume Off.
b.JPG

2.2 Audio Decoding Module VS1003 is a single-chip MP3/WMA audio decoding chip produced by Finnish VLSI. It has a high performance, low power DSP processor core VSDSP, 5 KB instruction RAM, O. 5 KB of data RAM, serial control and data input interface, 4 general purpose I/O ports, 1 UART port, 1 variable sample rate ADC, 1 stereo DAC and audio headphone amplifier. Its internal structure is shown in Figure 3.
c.JPG

The audio decoding module parses the digital MP3 audio data stream read by the single chip from the SD card, and converts it into an analog signal for output. 4 is a circuit schematic diagram of an audio decoding module of the MP3 player.
d.JPG

The VS1003 audio decoding chip is used to realize the analysis of the music data stream. Data communication between the VS1003 and the core controller MSP430F149 is performed via the SPI bus. The VS1003 receives the MSP430F149 control commands and MP3 data through the Serial Command Interface (SCI) and Serial Data Interface (SDI). It determines which interface is in the transmit state by setting the high/low of the xCS and xDCS pins. The function control of VS1003, such as initialization, soft reset, pause, volume control, read time of playback time, etc., is realized by writing to a specific register through the SCI port. The DREQ pin signal is used between the two SCI instructions to determine whether the last processing was completed.
2.3 SD card module SD card has low price, large storage capacity, convenient use, versatility and security. SD card is used as storage device for MP3 and digital cameras.
The SD card supports two bus modes: SD mode and SPI mode. Among them, the SD mode adopts the 6-wire system, and the SPI mode adopts the 4-wire system. The SPI mode is generally used when reading and writing SD cards by using a single chip microcomputer. The SD card can be operated in SD or SPI mode with different initialization methods.
In this design, the audio data MP3 file is based on the SD card, so the design of the circuit must include reading the SD card module. Figure 5 shows the interface circuit of the SD card module (SPI mode).
e.JPG

2.4 LCD Module The LCD3310 LCD is a 48-row, 84-column liquid crystal display. Its low-power PCD8544 CMOS LCD control driver with serial input speeds up to 4. O Mb/s. In order to allow the LCD3310 liquid crystal to display 4 lines of 12×12 Chinese characters, the system has opened a 6×84 byte buffer. When writing the liquid crystal, it is not necessary to directly write to the static DDRAM of the LCD3310. It can be written into the data buffer opened by the system for the first time, and then the modified part can be displayed to display the content to be displayed. The interface of the LCD3310 uses SPI mode, and its circuit is shown in Figure 6.

3 Software Design Figure 7 is the software flow of the MP3 player. After the system starts, initialize the hardware module first. The MCU reads some basic information of the SD card through the FAT32 file system interface, such as capacity, sector size, FAT table, and the starting sector where the root directory is located. With this information, you can find out if the SD card has music files that can be played. If so, the MCU reads the audio information through the SPI bus, and sends the stream stream information of the song to the VS1003 chip, and realizes the playback of the MP3 song through the VS1003 decoder chip and its high-quality stereo DAC and headphone driver circuit. Features. Under the control of the button, the function of song selection and volume control is realized through the selection of menu options in the LCD3310; while playing, the information displayed on the LCD3310 includes the progress and volume in addition to the song name.

f.JPG
After running the test, the system can smoothly play 320 kb / s high-quality MP3 music files, and in the case of using a 500 mA lithium battery, can play normally for up to 10 hours. It can be seen that its power consumption is relatively low.

Conclusion Based on the principle of low cost and practicability, an MP3 player with separate decoder and memory is designed to smoothly play high quality MP3 files. At the same time, as long as a small amount of hardware overhead is added and the corresponding code is added, the redundant I/O port can be used to conveniently add functions such as voltage measurement, frequency measurement, temperature measurement, etc. on the basis of the system, and truly multi-purpose.

This article refers to the address: http://

Mobile Cable

Mobile Cable,Military Communication System Cable Distribution,Between Radars Or Oil Field,Excellent Tensile Strength

Shandong Qingguo Optical Fiber Co., Ltd. , http://www.qgfiber.com

Posted on