A framework named "ns2-app" is developed and maintained by Xizhi Zhu to simplify the application layer simulations on NS-2. 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 framework NS2 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...
When you’re curious, you find lots of interesting things to do.