How to calculate the bandwidth consumed by a single voice

Source: Internet
Author: User

Learn about it:

 

In terms of voice, how does one calculate the bandwidth consumed by codec?
By default, after the analog voice is converted to a digital voice, it is cut in 20 ms segments for 20 ms segments, encapsulated with RTP, and then wrapped with UDP header, IP header, finally, the packet header of Layer 2 is sent out.

Suppose we use g.729 encoding and transmit it over Ethernet. Calculate the bandwidth required for a single voice.

G.729 the conversion starts when each voice is 8 kbit/s.
1000 bps/8 = 1000 bytes/s, get g.729 bandwidth bytes per second

By default, No 20 ms of voice is encapsulated into a packet, so you can calculate the number of packages sent within one period.
1 S/20 Ms = 50

That is to say, g.729 requires a bandwidth
1000 bytes/S/50 = 20 Bytes/s

Next, the Ethernet frame header is 6-byte, the IP packet header is 20-byte, The UDP packet header is 8-byte, And the RTP packet header is 12-byte.
In this way, the payload of g.729 is 20 bytes.
That is to say, a 6 + 20 + 8 + 12 + 20 = 66-byte frame is generated every 20 ms.
Then 50 66-byte will be sent in one second, which is equal to 3300-byte and converted to kbit/s.
3300 byte/S * 8/1000 = 26.4 kbit/s

Finally, the bandwidth occupied by g.729 voice (including Layer2 header) is 26.4 kbps.

 

 

 

From: http://blog.csdn.net/force_eagle/archive/2007/10/22/1836423.aspx

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.