Asterisk SPA-841 Sound Quality

Sipura SPA-841 Sound Quality Issues with Asterisk

This page is intended to address sound quality problems which result from using the Sipura SPA-841 SIP phones with an Asterisk PBX. Some of the hints and configuration items on this page may be appropriate for other Sipura devices as well, but my experience is primarily with the SPA-841. After initial work with the new SPA-941, I think almost everything here is applicable to that phone as well.

This is a work in progress, describing issues we have come across and how we fixed them. If you have solved any audio issues with Sipura SIP devices, please add any insights you have, if they may help others.

SPA-841 Configuration

Some of the default configuration settings for the SPA-841 are incompatible with Asterisk, and "must" be changed to provide optimum sound quality in use with an Asterisk server. These settings are all available on the Advanced Admin configuration page of the SPA's web interface configuration.

RTP packet size: 0.020

On the "SIP" tab of the Advanced Admin page, the "RTP packet size" is shown, measured in seconds. It defaults to 0.03, but Asterisk is hardcoded to use 0.02.

Silence Supp Enable: Off

On the "Ext1" and "Ext2" tabs of Advanced Admin, the "Silence Supp Enable" option must be turned off. This is Silence Suppression, which causes the phone to stop sending RTP packets when the phone detects silence in the handset. Asterisk does not support silence suppression, so this option must be turned off, or audio stream timing will fail a lot.

Other issues

These potential sources of sound quality issues are not necessarily unique to the SPA-841, but they came up when we were debugging sound problems with our SPA-841's.

Ethernet Duplex Mismatch

Ethernet ports can be set to either "half duplex" or "full duplex". Most of the time, ports are set to auto-negotiate this setting with the connected interface. You may experience problems if two connected ethernet interfaces are set to use different duplexes, or if autonegotiation fails (we've seen this when one side is set to autonegotiate and the other is not). Duplex mismatch can cause some of the same symptoms as massive packet loss (dropout, "robotic voice").

Unfortunately, we have not figured out how to tell what duplex the SPA-841 thinks it's using. We have had good luck so far using half duplex, since full duplex is uncommon on many 10 base T devices.

Decode latency: what causes it?

We found on the SPA-841's status page that although we had no jitter, negligible packet loss, and low round-trip times, the "decode latency" was sometimes "very" high (300ms or more) at the time we experienced audio problems.

We are not sure what causes this decode latency, yet. However, our current theory is that it is caused by excessive broadcast traffic on the local network.

Broadcast Traffic

We had our SPA-841's on a fully switched network, using gigabit ethernet switches in the backplane. For the most part there wasn't any traffic reaching the VoIP phones other than traffic specifically destined for each individual phone.

However, we did have a substantial amount of ARP broadcast traffic reaching the SIP phones. This was nowhere near enough to saturate the link, but it seems to have caused problems for us anyway. We have put some of our phones on a completely separate network to avoid this ARP traffic, and so far we have not had the audio problems we previously had.

Our current theory is: While most ethernet interfaces are clever enough to drop packets not intended for that interface without bothering the host system, perhaps the SPA-841 ends up using CPU cycles to discard these unneeded ARP packets. If so, lots of incoming ARP traffic might distract the phone enough that it doesn't have enough cycles left to decode the incoming RTP stream fast enough.

More Information

I've found to be a very good source of information for diagnosing and fixing sound quality issues. It provides .wav files which demonstrate what various kinds of sound issues sound like, and information on what those issues might be caused by.

See Also

Created by: ferrency, Last modification: Wed 15 of Jun, 2011 (09:07 UTC) by voipsiporg
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+