Skype for Business Wideband PSTN access – why Microsoft should really enable G.722

News on 28 Apr , 2016

If you ever deployed any SIP trunk in a multi-vendor enterprise environment, the very first thing you need to decide, what kind of codec I want to use on the SIP trunk. Normally in traditional IP telephony networks the well-known practice is to use compressed codecs like G.729 over the wide area network.  Sometimes Service Providers are strict in the codec choice, you might need to select one of the codecs offered from them. If you select G.729 because this is what your current IP telephony environment supports then later on you might have problem when you would like to connect your Lync/SfB environment as mediation server only supports G.711. In this case you need to have some transcoding capacity in your Session Border Controller which can translate G.711 into G.729 and vica-versa.


DSPs are normally not cheap and there might be some possible quality degradation as well, therefore transcoding is something you should try to avoid. The other possibility is to choose G.711 which might put additional bandwidth demand to your WAN infrastructure but compared to the early 2000s, bandwidth costs dropped significantly and at the end you will have slightly better quality.


Wideband audio codecs have been around for a while, we use it on our mobile, we use it on Skype For Business. It gives much better quality while the bandwidth requirements are basically equal to G.711.

Codec Information Bandwidth Calculations
Codec & Bit Rate (Kbps) Codec Sample Size (Bytes) Codec Sample Interval (ms) Mean Opinion Score (MOS) Voice Payload Size (Bytes) Voice Payload Size (ms) Packets Per Second (PPS) Bandwidth MP or FRF.12 (Kbps) Bandwidth w/cRTP MP or FRF.12 (Kbps) Bandwidth Ethernet (Kbps)
G.711 (64 Kbps) 80 Bytes 10 ms 4.1 160 Bytes 20 ms 50 82.8 Kbps 67.6 Kbps 87.2 Kbps
G.729 (8 Kbps) 10 Bytes 10 ms 3.92 20 Bytes 20 ms 50 26.8 Kbps 11.6 Kbps 31.2 Kbps
G722_64k (64 Kbps) 80 Bytes 10 ms 4.13 160 Bytes 20 ms 50 82.8 Kbps 67.6 Kbps 87.2 Kbps


And then we arrived to the point where this topic is becoming interesting, as service providers started to offer HD Audio Codecs (G722) on their SIP trunks. Wait a second, didn’t you just tell Lync/SfB only supports G.711? Yes, that’s true for the mediation server but if you are having a close look in the SfB client’s SIP/SDP you can clearly see the client is advertising G722. Well Ok, this still not solves the problem that mediation server strips off everything. In fact this is only true in non-media-bypass scenario, if you have media bypass turned on then all the SDP parameters will be passed to the PSTN gateway as you can see it in this outgoing INVITE.


Now lets have a look at the incoming 200 OK.


As you can see the only offered codec coming from the gateway is G722. The call setup is done properly and HD Audio codec is used. This is something you can utilize to have Wide-Band audio between your SfB and your IP-PBX (e.g. Cisco UCM) environment as well.


Of course this kind of setup is not supported by Microsoft, so there is no guarantee that it will work after the next CU updates, also in certain cases Media Bypass cannot be used (e.g. dial-in and remote Edge access). These days when even Service Providers are discussing about enhanced codecs (like G.722) over national interconnects, I think Microsoft should really consider of enabling it in the Mediation servers.