Difference between revisions of "Bit Rate Calculation"
Line 188: | Line 188: | ||
------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- | ||
{| class=" | {| class="wikitable" border="1" cellspacing="0" | ||
| <center>'''Audio Format'''</center> | | <center>'''Audio Format'''</center> | ||
| <center>'''Audio Data Rate (Kbit/sec)'''</center> | | <center>'''Audio Data Rate (Kbit/sec)'''</center> | ||
| <center>'''Packet/sec'''</center> | | <center>'''Packet/sec'''</center> | ||
| <center>'''Overhead (bit)'''</center> | | <center>'''Overhead (bit)'''</center> | ||
| <center>'''Total Bit Rate (Kbit/sec)'''</center> | | <center style="background-color:#FFB6C1">'''Total Bit Rate (Kbit/sec)'''</center> | ||
|- | |- | ||
Line 200: | Line 200: | ||
| <center>50</center> | | <center>50</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>95</center> | | <center style="background-color:#FFB6C1">95</center> | ||
|- | |- | ||
Line 207: | Line 207: | ||
| <center>41.7</center> | | <center>41.7</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>113.8</center> | | <center style="background-color:#FFB6C1">113.8</center> | ||
|- | |- | ||
Line 214: | Line 214: | ||
| <center>41.7</center> | | <center>41.7</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>169.85</center> | | <center style="background-color:#FFB6C1">169.85</center> | ||
|- | |- | ||
Line 221: | Line 221: | ||
| <center>41.7</center> | | <center>41.7</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>217.85</center> | | <center style="background-color:#FFB6C1">217.85</center> | ||
|- | |- | ||
Line 228: | Line 228: | ||
| <center>41.7</center> | | <center>41.7</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>121.85</center> | | <center style="background-color:#FFB6C1">121.85</center> | ||
|- | |- | ||
Line 235: | Line 235: | ||
| <center>38.3</center> | | <center>38.3</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>88.7</center> | | <center style="background-color:#FFB6C1">88.7</center> | ||
|- | |- | ||
Line 242: | Line 242: | ||
| <center>38.3</center> | | <center>38.3</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>113.7</center> | | <center style="background-color:#FFB6C1">113.7</center> | ||
|- | |- | ||
Line 249: | Line 249: | ||
| <center>38.3</center> | | <center>38.3</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>163.7</center> | | <center style="background-color:#FFB6C1">163.7</center> | ||
|- | |- | ||
Line 256: | Line 256: | ||
| <center>27.8</center> | | <center>27.8</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>45.2</center> | | <center style="background-color:#FFB6C1">45.2</center> | ||
|- | |- | ||
Line 263: | Line 263: | ||
| <center>27.8</center> | | <center>27.8</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>61.2</center> | | <center style="background-color:#FFB6C1">61.2</center> | ||
|- | |- | ||
Line 270: | Line 270: | ||
| <center>27.8</center> | | <center>27.8</center> | ||
| <center>652</center> | | <center>652</center> | ||
| <center>81.2</center> | | <center style="background-color:#FFB6C1">81.2</center> | ||
|} | |} |
Revision as of 09:40, 16 March 2009
With this document we want to explain how to calculate the total bit rate flowing on an Ethernet cable connected to a Barix device.
The total bit rate is equal at the audio bit rate plus the overhead due to the encapsulation of audio packet inside the layers of OSI stack [1].
We have used for the test an Instreamer 100 configured first in RAW UDP and then in RTP.
RAW UDP STREAMING MODE
For the structure of the Ethernet packet see here: [2]
The Total Ethernet Overhead per packet is 300 bit.
For the structure of the IP packet see here: [3]
The Total IP Overhead per packet is 160 bit.
For the structure of the UDP packet see here: [4]
The Total UDP Overhead per packet is 64 bit.
Total Bit of Overhead per Packet = Ethernet Overhead + IP Overhead + UDP Overhead = 524 bit
The Audio Bit rate is expressed in bit/sec but the Overhead is expressed in bit/packet.
So we have to translate the Overhead (bit/packet) in Overhead rate (bit/sec).
For this we need to know the amount of packet/sec, that depends by Audio Format and is measurable with Network Protocol Analyzer software like Wireshark.
The values of Audio Data for audio format, sampling frequency and quality (MP3 bitrate average), come from Instreamer Manual (firmware V3.10 – page 18 - [5])
Overhead/sec = Overhead/Packet x Packet/sec
Total Bit Rate (Kbit/sec) = Audio Data Rate (Kbit/sec) + Overhead/sec (Kbit/sec)
(Kbit = 1000 bit)
RTP STREAMING MODE
For the structure of the RTP packet see here: [6]
The Total RTP Overhead per packet is 128 bit (counting also the MP3 MPA wrapper inside the RTP payload, which has an extra 32 bit header).
Total Bit of Overhead per Packet =
Ethernet Overhead + IP Overhead + UDP Overhead + RTP Overhead = 652 bit
The values of Audio Data for audio format, are the same of above, since the transmission protocol doesn't affect audio bit rate.
Overhead/sec = Overhead/Packet x Packet/sec
Total Bit Rate (Kbit/sec) = Audio Data Rate (Kbit/sec) + Overhead/sec (Kbit/sec) (Kbit = 1000 bit)