|
Project Information
Featured
Links
|
ns2-app is a simple-to-use framework to simplify application layer simulations on NS2. BE CAREFUL, it's only tested on NS2.33 above, but it should work on some older versions as it doesn't change any existing code. Why this frameworkNS2 supports only unreal applications that just contain the length of packets. There do exist some real applications, but they are difficult to reuse, or even restricted to a specific type of applications. Therefore, we decide to write this framework trying to reduce the difficulty. Also, a P2P framework is to be provided based on it. Usage- The application layer simulation framework
- Download the latest source code here, uncompress it into the ~/ns-2.33/ directory, and recompile NS. BE CAREFUL, it will overwrite the original Makefile. But you can also modify the Makefile yourself by adding -I./real-app to the INCLUDES section and real-app/adu.o real-app/wrapper.o real-app/real-app.o real-app/test/test.o to the OBJ_CC section.
- Derive a class from ADU to represent the application layer data, and rewrite the size function. The packets are sent by calling the RealApplication::send() function
- Derive a class from RealApplication to represent the application, and rewrite the recv function which is called when a packet is arrived.
- Derive a class from TclClass to combine the application in C++ with OTcl.
- Write an OTcl script to configure the simulation.
- The P2P application
- It's still under development.
|