# Installating Omnetpp GUI and Native Quisp on Windows OS
## TL;DR
* Before You Start
* OMNeT++ Installation
* Insall Needed Tools for the GUI
* Cloning and Building Quisp
* Running A Simulation
## Before You Start
Before you begin installing OMNeT++ and Quisp, make sure you have a C++ compiler on computer. If you do, skip to step 1, if you don't, head to [this](https://www.tutorialspoint.com/How-do-I-set-up-C-Cplusplus-on-Eclipse-in-Windows) link and get your compiler set up and then come back and go to step 1!
## 1- OMNeT++ Installation
OMNeT++ is an extensible, modular, component-based C++ simulation library and framework and is used to simulate the network. To download it, please click [here](https://omnetpp.org/download/).
OMNeT++ will be downloaded as a zip file. Once the download is complete, extract the file, you should see these files in the extracted directory.

Run *mingwenv.cmd*, which will start a console with the MSYS bash shell.
In the shell type the following commands:
```
$ ./configure
$ make
```
This might take a while to finish executing.
**To verify** that the installation has been successful, run the following:
```
$ cd samples/aloha
$ ./aloha
```
By default, the samples will run using the graphical Qtenv environment. You should see the following GUI windows.

**Click OK**

Yay!! your installation was successful!!
**To run** the Omnetpp (OMNeT app), type the command
```
$ omnetpp
```
###### Whenever you want to run omnetpp, you will need to run from the mingwenv console.

## 2- Install Needed Tools for the GUI
To run the simulation GUI, you will need to install *Eigen*.
In the mingwenv console, type the following command:
```
git clone https://gitlab.com/libeigen/eigen.git
```
For more information on Eigen, please visit [this](http://eigen.tuxfamily.org/index.php?title=Main_Page) site.
## 3- Cloning and Building Quisp
To clone and build Quisp, one your terminal (use the mingwenv console to clone the repo) and type the follwoing commands:
```
$ git clone https://<username>@bitbucket.org/sfc-aqua/kaaki_master_quisp.git
```
The last command will take a while to build the docker (around 15 mins).
## 4- Set up OMNeT for the Simulation
*Launch* omnetpp from mingwenv console

From File >> Open Projects from File System

Click *Directroy* and choose the location where Quisp was cloned (usually it will be in the omnet directroy)

Select both files and click *Finish*

That will make *kaaki-quisp-master* and *quisp* appear in your **Project Explorer**
Select quisp, right-click on it and choose *properties*.

In the screen that shows up, expand OMNeT++, click on Makemake.
Select quisp from the middle and on the right-habd side, choose Makemake and then click on options.

In the compile tab, click the add button 
and then choose the directroy for **Eigen** and click OK

In the *Project Explorer* right-click on quisp and choose *Run As* > *OMNeT++ Simulation*.

The following window will pop up, and it will take up to 2 mins to get the simulation set up.

Test the simulation by choosing a *Config name*

And VoilĂ !!!

## 5- Running A Simulation
From File > Set Up an Unconfigured Network...

Choose a network and click OK.

Enjoy the simulated results!!
