Microcomputer Systems 1

Slides:



Advertisements
Similar presentations
EE2F2 - Music Technology 4. Effects. Effects (FX) Effects are applied to modify sounds in many ways – we will look at some of the more common Effects.
Advertisements

ECE 8443 – Pattern Recognition ECE 8423 – Adaptive Signal Processing Objectives: The Linear Prediction Model The Autocorrelation Method Levinson and Durbin.
August 2004Multirate DSP (Part 2/2)1 Multirate DSP Digital Filter Banks Filter Banks and Subband Processing Applications and Advantages Perfect Reconstruction.
Effects. Dynamic Range Processors Fixed Time Delay Effects Variable Time Delay Effects Reverberation Effects Time and Pitch Changing Effects Distortion.
Guitar Effects Processor Using DSP
Modulation: CHORUS AND FLANGE  Just as a chorus is a group of singers, the chorus effect can make a single instrument sound like there are actually.
0 - 1 © 2010 Texas Instruments Inc Practical Audio Experiments using the TMS320C5505 USB Stick “Sine Waves” Texas Instruments University Programme Teaching.
Implementation of an Audio Reverberation Algorithm
Image and Sound Editing Raed S. Rasheed Digital Sound Digital sound types – Monophonic sound – Stereophonic sound – Quadraphonic sound – Surround.
SYED SYAHRIL TRADITIONAL MUSICAL INSTRUMENT SIMULATOR FOR GUITAR1.
Live Sound Analog Mixing Console. Live Sound Analog Mixing Consoles Come in many different sizes and configurations for different applications Come in.
Overview of Adaptive Multi-Rate Narrow Band (AMR-NB) Speech Codec
4.4.3 Interpolation Using Unchanged Key Values It is often necessary to retain the values from the input sequence y(m) in the interpolated x(n). without.
Implementing 3D Digital Sound In “Virtual Table Tennis” By Alexander Stevenson.
1 Manipulating Digital Audio. 2 Digital Manipulation  Extremely powerful manipulation techniques  Cut and paste  Filtering  Frequency domain manipulation.
Joshua “Rock Star” Jenkins Jeff “Tremolo” Smith Jairo “the boss” Rojas
DSP Term Project By: Ashley Downs And Jeff Malen By: Ashley Downs And Jeff Malen.
Prepared by: Hind J. Zourob Heba M. Matter Supervisor: Dr. Hatem El-Aydi Faculty Of Engineering Communications & Control Engineering.
Digital Signals and Systems
Microcomputer Systems 1 Audio Processing Problems and Solutions.
EE Audio Signals and Systems Effects Kevin D. Donohue Electrical and Computer Engineering University of Kentucky.
“TMS320C5505 USB Stick Teaching Materials”
Fixed-Point Arithmetics: Part II
Digital Filters. Filters Filters shape the frequency spectrum of a sound signal. –Filters generally do not add frequency components to a signal that are.
Sound Quality.
Panning and Filters © Allan C. Milne Abertay University v
Copyright © 2011 by Denny Lin1 Computer Music Synthesis Chapter 6 Based on “Excerpt from Designing Sound” by Andy Farnell Slides by Denny Lin.
Ch.5 Fixed-Point vs. Floating Point. 5.1 Q-format Number Representation on Fixed-Point DSPs 2’s Complement Number –B = b N-1 …b 1 b 0 –Decimal Value D.
Signal Processing (time-based effects)
ECE 5525 Osama Saraireh Fall 2005 Dr. Veton Kepuska
Quiz 1 Review. Analog Synthesis Overview Sound is created by controlling electrical current within synthesizer, and amplifying result. Basic components:
 Sound effects  Our project  Background & techniques  Applications  Methodology  Results  Conclusion.
Microcomputer Systems Final Project “Speaker and Sound Modulation”
Effects. Effects in Music n All music that is recorded or amplified relies on effects to enhance certain characteristics of the sound. n Guitarists typically.
Digital Audio II. Volume Scaling The volume of a digitized audio source may be increased or decreased by multiplying each sample value by an appropriate.
Time Based Processors. Reverb source:
Chapter 6 Discrete-Time System. 2/90  Operation of discrete time system 1. Discrete time system where and are multiplier D is delay element Fig. 6-1.
Real-time Digital Signal Processing Digital Filters.
MECH 373 Instrumentation and Measurements
Linear Constant-Coefficient Difference Equations
Architectures of Digital Information Systems Part 1: Interrupts and DMA dr.ir. A.C. Verschueren Eindhoven University of Technology Section of Digital.
Signal Output Send effect Send/Return effects Definition:
Voice Manipulator Department of Electrical & Computer Engineering
Lattice Struture.
Analog to digital conversion
Digital Communications Chapter 13. Source Coding
Adaptive Filters Common filter design methods assume that the characteristics of the signal remain constant in time. However, when the signal characteristics.
Lecture 12 Linearity & Time-Invariance Convolution
Embedded Systems Design
ECE 3551 Microcomputer Systems
Digital Control Systems Waseem Gulsher
Microcomputer Systems 1
Microcomputer Systems 1
Designations Inputs Outputs Signal processing
Microcomputer Systems 1
Microcomputer Systems 1
Linear Predictive Coding Methods
Chapter 6 Discrete-Time System
Digital Systems and Binary Numbers
DEPARTMENT OF INFORMATION TECHNOLOGY DIGITAL SIGNAL PROCESSING UNIT 4
Games Development Practices Sound Effects
Adaptive Filter A digital filter that automatically adjusts its coefficients to adapt input signal via an adaptive algorithm. Applications: Signal enhancement.
Govt. Polytechnic Dhangar(Fatehabad)
Tania Stathaki 811b LTI Discrete-Time Systems in Transform Domain Ideal Filters Zero Phase Transfer Functions Linear Phase Transfer.
Zhongguo Liu Biomedical Engineering
DEPARTMENT OF INFORMATION TECHNOLOGY DIGITAL SIGNAL PROCESSING UNIT 4
Chapter 9 Advanced Topics in DSP
Fixed-point Analysis of Digital Filters
Recap In previous lessons we have looked at how numbers can be stored as binary. We have also seen how images are stored as binary. This lesson we are.
Embedded Sound Processing : Implementing the Echo Effect
Presentation transcript:

Microcomputer Systems 1 Digital Systems: Hardware Organization and Design 4/6/2019 Microcomputer Systems 1 Audio Processing Problems and Solutions Architecture of a Respresentative 32 Bit Processor

Audio Processing Problems and Solutions Digital Systems: Hardware Organization and Design 4/6/2019 Audio Processing Problems and Solutions Architecture of a Respresentative 32 Bit Processor

Automatic Gain/Volume Control Digital Systems: Hardware Organization and Design 4/6/2019 Automatic Gain/Volume Control One of the simplest operations that can be performed in a DSP on an audio signal is volume gain and attenuation. For fixedpoint math, this operation can be performed by multiplying each incoming sample by a fractional value number between 0x0000…. and 0x7FFF…. or using a shifter to multiply or divide the sample by a power of 2. When increasing the gain of a signal, the programmer must be aware of overflow, underflow, saturation, and quantization noise effects. 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Estimation of the Energy of the Signal Digital Systems: Hardware Organization and Design 4/6/2019 Estimation of the Energy of the Signal Algorithm: Keep track of the maximum energy of the input signal. if (abs(in_sample) > myMax) { myMax = abs(sample); } Ajust the Gain to cover 80% of the overall dynamic range of the output. new_target_gain = 0.8*MAX_RANGE/myMax; Compute actual gain factor based on some empirically defined function that performs necessary smoothing based on desired responsiveness and smoothness of the gain. gain = compute_gain(gain, new_target_gain); Apply Gain: out_sample = gain*in_sample; 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Gain Update Function float compute_gain(gain, new_gain) { // Linear interpolation float g, alpha = 0.2; // computed gain will adjust gain // each time is called by 20% toward // target gain g = (1-alpha)*gain + alpha*new_gain; return (g); } 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Amplitude Panning of Signals to a Left or Right Stereo Field Digital Systems: Hardware Organization and Design 4/6/2019 Amplitude Panning of Signals to a Left or Right Stereo Field Reference: Using The Low Cost, High Performance ADSP-21065L Digital Signal Processor For Digital Audio Applications Dan Ledger and John Tomarakos DSP Applications Group, Analog Devices, Norwood, MA 02062, USA Architecture of a Respresentative 32 Bit Processor

Amplitude Panning of Signals to a Left or Right Stereo Field Digital Systems: Hardware Organization and Design 4/6/2019 Amplitude Panning of Signals to a Left or Right Stereo Field In many applications, the DSP may need to process two (or more) channels of incoming data, typically from a stereo A/D converter. Two-channel recording and playback is still the dominant method in consumer and professional audio and can be found in mixers and home audio equipment. V. Pulkki [22] demonstrated placement of a signal in a stereo field (see Figure 4 below) using Vector Base Amplitude Panning. The formulas presented in Pulkki’s paper for a two-dimensional trigonometric and vector panning will be shown for reference. 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Amplitude Panning of Signals to a Left or Right Stereo Field Digital Systems: Hardware Organization and Design 4/6/2019 Amplitude Panning of Signals to a Left or Right Stereo Field Normally, the stereo signal will contain an exact duplicate of the sampled input signal, although it can be split up to represent two different mono sources. Also, the DSP can also take a mono source and create signals to be sent out to a stereo D/A converter. Typical audio mixing consoles and multichannel recorders will mix down multiple signal channels down to a stereo output field to match the standardized configuration found in many home stereo systems. Figure 25 is a representation of what a typical panning control ‘pot’ looks like on a mixing console or 8-track home recording device, along with some typical pan settings: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Pan Control Three Typical Pan Control Settings of a Mono Source To A Stereo Output Field L R L R L R Full Left Pane Center Mix Full Right Pane 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 “Source of the Sound” To give the listener a sense of location within the output stereo filed, the DSP can simply perform a multiplication of the algorithmic result on both the left and right channel so that it is perceived from coming from a phantom source. Virtual source x  0 -0 y Panning of Two-Channel Stereophonic Audio Derived by Blumlein, Bauer and Bernfeld [26] 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 “Source of the Sound” Pulkki’s Method [26] For Vector Panning of Two-Channel Audio Virtual source x  -0 0 p IR IL gLIL gRIR y 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Source of the Sound To create a panning effect of an audio channel to a particular position in the stereo output field, the programmer can use the Stereophonic Law of Sines, or the Tangent Law equation (Pulkki, Blumlein and Bauer[22], see Figure) where gL and gR are the respective gains of the left and right channels. This is valid if the listener’s head is pointing straight ahead. If the listener turns the head to follow the virtual source, the Tangent Law equation as described by Pulkki [derived by Bernfeld, 26] is modified as: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Source of the Sound Assuming fixed point signed fractional arithmetic where signals are represented between 0 (0x0000…) and 0.99999 (0x7FFF…), the DSP programmer needs simply to multiply each signal by the calculated gain. Using Pulkki's Vector Base Amplitude Panning method as shown in the slide 11, the position p of the phantom sound source is calculated from the linear combination of both speaker vectors: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Source of the Sound The output difference I/O equations for each channel are simply: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Vector Based Amplitude Panning Summary Digital Systems: Hardware Organization and Design 4/6/2019 Vector Based Amplitude Panning Summary Left Pan: If the virtual source is panned completely to the left channel, the signal only comes out of the left channel and the right channel is zero. When the gain is 1, then the signal is simply passed through to the output channel. GL= 1 GR= 0 Right Pan: If the virtual source is panned completely to the right channel, the signal only comes out of the right channel and the left channel is zero. When the gain is 1, then the signal is simply passed through to the output channel. GL= 0 GR= 1 Center Pan: If the phantom source is panned to the center, the gain in both speakers are equal. GL= GR Arbitrary Virtual Positioning: If the phantom source is between both speakers, the tangent law applies. The resulting stereo mix that is perceived by the listener would be off-scale left/right from the center of both speakers. Some useful design equations [26] are shown below: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Table Lookup If DSP processor/IDE does not support trigonometric functions then table lookups can be stored with pre- computed panning values for number of angles. Table below shows left and right channel gains required for the desired panning angle: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Graphic Equalizers Professional and Consumer use equalizers to adjust the amplitude of a signal within selected frequency ranges. In a Graphic Equalizer, the frequency spectrum is broken up into several bands using band-pass filters. Setting the different gain sliders to a desired setting gives a ‘visual graph’ (Figure in the next slide) of the overall frequency response of the equalizer unit. The more bands in the implementation yields a more accurate desired response. 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Graphic Equalizer Analog equalizers typically uses passive and active components. Increasing the number of bands results in a large board design. When implementing the same system in a DSP, however, the number of bands is only limited by the speed of the DSP (MIPs) while board space remains the same. Resisters and capacitors are replaced by discrete-time filter coefficients, which are stored in a memory and can be easily modified. Figure 33 in the next slide shows and example DSP structure for implementing a 6 band graphic equalizer using second order IIR filters. The feedforward path is a fixed gain of 0.25, while each filter band can be multiplied by a variable gain for gain/attenuation. There are many methods of implementation for the second order filter, such as using ladder structures or biquad filters. Filter coefficients can be generated by a commercially available filter design package, where A and B coefficients can be generated in for the following 2nd order transfer function and equivalent I/O difference equations: 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Direct form II implementation equations are given below and ARMA implementation equation is given below 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Block Diagram of Graphic Equalizer Digital Systems: Hardware Organization and Design 4/6/2019 Block Diagram of Graphic Equalizer DSP Implementation of a Digital Graphic Equalizer g1 2nd Order IIR Band 1 Filter x[n] g2 gMaster 2nd Order IIR Band 2 Filter gi y[n] 2nd Order IIR Band i Filter gN 2nd Order IIR Band N Filter 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Time-Delay Digital Audio Effects Digital Systems: Hardware Organization and Design 4/6/2019 Time-Delay Digital Audio Effects Background theory and basic implementation of variety of time-based digital audio effects will be examined. The figure below shows some algorithms that can be found in digital audio effects processor. Multiple reflection delay effects using delay lines will be discussed first then more intricate effects such as Chorusing (animation of the basic sound by mixing it with two slightly detuned copies of itself) Flanging (is an audio process that combines two copies of the same signal, with the second delayed slightly, to produce a swirling effect Pitch shifting Reverberation (Reverberation is the persistence of sound in a particular space after the original sound is removed. When sound is produced in a space, a large number of echos build up and then slowly decay as the sound is adsorbed by the walls and air, creating reverberation, or reverb.) 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Typical Signal Chain for Audio Multi-Effects Processors Digital Systems: Hardware Organization and Design 4/6/2019 Typical Signal Chain for Audio Multi-Effects Processors By-pass Control Digital Delay/ Reverb Input Signal Comp- ressor Distortion/ Overdrive Chorus/ Flanger Equalizer Output Signal 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Digital Delay The Digital Delay is the simplest of all time delay audio effects. The delay effect is often the basis to produce more intricate effects such as flanging and chorusing, which vary the delay time on-the-fly. It is also used in reverberation algorithms to produce early reflections and recursive delays. To create reflection digitally, DSP delay effects units encode the input signal and store it digitally in a delay-line buffer until it is required at the later time where it is decoded back to analog form [17]. The DSP can produce delays in a variety of ways. Delay units can produce stereo results and multiple-tapped delayed results [7]. Many effects processors implement a delay and use it as a basis for producing multi-tap and reverb effects. Multi-tapped signals can be panned to the right, left or mixed together to give the listener the impression of the stereo echo bouncing from one side to the other. 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Delay – Single Reflection Delay Digital Systems: Hardware Organization and Design 4/6/2019 Digital Delay – Single Reflection Delay Implementation of a Digital Delay with Single Tap To implement a single reflection of an input signal, the following difference equation can be used: h[n]  1 *x[n-D]  x[n] Z-D y[n] D 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Automatic Double Tracking (ADT) and Slapback Echo Digital Systems: Hardware Organization and Design 4/6/2019 Automatic Double Tracking (ADT) and Slapback Echo One popular use of the digital delay is to quickly repeat the input signal with a single reflection at unity gain. By making the delay an input signal around 15-40 milliseconds, the resulting output produces a “slapback” or “doubling” effect (see Figure 1 in the next slide). The slight differences in the delay create the effect of the two parts being played in unison. This effect can also be set up to playback the original “dry” signal in one stereo channel and the delayed signal in the other channel (Figure 2 in the next slide). This creates the impression of a stereo effect using a single mono source. The same technique is used for a mono result, except both signals are added together. With short delays, slapback can thicken the sound of an instrument or voice when mixed for a mono result, although cancellations can occur from comb filtering side effects when the delay is under 10 ms, which will result in a hollow, resonant sound [2], [26]. 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Automatic Double Tracking (ADT) and Slapback Echo Digital Systems: Hardware Organization and Design 4/6/2019 Automatic Double Tracking (ADT) and Slapback Echo Slapback Echo Effect Automatic Double Tracking/ “Stereo Doubling” yL[n] x[n] 0.5 y[n] x[n] gL Z-D Z-D yR[n] Small Delay Between 10 to 30 msec Small Delay Between 10 to 30 msec 0.5 gR 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Multitap Delays Multiple delayed values of an input signal can be combined easily to produce multiple reflections of the input. This can be done by having multiple taps pointing to different previous inputs stored into the delay line, or by having separate memory buffers at different sizes where input samples are stored. Typical Impulse Response of Multiple Delay Effect h[n] 1 1 2 3 4 5 D 2D 3D 4D 5D 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Multitap Delay Difference Equation Digital Systems: Hardware Organization and Design 4/6/2019 Multitap Delay Difference Equation The difference equation is a simple modification of the single delay case. To 5 delays of the input (see Figure 43), the DSP processing algorithm would perform the following difference equation operation: x[n] Z-D Z-D Z-D Z-D 1 2 3 y[n] 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor

Digital Systems: Hardware Organization and Design 4/6/2019 Reverberation Effect Adding an infinite # of delays will create a rudimentary reverb effect by simulating reflections in a room (Figure 46). The difference equation then becomes and IIR comb filter (Figure 46): 6 April 2019 Veton Këpuska Architecture of a Respresentative 32 Bit Processor