The ns-3 Network Simulator Project
Transfer actual data in ns-3 packets
ns-3 provides a SetFill method in UdpEchoClient which can be used to pass actual data in ns-3 packets. examples/tutorial/first.cc is a basic C++ program provided for ns-3 beginners. A line by line explanation of first.cc is provided in the ns-3 tutorial. Understand the working of first.cc from the tutorial, and then proceed with the following steps:
- Copy first.cc from examples/tutorial and paste it in scratch directory.
- Enable PCAP tracing in first.cc and verify whether two PCAP files are generated properly.
- Refer examples/udp/udp-echo.cc to understand the usage of SetFill method.
- Modify first.cc to use SetFill method. Pass the string "Google Code In" to SetFill method, and then compile and run the program.
- Verify whether the string "Google Code In" appears in both the PCAP files.
- Submit both the PCAP files for evaluation.
- Submit the patch containing the changes made to first.cc for evaluation.
Task tags
Students who completed this task
Parth Pratim, ErykMikolajek, Asanali, Victor Hu, sikfeng, bartekche