nrlsensorsim-2.27 installation

来源:互联网 发布:wps word表格数据计算 编辑:程序博客网 时间:2024/06/05 05:07

转载自:http://netemu.cn/NetworkSimulation/NS/20071028/242-1.html

under the assistance of season and some other essenstial reply on this website, today nrl'sensorsim-2.27, together with ns-2.27, has been sucessfully installed on my laptop running winxp+ cygwin.

nrl'sensorsim is an extension for simulating wireless sensor network. it supports dual MAC interfaces in one snesor node which is capable of detecting phenomennon signals from nearby phnomenon nodes and communicating with other peer sensor node in ad hoc manner to relay information back to data collection point. on the website, http://pf.itd.nrl.navy.mil/nrlsensorsim/ , the author details two versions of extension for counterpart ns2. detailed instructions are also listed.

my trial in installing ns-2.26 fails due to some weird reasons, probably lacking of relevant patch for ns-2.26. but i succeeded in fixing ns-2.27 and counterpart nrl'sensorsim-2.27. Therefore, i list the procedure here in order to facilitate someone who might come across the same prob.

step1: download necessary materials including:
       1) nrlsensorsim-2.27 and ns-allinone-2.27 from the following website: http://pf.itd.nrl.navy.mil/nrlsensorsim/
       2) make sure you download the right instruction, just for nrlsensorsim-2.27
       3) download the patch for ns-allinone-2.27 from the following link: https://www.ececs.uc.edu/~cdmc/ucbt/src/
notice: put these files in one directory!

step2: installation procedure:
       1) unzip nrlsensorsim-2.27 and ns-allinone-2.27;
       2) cd nrlsensorsim-2.27 and ./patch_script-2.27.sh
       3) cd ..
       4) patch -p0 < ns227-gcc34.patch.  notice: during the process, there might be some warning against some compnents failed to be patched. ignore them!
       5) cd ns-allinone-2.27 and ./install
       6) put the envirnoment variables at the right path at the end of the installaton by following the instruction at the end of the compile.

i havnt done any simulations by using nrlsensorsim so far, but later on, i will continue this part after the operating.

enjoying the trip and please propose any suggestions. thanks

 

PS: according to serveral responses, the website for nrlsensorsim seems excludeing  ip addresses from china. i am wondering if any space in this website could be allocated for me to upload the file in the size of 926KB. any suggestions will be highly valued.

转载自:http://downloads.pf.itd.nrl.navy.mil/archive/nrlsensorsim/INSTALL-2.27.txt

<PRE>TITLE: Installing NRL's Sensor Network extensions to NS-2.27AUTHOR: Ian Downard <nrlsensorsim@pf.itd.nrl.navy.mil>DATE: April 2004ABSTRACT:  These instructions describe how to install the code necessary for simulating  sensor networks in the Network Simulator, version 2.27, distributed by the  Information Sciences Institute at the USC School of Engineering [1]. QUICK AND DIRTY INSTALLATION:  Download nrlsensorsim-2.27.tgz.  A script has been written to automatically patch the ns-2.27. That script is  called "patch_script-2.27.sh", and must be run from the nrlsensorsim-2.27/  directory, which in turn must be located in the same directory that has the  ns-allinone-2.27 directory.  So here's the procedure:    tar -xzvf ns-allinone-2.27.tgz    tar -xzvf nrlsensorsim-2.27.tgz    cd nrlsensorsim-2.27/    ./patch_script-2.27.sh(This script must be run BEFORE the ns-allinone-27/install script is run.
 cd ../ns-allinone-2.27/ ./install Our extensions to ns-2.27 do not yet include support for the NRLOLSR routing algorithm. If you desire NRLOSLR, download our patches for ns-2.26.PATCHING SUMMARY:Some of ISI's enhancements added to ns-2.27 were removed in order to force incompatibility with our sensor network extensions. The side effects of ourhacks are not yet understood. Users should corroborate their simulationresults as much as possible with earlier versions of ns.PATCHING DETAILS:Here are the problems I've fixed with ns-2.27 (first two are in mac/channel.cc):1. WirelessChannel::sendUp contains an else structure with list-based improvements. I reverted that else structure back to what it was in 2.26. Without this modification, PHENOM packets will never get received.2. WirelessChannel::updateNodesList contains a call to sortLists(). I removed that call in order to fix a segmentation fault.3. The makefiles ns-2.27/indep-utils/cmu-scen-gen/setdest/Makefile, ns-2.27/indep-utils/webtrace-conv/conv/Makefile, and ns-2.27/indep-utils/webtrace-conv/dec/Makefile, needed to be modified in order to fix a bug in ISI's distribution. The bug caused a compile-time error that looked like this: g++ -c -Dstand_alone -DSTL_NAMESPACE=@STL_NAMESPACE@ -o setdest.o setdest.cc In file included from ../../../config.h:54, from setdest.h:5, from setdest.cc:57: ../../../autoconf.h:85: Error: namespace `CPP_NAMESPACE' undeclared setdest.cc:71:1: warning: "INFINITY" redefined In file included from /usr/include/math.h:40, from setdest.cc:43: /usr/include/bits/mathdef.h:35:1: warning: this is the location of the previous definition make[1]: *** [setdest.o] Error 1 make[1]: Leaving directory `/home/iandow/netsim/ns-allinone-2.27/ns-2.27/indep-utils/cmu-scen-gen/setdest' make[1]: Entering directory `/home/iandow/netsim/ns-allinone-2.27/ns-2.27/indep-utils/webtrace-conv/dec' To fix the bug, edit ns-2.27/indep-utils/cmu-scen-gen/setdest/Makefile and change this line: DEFINE = -Dstand_alone -DSTL_NAMESPACE=@STL_NAMESPACE@ to this line: DEFINE = -Dstand_alone -DSTL_NAMESPACE=@STL_NAMESPACE@ -DCPP_NAMESPACE=std In the other two makefiles, append -DCPP_NAMESPACE=std to CFLAGS. I discovered that fix by searching the NS news database[2] for "CPP_NAMESPACE".REFERENCES:[1] The Network Simulator - ns-2, http://www.isi.edu/nsnam/ns/[2] NS news database, http://www.isi.edu/nsnam/htdig/search.html</PRE>

0 0
原创粉丝点击