Acoustic Echo Cancellation using Frequency Domain Adaptive Methods on TMS320C6713DSK

Download Full-Text PDF Cite this Publication

Text Only Version

Acoustic Echo Cancellation using Frequency Domain Adaptive Methods on TMS320C6713DSK

Shreyas H. Gopalaiah

Student, M.Tech 4th Semester, Research Scholar and Associate Professor,

Department of Instrumentation Technology, Department of Instrumentation Technology,

Dayananda Sagar College of Engineering, Dayananda Sagar College of Engineering, Bangalore, India Bangalore, India

Abstract In this new period of worldwide communication, wireless phones are considered and viewed crucial communication tools and have an immediate effect on peoples everyday personal and business communications. A new system network bases are implemented and competition between wireless communications is incremented, digital wireless communication subscribers are increasing ever and the service and voice quality they receive from network providers are very critical. Subscriber demand for upgraded and good voice quality over wireless networks has driven a new innovation termed as echo cancellation technology, which can provide close and good voice quality over a wireless network.

Ultimately, the search for enhanced voice quality has promoted intensive research into the region of echo cancellation. Such research is led with the point of giving results that can reduce background noise and remove hybrid and acoustic echoes before any transcoder transforming happens, by utilizing echo cancellation technology, the quality and nature of speech can be enhanced significantly.

KeywordssAdaptive filters, Least mean square (LMS), Fast LMS, Fast Fourier Transform (FFT).


    Acoustic Echo is a common occurrence in todays telecommunication systems. This occurs when an audio source and sink operate in full duplex mode; an example of this is a hands-free loudspeaker telephone. In this condition the received signal is output through the telephone loudspeaker. This audio signal is then reverberated through the physical environment and picked up by the systems microphone. The effect is the return to the distant user of time delayed and attenuated of original speech signal.

    The signal interference caused by acoustic echo is distracting to both users and causes a reduction in the quality of the communication. This project focuses on the use of adaptive filtering techniques to reduce this unwanted echo, thereby increasing communication quality.

    Adaptive filters are a class of filters that iteratively alter their parameters in order to minimize a function of the difference between a desired target output and their output. In considering the case of acoustic echo in telecommunications, the optimal output is an echoed signal which accurately estimates the unwanted echo signal. This project implements an Acoustic Echo Canceller system on TMS320C6713DSK.

    The main module of this echo canceller is Frequency Domain adaptive systems are to be implemented on the DSP hardware.


    The quick development of innovation in recent decades has changed the entire system of communications. Nowadays, people are more interested in hands-free communication. In such a circumstance, the utilization of a regular loudspeaker and a high-gain microphone, in place of a telephone receiver may appear to be more suitable. This would permit more than one man to participate in a conversation at the meantime, such as a teleconference environment. However, due to a large acoustic coupling between the loudspeaker and microphone would generate a loud echo that would make conversation difficult. Additionally, the acoustic system could become unstable, which would generate a loud howling noise to occur.


    Fig. 1 Block Diagram for the overlap-save algorithm

    A. Overlap-Save Algorithm

    Let N be the length of the impulse response of the system, the modem echo path. The length of the input sequence is then twice this at 2N.

    1. N zeros are added to the impulse response if necessary so that the result of the FFT will be the same length as that of the FFTs of the input sections.

    2. The FFT of the impulse response is calculated and stored in memory because it will remain unchanged.

    3. Next the current block of the input is taken and the FFT of it has to find, for the first block there are N zeros in front of it for subsequent blocks the previous input block precedes the current input block.

      W k FFT x

    4. The two FFTs are now multiplied, to say that each element in one of the arrays will be multiplied by the corresponding element in the other. It corresponds to convolution in the time domain.

      Y k X k .W k

    5. The IFFT of Y(k) must now be calculated to bring the results back to the time domain.

      yn IFFT Y k

    6. The second half of this result is dumped for each convolution. The first half should be added to an array as the output of the filter for the given input block.

    7. The input block is updated applying 50% overlap and steps 3 to 7 are repeated.

    It is a fine algorithm so long as the filter coefficients are known. In the next section we will consider an algorithm that will enable adaptive filters to operate in the frequency domain.

    As in the Overlap-Save algorithm N is the length of the impulse response of the unknown system. Blocks of size 2N will be taken from the input at a time with 50% overlap as before. W will donate the filter coefficients, which will be initialized to zero and it should be updated after each block.

    The desired output is obtained by using the MATLAB filter function. The desired response of the adaptive filter is now known and it will be used to update its coefficients correctly. Similar to the Overlap-Save Algorithm we add N zeros to the start of the input array to ensure correct convolution results.

    1. An input block of size 2N is taken from the input array, U, the FFT of this block is calculate

      U k FFT un

    2. Now the Filter output can be computed by multiplying the FFT of the input block, U(k) by the Filter coefficients as updated by the previous iteration of the algorithm

      Y k U k .W k

      This is transformed to the time domain by finding the IFFT of the above result.

      yn IFFT Y k

      By circular convolution the first half of this result is simply discarded and the second half forms the output of the adaptive filter for the given input block.

      yn y N 1 upto 2N

    3. The error signal is computed next by means of simple subtraction to calculate the difference between the desired and the actual response.

      en dn yn

      where d(n) is the corresponding section of the desired response.

      The error should be brought into the frequency domain by adding N zeros to the start of e(n) and by computing a 2N point FFT and the result is called E(k).

      Ek FFT zeros, en

      The Gradient Constraint

    4. The conjugate of U(k), U(k) is found and this is multiplied by E(k) and the IFFT of the result is found. The second half of this result can be dropped due to circular convolution.

      gn IFFT Ek .U * k

      gn g1 upto N

    5. N zeros are now added to the end of what we are left with and the 2N point FFT of the resulting sequence is calculated and the result is multiplied by (the step size parameter)

      Save Last Block

      Save Last Block

      gn gnfollowed by N zeros












      X mu


      Append Zero Block

      Delete Last Block



      Append Zero Block

      Delete Last Block


      Gradient Constraint


      W1 k FFT gn

      Its the filter coefficient update factor, W1(k) and is added to W(k) and this is how the update of the coefficients is conducted.

      W(k+1) = W(k)+W1(k)

    6. This newly updated W(k+1) will now be used as the filter coefficients for the next block of input. An error may exist, however as W(k) is updated more often this error will diminish which shows the convergence of the filter coefficients to near optimum performance.





    Append Zero Block

    Append Zero Block

    E(k) e(n)

    X +


    The result for AEC in frequency domain is obtained under single talk condition. The simulation result is obtained using MATLAB. The Far end signal x(n), Echo signal r(n) and Error signal e(n) of frequency domain based Fast LMS (FLMS) algorithm is shown in figures 3-5.

    Fig. 2. Flow of Frequency Domain Adaptive Algorithm

    Fig. 3. Far end signal under single talk condition in FLMS algorithm

    Fig. 4. Echo Signal under single talk condition in FLMS algorithm

    Fig. 5. Error Signal under single talk condition in FLMS algorithm

    From figure 5, the residual echo in error signal is more for few milliseconds. Hence, the residual echo in frequency domain adaptive filter algorithm is more compared to time domain adaptive filter algorithms. From the figure 5, the convergence time for frequency domain based algorithm is very much less i.e. from 0.362 to 0.4 seconds. Hence, frequency domain based Fast LMS has fast processing time and converges faster than the time domain based adaptive filter algorithms. This is the main advantage of frequency domain based adaptive filter algorithm over time domain based adaptive filter algorithm. The residual echo in error signal can be minimized by using Non Linear Processor.


The frequency domain based Fast LMS algorithm is introduced in this project and simulation results are obtained using MATLAB and waveforms are observed in WAVOSAUR. From the simulation results we can conclude that Fast LMS has fast convergence time and processing time compared to time domain adaptive algorithms.


  1. Jose M. Gil-Cacho, Toon van Waterschoot, Marc Moonen, and Søren Holdt Jensen, A Frequency-Domain Adaptive Filter (FDAF)Prediction Error Method (PEM) Framework for Double-Talk- Robust Acoustic Echo Cancellation, IEEE/ACM transactions on audio, speech, and languageprocessing, VOL. 22, NO. 12, December 2014.

  2. Jason Wung, Daniele Giacobello, Joshua Atkins, Robust acoustic echo cancellation in the short-time fourier transform domain using adaptive crossband filters, 2014 IEEE International Conference on Acoustic, Speech and Signal Processing (ICASSP)

  3. Fabian Kuech, Edwin Mabande, Gerald Enzner, state-space architecture of the partitioned-block-based acoustic echo controller, 2014 IEEE International Conference on Acoustic, Speech and Signal Processing (ICASSP)

  4. Chul Min Lee, Jong Won Shinand Nam Soo Kim, Stereophonic Acoustic Echo Suppression Incorporating Spectro-Temporal Correlations,

    IEEE signal processing letters, vol. 21, NO. 3, March 2014

  5. Satoru Emura, Yusuke Hiwasaki and Hitoshi Ohmuro, Satoru Emura, Yusuke Hiwasaki and Hitoshi Ohmuro, 2013 IEEE Workshop on Applications of Signal Processing to Audio and Acoustics

  6. R. H. Kwong and E. W. Johnston, A variable step size LMS algorithm, IEEE Transactions on Signal Processing, Vol. 40, pp. 1633 – 1642, July 1992.

  7. J. Lee, H. C. Huang, and Y. N. Yang, The generalized square-error- regularized LMS algorithm, Proceedings of WCECS 2008, pp. 157 160, Oct. 2008.

  8. D. P. Mandic et al., Collaborative adaptive learning using hybrid filters,

    Proceedings of 2007 IEEE ICASSP, pp. III 921924, April 2007.

  9. D. P. Mandic; A generalized normalized gradient descent algorithm, IEEE Signal Processing Letters, Vol. 11, No. 2, pp. 115118, Feb. 2004.

  10. H. C. Shin, A. H. Sayed, and W. J. Song, Variable step-size NLMS and affine projection algorithms, IEEE Signal Processing Letters, Vol. 11, No. 2, pp. 132 – 135, Feb. 2004.

  11. J. M. Valin and I. B. Collings, Interference-normalized least mean square algorithm, IEEE Signal Processing Letters, Vol. 14, No. 12, pp. 988-991, Dec. 2007.

Leave a Reply

Your email address will not be published. Required fields are marked *