360 likes | 496 Views
Surround Sound Decoder. ECE345 Spring 2001 Sean Davis Kevin McMahon. Hardware Development. Block Diagram of Project Initial Circuit Design Overview Board Layout Board Testing. Software Development. Development Platform Tools Design Testing Challenges.
E N D
Surround Sound Decoder ECE345 Spring 2001 Sean Davis Kevin McMahon
Hardware Development • Block Diagram of Project • Initial Circuit Design Overview • Board Layout • Board Testing
Software Development • Development Platform • Tools • Design • Testing • Challenges
Block Diagram of Components for Surround Sound Decoder Control: Communicates with the DSP and sends control signals to the other components. Input: Line receiver that changes the incoming digital signal into readable serial data. DSP: Processes the serial data and outputs to the appropriate channel for output. Digital Input from source 3 Digital Channels Digital to Analog Converters: Changes the digital output from the DSP to analog. 6 Analog Channels Output: Amplifies the analog output from the DAC for output to the receiver. Output to 5.1 Channel receiver
Power • Power is supplied by a 12V wall transformer. • Linear voltage regulators used to convert voltage to +5V and +2.5V. • Chosen for ease of use and smaller number of external components. • For more efficient regulation, it would be best to use a DC-DC converter or switching power supply. • Ferrite Bead inductors are used for filtering analog signals in the power supply.
Input • Streaming digital audio signal is taken from a source, such as a DVD player. • The serial signal is sent at +/- 0.5V. • The Crystal® CS8414 Line Receiver is used to change the incoming signal to +5V for input to the DSP and DACs. • The mode of operation is set for the L/R and S clock to be inputs to the line receiver (generated by the DSP) and the data to be sent in 24-bit I2S compatible format.
Control • Microchip’s PIC16F877 microcontroller is used to control the various chips. • Communicates with the DSP over an I2C bus. • We used capacitors on the I2C lines to filter noise. • Issues reset commands to all of the other components.
DSP • Crystal® CS49326 DSP • 12.288MHz crystal oscillator is used to generate internal PLL clock. • DSP can decode standard PCM (CD audio) as well as Dolby Digital® and DTS® audio (used on most DVD movies). • The code is loaded from the microcontroller.
Digital to Analog Converters • Crystal® CS4340 DACs • Input mode is set to 16 to 24-bit I2S compatible. • DAC converters signal to 48-96KHz audio for input to an external amplifier.
Analog Output • The analog audio is filtered for output to the external amplifier. • The DAC issues a mute signal during power up and if the clocks are out of sync. • When mute is high, the transistor network clamps the output to ground. • This part of the circuit reduces pops and clicks heard on the speakers.
Board Layout • Layout of the board was done in OrCAD Layout Plus. • Took special consideration of noise on digital components. • The board has four layers and all have a copper ground area to help dissipate noise. • Parts were ordered before the layout process to ensure proper footprints.
Board Testing • The board was systematically tested in stages so as to rule out problems as we went. • The power, control, and input stages where populated and tested first. • Once this was complete, the board was turned over for the software development and testing.
Development Platform • Microchip PIC 16F877 • 20 MHz • 8K x 14 bit words FLASH Memory • I2C or SPI support • Debugging tools • Availability of professional C compilers
Tools • CCS Inc. PIC C Compiler • MPLAB • In-Circuit Debugger • Logic Analyzers • Oscilloscope
Basics Reset hardware Initialize DSP Configure hardware Configure software Extras Automatically switch streams Bass management Addition Dolby play modes Design Overview
Software Requirements • Boot DSP • Transfer appropriate application code • Dolby Digital®, DTS®, PCM, MP3 • Ensure hardware is initialize correctly • Monitor DSP playback modes • Watch for changes in stream • Out-of-Sync messages
Extras • Recognize changes in streams and load appropriate code • Bass management • Additional Dolby play mode • Audio effects
Design Issues • I2C methods • Hardware modes • Input settings • Output settings • Handling unsolicited messages • Interrupt handler issues
Testing • In-Circuit Debugging • Logic analyzer • Helper functions
Successes and Challenges • Re-wrote I2C functions • Implemented automatic stream processing for changing audio streams mid-track • Wrote functions to verify and test DSP operation
Hardware Post Mortem • Positives • 4 Layer board • Power system • Parts layout and planning • Licensing issues • Negatives • Voltage conversion between line receiver and DSP • DAC issues • Hardwiring mode bits
Software Post Mortem • Positives • I2C rewrite • Taking the time to write helper functions • Development done in C instead of ASM • Negatives • In-Circuit Debugger only debug method • Compiler stability • Interrupt handler