My project needs a Random way point scenario to be created, and on searching on Google i came across a useful tool called as Bonnmotion. The tool seemed to be useful but the problem is that it is a very old version. This tool can be downloaded from this
link and you can find the documentation of this tool
here. This is the homepage of this tool
BonnMotion.
http://web.informatik.uni-bonn.de/IV/Mitarbeiter/dewaal/BonnMotion/The BonnMotion is a Java software. It can be installed in Linux and also in Windows. It has been tested on jdk1.4. It can be used to create the following models
- the Random Waypoint model,
- the Gauss-Markov model,
- the Manhattan Grid model and
- the Reference Point Group Mobility model.
Coming to my experience, recently my whole day was wasted installing this tool. I initially tried to install it on Linux but as I need to install java in Linux and my Linux version is RHEL 3, which is a old version (I was concerned whether jdk6 will be compatible with RHEL 3 or not) so I decided I would go with Windows instead. The sad part of the story is that I was unable to install it straight-away in Windows either.
Once I tried to execute the install script it asked the java path which I provided, my Java path is
C:\Program Files\Java\jdk1.5.0
and next it asked the bonnmotion path. I placed my bonnmotion in the C: directory itself.
I initially thought the problem was concerning with version compatability of Java, Bonnmotion was tested with jdk1.4, and I have jdk1.5 installed on my system. I searched in the net for jdk1.4 and was unsuccessful in my effort, than I tested some of the scripts in batch file and felt like there were some problems with the scripts in batch files.[This I cannot guarantee, and is just my thought].
Ok this is what I did and successfully installed Bonnmotion in my Windows XP.
While looking at the errors
"
The system cannot find the specified path"
I observed that the error emerged from the statements
if not exists ......script statement in "
install.bat" batch script
so I removed all such statements from that script, and also embeded the important JAVA variables within double quotes
Here are the steps to be followed:
1. Try to edit the
install.bat file using notepad or any of your favourite text editor,
2. This is the
install.bat file before modification(here I am showing only the lines to be modified, not the entire code)
.............................
.............................
set PACKAGE=edu.bonn.cs.iv.bonnmotionset JAVA=%JAVAPATH%\bin\java.exeset JAVAC=%JAVAPATH%\bin\javac.exeset JAVADOC=%JAVAPATH%\bin\javadoc.exeif not exist %JAVA% ( echo Don't forget to configure this script. echo Could not find java.exe : %JAVA% goto Ende)if not exist %JAVAC% ( echo Don't forget to configure this script. echo Could not find javac.exe : %JAVAC% goto Ende)if not exist %JAVADOC% ( echo Don't forget to configure this script. echo Could not find javadoc.exe : %JAVACDOC% goto Ende)if not exist %BONNMOTION% ( echo Don't forget to configure this script. echo Could not find BonnMotion root directory: %BONNMOTION% goto Ende)echo Installing ...REM bmset FILE=bm.batecho %FILE%if exist bin\%FILE% del bin\%FILE%echo @echo off >> bin\%FILE%echo cd %BONNMOTION% >> bin\%FILE%echo %JAVA% -cp %BONNMOTION%\classes %PACKAGE%.run.BM %%1 %%2 %%3 %%4 %%5 %%6 %%7 %%8 %%9 >> bin\%FILE%REM compileset FILE=compile.batecho %FILE%if exist bin\%FILE% del bin\%FILE%echo @echo off >> bin\%FILE%echo cd %BONNMOTION% >> bin\%FILE%echo if not exist classes mkdir classes >> bin\%FILE%echo echo on >> bin\%FILE%echo for /r %%%%i in (*.java) do %JAVAC% -d classes -sourcepath src -classpath classes %%%%i >> bin\%FILE%REM makedocset FILE=makedoc.batecho %FILE%if exist bin\%FILE% del bin\%FILE%echo @echo off >> bin\%FILE%echo cd %BONNMOTION% >> bin\%FILE%echo if not exist doc mkdir doc >> bin\%FILE%echo %JAVADOC% -quiet -d doc -use -windowtitle "BonnMotion" -sourcepath %BONNMOTION%\src edu.bonn.cs.iv.bonnmotion edu.bonn.cs.iv.bonnmotion.apps edu.bonn.cs.iv.bonnmotion.run edu.bonn.cs.iv.bonnmotion.models >> bin\%FILE%echo done.:Ende......................................
......................................
3. After deleting the conditional statements which start with "
if not exist" (You can also comment the lines if you do not want to delete them, by placing :: before the lines) and embeding some important Java variables (JAVA,JAVAC,JAVADOC) within doublequotes
The modified code looks like this
..............................
..............................
set PACKAGE=edu.bonn.cs.iv.bonnmotionset JAVA=%JAVAPATH%\bin\java.exeset JAVAC=%JAVAPATH%\bin\javac.exeset JAVADOC=%JAVAPATH%\bin\javadoc.exe::The conditional statements are deleted echo Installing ... REM bmset FILE=bm.batecho %FILE%if exist bin\%FILE% del bin\%FILE%echo @echo off >> bin\%FILE%echo cd %BONNMOTION% >> bin\%FILE%echo "%JAVA%" -cp %BONNMOTION%\classes %PACKAGE%.run.BM %%1 %%2 %%3 %%4 %%5 %%6 %%7 %%8 %%9 >> bin\%FILE%REM compileset FILE=compile.batecho %FILE%if exist bin\%FILE% del bin\%FILE%echo @echo off >> bin\%FILE%echo cd %BONNMOTION% >> bin\%FILE%echo if not exist classes mkdir classes >> bin\%FILE%echo echo on >> bin\%FILE%echo for /r %%%%i in (*.java) do "%JAVAC%" -d classes -sourcepath src -classpath classes %%%%i >> bin\%FILE%REM makedocset FILE=makedoc.batecho %FILE%if exist bin\%FILE% del bin\%FILE%echo @echo off >> bin\%FILE%echo cd %BONNMOTION% >> bin\%FILE%echo if not exist doc mkdir doc >> bin\%FILE%echo "%JAVADOC%" -quiet -d doc -use -windowtitle "BonnMotion" -sourcepath %BONNMOTION%\src edu.bonn.cs.iv.bonnmotion edu.bonn.cs.iv.bonnmotion.apps edu.bonn.cs.iv.bonnmotion.run edu.bonn.cs.iv.bonnmotion.models >> bin\%FILE%echo done.:Ende......................................
......................................
4. Now try to install the Bonnmotion by double clicking the install.bat file. If you see these files being created
bm.bat compile.bat makedoc.batthan bonnmotion is successfully installed in your system. Congrats!!!
Any Comments, Suggestions, Positive Criticism and Corrections are welcome!!!
Hope it helped!
Good Luck!!! :)