Post on 14-Dec-2015
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
RTP ndash Real Time Protocol (and RTCP)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
RTPbull Signaling can be mediated by devices in the middle
of the network (SIP Proxies softswitches gatekeepers etc)ndash For SIP this is the typical call flow (draw ex)ndash For H323 gatekeeper direct is typical which means
signaling typically happens between endpoints (draw ex)
bull RTP (media) often occurs between the endpoints although there are important instances where this is not the casendash Some enterprise (cisco call manager) firewall issuendash Blind re-file (wholesale)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
RTP
bull RTP ndash carries real time databull RTPC ndash control port that carries information to
monitor quality of service
+1 port
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works (2)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
RTPbull Signaling can be mediated by devices in the middle
of the network (SIP Proxies softswitches gatekeepers etc)ndash For SIP this is the typical call flow (draw ex)ndash For H323 gatekeeper direct is typical which means
signaling typically happens between endpoints (draw ex)
bull RTP (media) often occurs between the endpoints although there are important instances where this is not the casendash Some enterprise (cisco call manager) firewall issuendash Blind re-file (wholesale)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
RTP
bull RTP ndash carries real time databull RTPC ndash control port that carries information to
monitor quality of service
+1 port
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works (2)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
RTP
bull RTP ndash carries real time databull RTPC ndash control port that carries information to
monitor quality of service
+1 port
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works (2)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works (2)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works (2)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
How this all works (2)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example
bull For G729 voice is 8 kbitssec Assume 20ms payloadbull Packet payload size = 8 kbitssec X 20ms = 160 bits = 20 bytespacket IP
Packet = 60 bytes
bull For Cisco HDLC (cisco-cisco router serial) add 5 bytes header 3 bytes trailer Bandwidth = (63 bytes20ms)(8 bitsbyte) = 252 kbps
bull Efficiency = 8 kbs 252 kbs ~ 32 Number of packetssec = 1sec02sec Loss of 1 packetsec = 2 packet loss
ΔDelay = buffer (20ms) + codec delay + layer23 delay + queuing delay + codec delay
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth requirement G729 Example 2
bull Assume 60 ms packetsbull Packet payload size = 8 kbitssec X 60ms = 60 bytespacket IP Packet
= 60 bytes
bull For ethernet 14 byte header 4 byte trailer =gt bandwidth = (118 bytes60ms)(8bitsbyte) = 157 kbs
bull Efficiency = 8 kbs 157 kbs ~ 50 Number of packetssec = 1sec06sec Loss of 1 packetsec = 6 packet loss
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
60 bytesEthernet14 bytes
Ethernet4 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codec Table
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
What is iLBCiLBC (internet Low Bitrate Codec) is a FREE sppech codec suitable for robust voice communication over IP The codec is designed for narrow band speech and results in a payload bit rate of 1333 kbps with an encoding frame length of 30 msec and 1520 kbps with an encoding length of 20 msec The iLBC codec enables graceful speech quality degradation in the case of lost frames which occurs in connection with lost or delayed IP packets
Featuresbull Bitrate 1333 kbps (399 bits packetized in 50 bytes) for the frame size of 30 msec and 152 kbps
(303 bits packetized in 38 bytes) for the frame size of 20 msecbull Basic quality higher then G729A high robustness to packet lossbull Computational complexity in a range of G729Abull Royalty Free Codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash PacketCable SpecCodecs defined in this specification MUST be encoded witht he following string names in the rtpmap parameter
Codec RTP Map Parameters
For the use in the SDP the Rtpmap parameter (ie PCMU8000 in the case of μ-law) is used Unknown Rtpmap parameters SHOULD be ignored if they are received
133 and152 kbps
kbps
16 kbps
8 kbps
118 kbps
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Codecs ndash ldquoYour mileage may varyrdquobull Large perceived quality difference between PSTN quality
(MOS=41) and cell quality (MOS=35)bull Codecs respond differently to packet loss delay noise
multiple transcodings etc Itrsquos not just the MOSPSQM measurement that counts
bull There are also licensing issues ($$) what the call is being used for (messaging conferencing etc) and DSP HP required
bull The number of framespacket can be dynamically adjusted to tradeoff quality for efficiency
bull Header compression can drastically improve efficiency ndash at the expense of router processing power
bull VoIP Community has ndash for the most part ndash converged around G711 G729 Some application for G726 (packs better into ATM) EE thinks that GSM interworking is very important
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Speech Coders Lots of Code DSP intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Bandwidth reductionbull IP ndash almost by definition - is less bw efficient than PSTNbull Bandwidth reduction where the cost for bandwidth is at a
premium ndash typically tail circuits or some international destinations
bull VAD (Voice Activity Detection) Rule of thumb is 13-12 reduction in bw Cost is voice quality (clipping) poor performance in conferencing
bull Header Compressionndash Compressed RTP Hop-to-hop requires
decompression and compression at each hop For G279 = 128 kbs
ndash VoMPLS New not sure of what it takes beyond MPLS End-to-end (not hop-to-hop) likely to be much less router CPU intensive
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Header Compression Example
bull Conventional frame G729 = 252 kbps
bull Compressed frame G729 = 128 kbps
CRTP4 bytes
G729 Payload20 bytes
IP 20 bytesUDP
8 bytesRTP
12 bytesG729 Payload
20 bytesHDLC
5 bytesHDLC
3 bytes
HDLC5 bytes
HDLC3 bytes
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
wav
bull MicrosoftIBM Specbull PCM with bandwidth = SxBxC
ndash S = Sample Rate (samplessec)ndash B = BitsSamplendash C = Channels
bull For example audio might be 44 kHz sampling rate at 16 bitssample and 2 channels = 14 Mbs
bull Another example might be voice mail in an email attachment (try it ndash right click on a wav file) ndash 8kHz sampling and 16 bitssample = 124 kbs
bull Conversion between audio formats Interesting (how do you go from compressed format to un-compressed formats)
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Tradeoffs ndasha Efficiency vs Latency amp Packet Lossb Codec bandwidth vs CPU cycles
bull Short Packets = low latency tolerates packet loss better inefficient
bull Large Packets = long latency (got to wait for buffer to fill up before shipping out packet) does not tolerate packet loss as well (loss of many bytes hurts) more efficient
bull Narrowband high quality codecs =gt more processing (cpu cycles) than either poor quality or less compression
bull Why not something BETTER than G711
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Voice Codecs ndash Bandwidth Consumption
Pulse Code Modulation
Codec(compression)
Buffer
Layer 3 (RTPUDPIP)+Layer 2 Encapsulation
Analog waveform 64 kbps
6-16 kbps ~10-40
msec
40 bytessec
Physical Layer (wire)
Getting from pt A to pt B
Layer 23
Jitter Buffer
~1-2 packets
CodecPCM
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Transcoding ndash From codec to codec
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Marginal delay - Example
bull Δ Delay = buffer + codec + layer23 + queuing + network congestion + jitter + codec
bull If buffer = 20ms codec = 12ms layer23 = 2ms queuing = 1ms jitter = 20ms =gt Delay ~ 70 ms
bull Rule of thumb =gt Total Delay lt 150ms for Toll Quality If NY LA is 35 ms itrsquos OK If NY 1048793 Sydney = 100 ms itrsquos marginal
bull Total Delay = point-point delay (cn + ) + Δ Delaybull Transcoding = twice the Δ Delay =gt itrsquos a killer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Distances (NY to) amp One Way Delay
bull Discrepancy Between Calculated and Actual Delaysndash Great Circle vs as the railroadscables runndash Multiple Hopsndash Congestion
1 2
1 great circle route
2 httpipnetworkbgtmoipattnetpwsnetwork_delayhtml
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Jitter- not such a big deal in modern networks
bull Why is Jitter Importantndash If jitter gt receive buffer size jitter = packet
loss
bull Tradeoff between Receive Buffer Size and Latencyndash Bigger Receive Buffer =gt Better immunity to
packet jitter But longer latency
bull It all depends but it is typical to have a +- 1 pakcet jitter buffer
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Summary (PAMS listening score only)
What about wideband codecs (G722 speex AAC etc) Should also include wireless codecs including GSM and the CDMA equivalent
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made
Copyright 2003-2010 copy by Elliot Eichen All rights
reserved
Why VoIP so cool
bull The codecs make the voice sounds lousy
bull Itrsquos less efficient than circuit switched voice
bull It has all these QoS issues (latencypacket loss)
bull Itrsquos driven down the price that can be charged for a call so that there are no $$ to be made