Turning to glomosim

Source: Internet
Author: User
ArticleDirectory
    • Install parsec:
    • Visual tool installation (optional)
    • Install glomosim

I have been worried about this paper recently. I have never had time to learn NS2. I think it is troublesome to install and I think it is difficult to learn. I recently found some papers and found a glomosim simulation platform, I have a rough understanding of it. It is easy to install and can be used in windows. In addition, it is convenient to use it. So I decided to start studying glomosim. I will summarize the collected information as follows:

I. Installation

Install glomosim Preparations before installation

L The C compiler is required to run glomosim and parsec. Therefore, make sure that Microsoft Vc ++ version 6.0 is installed on the machine.

L if you need a visualization tool, you also need to install Java JRE or Java SDK version 1.2 or later.

L you must have full permission to modify the environment variables of your computer.

Install parsec:

(1) download and decompress glomosim and save it as "C: \ glomosim ". (The installation directory of glomosim in this article uses C: \ glomosim as an example. You can modify the installation directory accordingly .)

(2) Go To The windows-nt-vc6.0 subdirectory under the glomosim/parsec directory and copy all the files under the windows-nt-vc6.0 and save it to the Parsec directory. Delete all other folders in the Parsec directory.

(3) set environment variables for parsec.

Right-click my computer and choose Properties> advanced> environment variables"

L in "User variables", "new" item "pcc_directory" is set to: C: \ glomosim \ parsec(when the directory where the file pcc.exe is located ).

L in "User variables", set the value of the path item to "C: \ glomosim \ parsec \ bin"

(4) set environment variables for Microsoft Vc ++ version 6.0

L add a semicolon to the value of the include item in "User variables. Add "C: \ Program Files \ Microsoft Visual Studio \ vc98 \ MFC \ include; C: \ Program Files \ Microsoft Visual Studio \ vc98 \ include"

L add a semicolon to the value of the Lib item in "User variables. Add "C: \ Program Files \ Microsoft Visual Studio \ vc98 \ MFC \ Lib; C: \ Program Files \ Microsoft Visual Studio \ vc98 \ Lib"

L add a semicolon to the value of the path entry in "system variables" and add "C: \ Program Files \ Microsoft Visual Studio \ common \ msdev98 \ bin"

Visual tool installation (optional)

During the running of glomosim, the installation of visualization tools is not necessary. The main purpose of a visualization tool is to debug protocols for network designers. It is written in Java to provide the possibility of multiple platforms. It is executed through the GUI provided by the visualization tool.

(1) install Java JRE, Java SDK 1.2, or later on your computer.

(2) Set environment variables:

L add a semicolon to the value of the classpath item in "system variables" and add "C: \ j2sdk1.4.2 _ 04 \ bin"

L add a semicolon to the value of the path entry in "system variables" and add "C: \ j2sdk1.4.2 _ 04 \ bin"

L set the value of the jdk_home item to "C: \ j2sdk1.4.2 _ 04 \ bin" in "system variables"

(3) modify the configuration file:

Change the GUI-OPTION, Gui-radio, GUI-ROUTING from no to yes in the config. In configuration file

Install glomosim

L compile the VC ++ file, go to the C: \ Program Files \ microsoft visualstudio \ vc98 \ bin directory in the command line state, and enter: vcvars32

L compile the glomosim source file. In the command line status, enter the c: \ glomosim \ main directory and enter makent. You can compile it successfully. At this time, you can see the execution in./glomosim/bin.Program"Glomosim.exe ". Check whether the installation is correct. You can run "./glomosim config. In ". A "glomo. Stat" file is generated. Compare it with the "glomo. Stat. sample" file in the same directory to ensure that the output file is valid. Then glomosim is successfully installed.

L compile the visualization tool. Go to the C: \ glomosim \ java_gui directory,

Input: javac *. Java

[Note: If a warning occurs during compilation, use the-source 1.4 option for compilation due to Java version issues]

L start the visualization tool from the glomo/java_gui/directory,

Input: Java glomomain

This tool allows us to debug and run models and scenarios, and can be executed, stopped, and restarted step by step. Show the moving group users and display statistics in different colors. In the visualization tool, the physical layer displays the following status: When a node transmits a data packet, a yellow link is drawn from the node to all other nodes in the sphere of influence. When each node receives a data packet, the link is deleted. If it is accepted successfully, a green link is generated. If it is not received successfully, a red link is drawn. There is no obvious difference between different package types. (Such as control packets and common data packets ).

(I will continue to add my learning experience later and share it with you ~)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.