Skip to content

Emulator manual

Jose Daniel Britos edited this page Feb 8, 2015 · 26 revisions

Installing the program

The program is written in Python once download in the work directory the requirements to run are:

  • VirtualBox instaled with an openwrt virtual machine.
  • Vde-Switch with the patch colour.path and the frame_size.patch
  • the python library pygtk, gobject, cairo,math, pickle os, netsnmp, time and vboxapi.

With the command:python simmeshv11.py the program must run.

If you do not want to configure your openwrt virtual machine it can be download from the Git Hub repository this is a fully configurated virtual machine. Download openwrt.ova in VirtualBox program go to File menu -> Import Appliance.

##Runing the program

When the program is running present the first screen, asking for the password it is needed to setup the interfaces in the host machine. If any work was saved with the option Menu File Save the topology saved is load automatically it is saved in "data.ms".

Password Screen

In the superior bar there are a menu, File, Edit Run/Stop Tools in the following figure is show the menu File.

File Menu

  • The New clear the work-space to begin a new topology.
  • Open present a File dialog to choose a topology file.
  • Save Store the current topology in the "data.ms" file. (First must stop the emulation).
  • Save as permit choose the file to save the topology.(First must stop the emulation).
  • Quit close all and exit the program.

The Edit menu shown in the following figure:

Menu Edit

have the following entry:

  • Delete Mesh erase current mesh topology
  • Delete Nodo erase the Nodes without connections.
  • Delete Link erase links that not connect any nodes.
  • Edit Wire Show the window "EDIT WIRE" this permit select the properties of the connection. Is not necessary to press the OK button to make the selection is possible to let open the window and change the selection before to put the wire in the topology screen.
  • Select VM Show the window "SELECT VIRTUAL MACHINE" this show all the virtual machines of VirtualBox and one can select the appropriate VM. Is not necessary to press the OK button to make the selection of the VM, is possible to let open the window and change the selection before to put the Node in the topology screen.

Wire setup

The following figure show the windows "SELECT VIRTUAL MACHINE" with openWrt selected.

VM select

The Run/Stop menu have two option :

  • Run this launch the emulation creating de VM, the vde-switch, the wirefilter and creates the interfaces TAP and vboxnet in the host, the emulator pass from edit mode to emulation mode.
  • Stop the emulation stop the VM, the vde-switch, the wirefilter and remove the host interfaces, the emulator pas from emulation mode to edit mode.

The Tools menu and about menu is not yet implemented.

##Edit mode

Edit mode is used to build the topology of the mesh network. With one click of the left button the nodes are create, the virtual machine of the node is setup selecting with the VM Select menu, the VM name prior to create the node. To delete nodes press the right button over the node and the node is deleted. To create a link is necessary at least two nodes, maintaining pressed the left button and sliding the mouse between the two nodes, press in the origin node and release in the end node. To delete a link the same action to create a node is performed with the right button. If in wire properties 2.4GHz is selected, only this link is delete, if is necessary to delete the 5.0GHz link, this must be selected in wire properties.

When one node or one link is create this become the current node and the information on the screen is for the current node. To select other current node or current link the same action to create or delete is performed with the middle button of the mouse.

Edit mode

The figure show the layout of the screen with information of virtual machine name of the current node, the highlight node is the current node, the highlighted link is the current link in the second and third line is shown the wire properties with pink color for 2.4 GHz and light blue color for 5.0 GHz.

##Run Mode

Run mode is when through the Run/Stop menu Run is selected the program launch the virtual machines the vde-switch the TAP interfaces of the host and the wirefilters. once the virtual machines haved boot the screen present the followin information: In the first line the Rx/Tx packets of the current Node, over the circle of each node is presented the Rx/Tx packets of the bat0 interface, and in the bottom of the screen the originators list of the current Node.

Run Mode

###Change link properties.

Is possible to change the link properties in Run mode for do this follow the next step:

  • Delete the link
  • Change wire properties.
  • Create a new link.

Batman-adv search a new path and if this link is appropriate, it use this link.

###Wireshark integration. The integration with the wireshark network analyzer is very simple run Wireshark and the program present the list of interfaces as shown in the figure:

Wireshark

Choose the tap interface for the node and the band (2.4GHz or 5.0 GHz) that you want to inspect and the wireshark sniff in these interface. The notation of the tap interface "tapc24GHz11" is the following:

  • tap designate a tap interface
  • c24GHz designate the band of the interface 2.4GHz.
  • 11 Designate the Node number 11 in this case.
Clone this wiki locally