Embedded MP2 decoder

Project name:
 Embedded MP2 audio decoder
   
Language: ANSI C
   
Target platform: Currently running on a Ti C6000, but suitable for most embedded platforms
   
Abstract: This takes the MP2 audio data and decodes it to a PCM audio stream
   
Key features and advantages: The software is a complete tested solution. It has been highly optimised and all the code is based on integer maths.
   

Full Description

MP2 Decoder is a high-quality MPEG-1 Layer II decoder optimised with integer arithmetic for Embedded Applications. The library was originally developed for a DVD playback system running on a c6000 DSP from Ti.

Overview of MP2 decoder library

PCM output
MP2 Decoder provides full 16-bit PCM output making applications to produce exceptionally high quality audio.

Fixed-point (integer) computations
It uses integer computations rather than floating point to gain maximum performance on architectures without a floating point unit.

Implemented based on the ISO/IEC standards
MP2 Decoder is implemented based on the ISO/IEC standard and it is not a derivation of the ISO reference source code. Considerable effort has been expended on porting this for embedded applications to ensure a correct implementation.


Performance Parameters


RAM requirements: xxkB minimum, typicall xxkB

Typical code space requirements: xxkB

Typical speed: Stereo 48KHz,128Kb/s at xx% processor load (DM648 @900MHz)

Embedded MP2 Audio decoder Application Programming Interface

1. void init_mp2decoder ( )

This function needs to be called before using the MP2 Audio Decoder

2. int decode_audio(unsigned char *audioBuf, int iNumBytes);

This function decoded MPEG-1 Layer II data and produce PCM output internally. 

Parameters:      audioBuf         -           MPEG-1 Layer II data buffer

iNumBytes      -           Number of bytes in the buffer

Return Value:     1     successful

                  0     error

Note:

Decoded PCM samples will be saved to a global buffer called pcm_data which is defined as follows.

unsigned short pcm_data[5376];







This page was printed from: http://www.hynav.com/index.php?pcat=2&cat=7498&lang=1

© Race Technology Ltd '24