[Speex-dev] AEC and resample question

Jerry Trantow jtrantow at ieee.org
Thu Feb 8 10:08:16 PST 2007


I understand that the capture/playback signals need to be sync'd for an AEC
to adapt.  I'm a little bit confused on the requirements of synchronous
sampling between the near end (mic/speaker) and the far end (phone line).  I
have an embedded DSP system with mic and speaker getting 1msec packets
containing 8 samples.  We can watch the DSP and ISDN clock frames drift and
every few minutes we will drop or reuse a packet of samples.  

According to "Echo Cancellation Demystified" by Alexey Frunze
http://www.spiritdsp.com/pdf/article_4.pdf (see section "Incorrect Codec
Synchronization") dropping or reusing samples isn't a viable solution since
it abruptly changes the echo path delay.  If I am dropping/reusing far end
(phone line/ISDN) samples before they go out the speaker and after the mic,
I don't understand why this has anything to do with the echo path.

The solution in the paper is to put an adaptive SRC between the phone codec
and mic/speaker codec.

This must be a common situation.  I'm curious how people are implementing
speex and the AEC?  Is there any benefit to resample?  Is the speex resample
code suitable for adjusting the sample rates that only differ by clock
crystal tolerances?  




More information about the Speex-dev mailing list