You are on page 1of 11

What you eat, What you read

ABOUT

LOT, I LEARNED

VIDEO STREAM OVER HSDPA


UNDER NS2 SIMULATION
ENVIRONMENT: TUTORIAL
JANUARY 13, 2013
COMMENT

YOANDA ALIM SYAHBANA

LEAVE A

Instalation
1.
2.
3.
4.
5.

Install Cygwin
Install ns2 2.28
Install Evalvid
Install MyEvalvid_RTP
Install VLC media player. This tutorial uses VLC 0.8.6a.

Video Stream SImulation


1. Run VLC.
open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

2. Click File > Open File.


3. Click Browse > select video file > Click Open.
4. In Advance Option group box, Check stream/save
and Click settings.
5. In Outputs group box, Check RTP and Input real Virtual PC IP
address and port number (Input: 1234).
6. Click OK in stream output dialog and return to open dialog. Do
not click OK in this open dialog.
7. Run Cygwin, go to RTPtools directory. Type: cd c: .
8. Press Enter button in keyboard.
9. Type: cd cygwin/home/computer user name/ns-allinone2.28/ns-2.28/mympeg/ern_evd) .
10. Press Enter button in keyboard.
11. Type: ./rtpdump F hex real Virtual PC IP address/1234 > aaa .
12. Press Enter button in keyboard,
13. Return to VLC program, click OK in open dialog.
14. The video will be played and streamed out, and received by
RTPdump. The data received will be saved in aaa file.
15. When finishing streaming, return to the cygwin and do ctrl+C to
stop receiving the data.
16. Re-execute rtpdump program, but change parameter to become
-F dump. This is because we have to save the data payload of
each rtp packet. Type: ./rtpdump F dump real Virtual PC IP
open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

address/1234 > bbb


17. Press Enter button in keyboard .
18. Click play in VLC
19. When finishing streaming, remember to return to the cygwin and
do ctrl+C to stop receiving the data.
20. Close VLC
21. Now, we have aaa and bbb file in c:/cygwin/home/computer
user name/ns-allinone-2.28/ns-2.28/mympeg/ern_evd directory.
22. Execute work1.exe program to analyze the information of aaa
file. Type: ./work1.exe .
23. Press Enter button in keyboard .
24. Type: aaa (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work1.exe) .
25. Press Enter button in keyboard .
26. Type: st_a00 (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work1.exe). st_a00 is referred to
stream trace variable that used in wireless scenario.
27. Press Enter button in keyboard.
28. We get st file in c:/cygwin/home/computer user name/nsallinone-2.28/ns-2.28/mympeg/ern_evd directory.
29. Executes wireless scenario. Type: ns Evalvid_eurane.tcl 1.
30. Press Enter button in keyboard.
31. After the simulation there will be sd_a00 and rd_a00 files in
open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

c:/cygwin/home/computer user name/ns-allinone-2.28/ns2.28/mympeg/ern_evd directory.


32. Execute work2.exe program. Type: ./work2.exe .
33. Press Enter button in keyboard.
34. Type: rd_a00 (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work2.exe).
35. Press Enter button in keyboard.
36. Type: lost (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work2.exe).
37. The rd_a00 file we input is receiver trace file, and lost file record
mainly the packets which are lost when transmitting.
38. Press Enter button in keyboard.
39. Type: 1328 (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work2.exe).
40. 1328 is rtp packet payload size, not input total packet size. The
size of sd and rd files is IP header + UDP header + rtppayload.
We need rtp payload size here, read from second column in st
file.
41. Press Enter button in keyboard.
42. We get lost file in c:/cygwin/home/computer user name/nsallinone-2.28/ns-2.28/mympeg/ern_evd directory.
43. Execute work3.exe program, this program will analyze lost file
and remove the lost information from data received by rtpdump.
open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

Therefore, we can obtain the data which is the same as received in


the receiver (such as ccc file).
44. Type: ./work3.exe .
45. Press Enter button in keyboard.
46. Type: lost (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work3.exe).
47. Press Enter button in keyboard.
48. Type: bbb (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work3.exe).
49. Press Enter button in keyboard.
50. Type: ccc (if you mistyped this input, just press Enter button in
keyboard, and repeat to execute work3.exe).
51. Press Enter button in keyboard.
52. We get ccc file in c:/cygwin/home/computer user name/nsallinone-2.28/ns-2.28/mympeg/ern_evd directory.
53. Re-execute VLC.
54. Click File->Open Network Stream.
55. Make sure, the configuration in UDP/RTP option and the port is
1234.
56. Check Stream/Save and click Settings.
57. Check File.
58. Click Browse. Input the filename you want to save the streaming
result. Type: distorted.mp4 ).
open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

59. Click Save.


60. Check MP4 in Encapsulation Method group box.
61. Click OK.
62. Click OK.
63. Transmit ccc file to VLC program by rtpplay. Type: ./rtpplay v f
ccc real Virtual PC IP address/1234.
64. Press Enter button in keyboard.
65. The content of ccc file is recorded by VLC. Wait until the process
complete.
66. Press Stop in VLC program.
67. Now we have video result in place where we save the result
distorted.mp4. We can use media player to view the video
results.
*For the .tcl file, I use combination of coding from EURANE sample
code and simulation tutorial from Chia-Yu Yu in
publication MyEvalvid_RTP: A New Simulation Tool-set Toward
More Realistic Simulation. I hope this tutorial will be useful for you.
For suggestion and correction regarding this tutorial, just drop a
polite comment belows..
About these ads

open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

SHARE THIS:
Tw eet

Like

Print

Email

Like
Loading...
Be the first to like this.

FFMPEG

MYEVALVID_RTP

NS2

TUTORIAL

VIDEO STREAM SIMULATION

open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

PREVIOUS POST

The Verb Class


NEXT POST

It is a No for Racism

LEAVE A REPLY
Enter your comment here...

Search

RECENT POSTS

open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

Katanya sih begitu


First and more to come Aamiin.. :D
2014 in review
Peterpan-What the matter with you
Manfaat Pretest di Awal Perkuliahan
Peterpan-2DSD
Chapter #43
Peterpan-Mask
Apakah sekolah itu hanya untuk orang yang pintar saja?
Mengagumi Luasnya Ilmu Alloh : Belajar dari sebuah kata Tidak/Jangan
Apakah Sekolah Kita Sudah Beradab?

CATEGORIES

Aphorist Author (9)


B-right Brain (37)
Contemplated Curiosity (9)
open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

Draw Dream Done (11)


I Learned (2)
Lot (2)
Lot, I Learned (28)
Trip Trail's (2)
Uncategorized (3)

FOLLOW ME ON TWITTER
My Tweets

FOLLOW BLOG VIA EMAIL


Enter your email address to follow this blog and receive notifications of new posts by email.

Enter your email address


FOLLOW

open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

BLOG STATS
2,378 hits

Follow

The Twenty Fourteen Theme. Create a free website or blog at WordPress.com.

Follow What you


eat, What you
read
Get every new post delivered
to your Inbox.
Join 790 other followers
Enter your email address

SIGN ME UP
Build a website with WordPress.com

open in browser PRO version

Are you a developer? Try out the HTML to PDF API

pdfcrowd.com

You might also like