Install and run Aqua-Sim-NG code

From Zheng Peng's Wiki
Revision as of 08:41, 17 August 2018 by Dmitrii (talk | contribs) (How-To)
Jump to: navigation, search

How-To build ns-3 + aqua-sim

  • download and unpack ns-3.27 source code:

wget http://www.nsnam.org/release/ns-allinone-3.27.tar.bz2

tar xjf ns-allinone-3.27.tar.bz2

Note: Aqua-Sim-NG has been tested with ns-3.27. The higher versions of ns-3 (i.e., 3.28, 3.29) might not be compilable with aqua-sim modules.

  • get aqua-sim source code:

- move to ../src directory of ns-3:

cd "ns-3_working_dir/ns-3.27/src/"

- for multichannel MAC development:

git clone https://github.com/dugdmitry/aqua-sim-ng.git

- original version from main repository:

git clone https://github.com/rmartin5/aqua-sim-ng.git

  • build ns-3 with aqua-sim source code:

- change to ns-3 working directory:

cd "ns-3_working_dir/ns-3.27/

- configure and build using "waf":

./waf clean

./waf configure --build-profile=debug --enable-examples

./waf


How-To run examples

After building ns-3 + aqua-sim, simulation scripts can be run using ./waf --run 'script_name' command.

The scripts are located in "/scratch" folder, and also in "examples" folders of the corresponding ns-3 models, located in "src/" folder.

E.g., the corresponding examples of aqua-sim models are located in ../src/aqua-sim-ng/examples/

Note: Names of the scripts to execute may differ from the names of the corresponding .cc files.

For example, in order to run "../src/aqua-sim-ng/examples/multichannel_mac_example.cc" script, the following command should be executed:

./waf --run ./waf --run MultichannelMacExample

'script_source_name.cc' and corresponding 'script_name' mapping can be found in "../src/model_name/examples/wscript" file.