Difference between revisions of "Bit Rate Calculation"

Line 171: Line 171:
{| class="wikitable" border="1" cellspacing="0"
{| class="wikitable" border="1" cellspacing="0"
| <center>'''Audio Format'''</center>
| <center>'''Audio Format'''</center>
| <center>'''Audio Data Rate'''</center>
| <center>'''Audio Data Rate (Kbit/sec)'''</center>
<center>'''(Kbit/sec)'''</center>
| <center>'''Packet/sec (Wireshark)'''</center>
| <center>'''Packet/sec (Wireshark)'''</center>
| <center>'''Overhead without Ethernet (bit)'''</center>
| <center>'''Overhead without Ethernet (bit)'''</center>
Line 189: Line 188:
| <center>42.213</center>
| <center>42.213</center>
| <center>224</center>
| <center>224</center>
| <center>393.46</center>
| <center style="background-color:#FFB6C1">393.46</center>


|-
|-
Line 196: Line 195:
| <center>6.7</center>
| <center>6.7</center>
| <center>224</center>
| <center>224</center>
| <center>65.5</center>
| <center style="background-color:#FFB6C1">65.5</center>


|-
|-
Line 203: Line 202:
| <center>6.7</center>
| <center>6.7</center>
| <center>224</center>
| <center>224</center>
| <center>65.5</center>
| <center style="background-color:#FFB6C1">65.5</center>


|-
|-
Line 210: Line 209:
| <center>20.28</center>
| <center>20.28</center>
| <center>224</center>
| <center>224</center>
| <center>196.54</center>
| <center style="background-color:#FFB6C1">196.54</center>


|-
|-
Line 217: Line 216:
| <center>20.28</center>
| <center>20.28</center>
| <center>224</center>
| <center>224</center>
| <center>196.54</center>
| <center style="background-color:#FFB6C1">196.54</center>


|-
|-
Line 224: Line 223:
| <center>16.46</center>
| <center>16.46</center>
| <center>224</center>
| <center>224</center>
| <center>91.69</center>
| <center style="background-color:#FFB6C1">91.69</center>


|-
|-
Line 231: Line 230:
| <center>22.56</center>
| <center>22.56</center>
| <center>224</center>
| <center>224</center>
| <center>149.05</center>
| <center style="background-color:#FFB6C1">149.05</center>


|-
|-
| <center>MPEG1 48KHz</center>
| <center>MPEG1 48KHz quality 7, stereo</center>
 
<center>quality 7, stereo</center>
| <center>192</center>
| <center>192</center>
| <center>27.81</center>
| <center>27.81</center>
| <center>224</center>
| <center>224</center>
| <center>198.23</center>
| <center style="background-color:#FFB6C1">198.23</center>


|-
|-
Line 247: Line 244:
| <center>16.08</center>
| <center>16.08</center>
| <center>224</center>
| <center>224</center>
| <center>99.6</center>
| <center style="background-color:#FFB6C1">99.6</center>


|-
|-
| <center>MPEG1 44.1KHz </center>
| <center>MPEG1 44.1KHz quality 0, mono</center>
 
<center>quality 0, mono</center>
| <center>65</center>
| <center>65</center>
| <center>12.27</center>
| <center>12.27</center>
| <center>224</center>
| <center>224</center>
| <center>67.75</center>
| <center style="background-color:#FFB6C1">67.75</center>


|-
|-
| <center>MPEG1 44.1KHz </center>
| <center>MPEG1 44.1KHz quality 4, mono</center>
 
<center>quality 4, mono</center>
| <center>90</center>
| <center>90</center>
| <center>15.76</center>
| <center>15.76</center>
| <center>224</center>
| <center>224</center>
| <center>93.53</center>
| <center style="background-color:#FFB6C1">93.53</center>


|-
|-
| <center>MPEG1 44.1KHz </center>
| <center>MPEG1 44.1KHz quality 7, mono</center>
 
<center>quality 7, mono</center>
| <center>140</center>
| <center>140</center>
| <center>25</center>
| <center>25</center>
| <center>224</center>
| <center>224</center>
| <center>145.6</center>
| <center style="background-color:#FFB6C1">145.6</center>


|-
|-
Line 281: Line 272:
| <center>5.8</center>
| <center>5.8</center>
| <center>224</center>
| <center>224</center>
| <center>29.3</center>
| <center style="background-color:#FFB6C1">29.3</center>


|-
|-
Line 288: Line 279:
| <center>7.58</center>
| <center>7.58</center>
| <center>224</center>
| <center>224</center>
| <center>45.7</center>
| <center style="background-color:#FFB6C1">45.7</center>


|-
|-
| <center>MPEG2 16KHz</center>
| <center>MPEG2 16KHz quality 7, mono</center>
 
<center>quality 7, mono</center>
| <center>64</center>
| <center>64</center>
| <center>11.5</center>
| <center>11.5</center>
| <center>224</center>
| <center>224</center>
| <center>66.58</center>
| <center style="background-color:#FFB6C1">66.58</center>


|}
|}

Revision as of 08:19, 24 March 2009

BIT RATE CALCULATION WITH BARIX DEVICES

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 (with standard firmware) configured first in RAW UDP and then in RTP, and an Exstreamer 1000 (with STL firmware).


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)


Audio Format
Audio Data Rate (Kbit/sec)
Packet/sec (Wireshark)
Overhead (bit)
Total Bit Rate (Kbit/sec)
PCM 16 bit 8 KHz, mono
128
13.551
524
135.1
PCM 16 bit 24 KHz, mono
384
42.213
524
406.12
uLaw 8 KHz, mono
64
6.7
524
67.5
ALaw 8 KHz, mono
64
6.7
524
67.5
ALaw 24KHz, mono
192
20.28
524
202.62
uLaw 24 KHz, mono
192
20.28
524
202.62
MPEG1 48KHz quality 0, stereo
88
16.46
524
96.62
MPEG1 48KHz quality 4, stereo
144
22.56
524
155.82
MPEG1 48KHz quality 7
192
27.81
524
206.57
MPEG1 48KHz quality 4, mono
96
16.08
524
104.42
MPEG1 44.1KHz, quality 0, mono
65
12.27
524
71.43
MPEG1 44.1KHz, quality 4, mono
90
15.76
524
98.25
MPEG1 44.1KHz, quality 7, mono
140
25
524
153.1
MPEG2 16KHz quality 0, mono
28
5.8
524
31.03
MPEG2 16KHz quality 4, mono
44
7.58
524
47.97
MPEG2 16KHz quality 7
64
11.5
524
70


Without Ethernet Overhead


Audio Format
Audio Data Rate (Kbit/sec)
Packet/sec (Wireshark)
Overhead without Ethernet (bit)
Total Bit Rate without Ethernet (Kbit/sec)
PCM 16 bit 8 Khz, mono
128
13.551
224
131.4
PCM 16 bit 24 Khz, mono
384
42.213
224
393.46
uLaw 8 Khz, mono
64
6.7
224
65.5
ALaw 8 Khz, mono
64
6.7
224
65.5
ALaw 24KHz, mono
192
20.28
224
196.54
uLaw 24 Khz, mono
192
20.28
224
196.54
MPEG1 48KHz quality 0, stereo
88
16.46
224
91.69
MPEG1 48KHz quality 4, stereo
144
22.56
224
149.05
MPEG1 48KHz quality 7, stereo
192
27.81
224
198.23
MPEG1 48KHz quality 4, mono
96
16.08
224
99.6
MPEG1 44.1KHz quality 0, mono
65
12.27
224
67.75
MPEG1 44.1KHz quality 4, mono
90
15.76
224
93.53
MPEG1 44.1KHz quality 7, mono
140
25
224
145.6
MPEG2 16KHz quality 0, mono
28
5.8
224
29.3
MPEG2 16KHz quality 4, mono
44
7.58
224
45.7
MPEG2 16KHz quality 7, mono
64
11.5
224
66.58



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)


Audio Format
Audio Data Rate (Kbit/sec)
Packet/sec (Wireshark)
Overhead (bit)
Total Bit Rate (Kbit/sec)
ALaw 8 Khz, mono
64
50
652
96.2
MPEG1 48KHz quality 0, stereo
88
41.7
652
115.2
MPEG1 48KHz quality 4, stereo
144
41.7
652
171.2
MPEG1 48KHz, quality 7, stereo
192
41.7
652
219.2
MPEG1 48KHz quality 4, mono
96
41.7
652
123.2
MPEG1 44.1KHz, quality 0, mono
65
38.3
652
90
MPEG1 44.1KHz, quality 4, mono
90
38.3
652
114.97
MPEG1 44.1KHz, quality 7, mono
140
38.3
652
164.97
MPEG2 16KHz quality 0, mono
28
27.8
652
46.12
MPEG2 16KHz quality 4, mono
44
27.8
652
62.12
MPEG2 16KHz, quality 7, mono
64
27.8
652
82.12



Without Ethernet Overhead


Audio Format
Audio Data Rate (Kbit/sec)
Packet/sec (Wireshark)
Overhead (bit)
Total Bit Rate (Kbit/sec)
ALaw 8 Khz, mono
64
50
352
81.6
MPEG1 48KHz quality 0, stereo
88
41.7
352
102.67
MPEG1 48KHz quality 4, stereo
144
41.7
352
158.67
MPEG1 48KHz, quality 7, stereo
192
41.7
352
206.67
MPEG1 48KHz quality 4, mono
96
41.7
352
110.67
MPEG1 44.1KHz, quality 0, mono
65
38.3
352
78.48
MPEG1 44.1KHz, quality 4, mono
90
38.3
352
103.48
MPEG1 44.1KHz, quality 7, mono
140
38.3
352
153.48
MPEG2 16KHz quality 0, mono
28
27.8
352
37.78
MPEG2 16KHz quality 4, mono
44
27.8
352
53.78
MPEG2 16KHz, quality 7, mono
64
27.8
352
73.78

Back to FAQ