Building The OSLEC Echo Canceller

Many people have had good success with the OSLEC echo canceller. Its performance is claimed to be much better than some of the other echo cancellers that are available.

Unfortunately, this echo canceller is not yet included in the DAHDI build. In order to use it, you will have to go get the source yourself and then enable the "experimental" lines in the build rules that cause OSLEC to be built. You can try it, if you want, by following these instructions. But, we haven't been able to get the echo canceller built via this build process to install properly so it is probably best to skip ahead to Building The OSLEC Patch, below.

The source for OSLEC is actually found in the kernel build sources (2.6.28 and later), since this echo canceller is now part of the kernel. So, in order to get the source, you need to fetch the kernel source for (at least) 2.6.28. Take the first three sets of digits (before the dash) of the kernel that you wish to fetch and plug them into these commands:

     cd .../asterisk
     wget http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.28.tar.bz2
     tar -xvjf linux-2.6.28.tar.bz2

At this point, you can't get there from here. You need to install the source from the Linux kernel into the DAHDI source tree. But, the DAHDI source tree hasn't been built yet. So, we'll do things out of order here and extract the DAHDI source (you can skip this step in the next section):

     tar -xvzf dahdi-linux-complete*.tar.gz

Now, we can make a directory in the DAHDI source tree to hold the OSLEC echo canceller, copy the kernel source and then remove the kernel source tree (we don't really need it):

     cd dahdi-linux-complete*
     mkdir linux/drivers/staging
     cp -Rf ../linux-2.6.28/drivers/staging/echo linux/drivers/staging
     cd ..
     rm -rf linux-2.6.28

Now, edit drivers/dahdi/Kbuild and uncomment the two lines related to OSLEC. When DAHDI is built (in the Building DAHDI section), the OSLEC echo canceller should be built too.