e-mail address: omnetmanual@gmail.com

Phone number: +91 9444856435

Tel 7639361621

DEFENDER
  • Phd Omnet++ Projects
    • RESEARCH PROJECTS IN OMNET++
  • Network Simulator Research Papers
    • Omnet++ Thesis
    • Phd Omnet++ Projects
    • MS Omnet++ Projects
    • M.Tech Omnet++ Projects
    • Latest Omnet++ Projects
    • 2016 Omnet++ Projects
    • 2015 Omnet++ Projects
  • OMNET INSTALLATION
    • 4G LTE INSTALLATION
    • CASTALIA INSTALLATION
    • INET FRAMEWORK INSTALLATION
    • INETMANET INSTALLATION
    • JDK INSTALLATION
    • LTE INSTALLATION
    • MIXIM INSTALLATION
    • Os3 INSTALLATION
    • SUMO INSTALLATION
    • VEINS INSTALLATION
  • Latest Omnet++ Projects
    • AODV OMNET++ SOURCE CODE
    • VEINS OMNETPP
    • Network Attacks in OMNeT++
    • NETWORK SECURITY OMNET++ PROJECTS
    • Omnet++ Framework Tutorial
      • Network Simulator Research Papers
      • OMNET++ AD-HOC SIMULATION
      • OmneT++ Bandwidth
      • OMNET++ BLUETOOTH PROJECTS
      • OMNET++ CODE WSN
      • OMNET++ LTE MODULE
      • OMNET++ MESH NETWORK PROJECTS
      • OMNET++ MIXIM MANUAL
  • OMNeT++ Projects
    • OMNeT++ OS3 Manual
    • OMNET++ NETWORK PROJECTS
    • OMNET++ ROUTING EXAMPLES
    • OMNeT++ Routing Protocol Projects
    • OMNET++ SAMPLE PROJECT
    • OMNeT++ SDN PROJECTS
    • OMNET++ SMART GRID
    • OMNeT++ SUMO Tutorial
  • OMNET++ SIMULATION THESIS
    • OMNET++ TUTORIAL FOR WIRELESS SENSOR NETWORK
    • OMNET++ VANET PROJECTS
    • OMNET++ WIRELESS BODY AREA NETWORK PROJECTS
    • OMNET++ WIRELESS NETWORK SIMULATION
      • OMNeT++ Zigbee Module
    • QOS OMNET++
    • OPENFLOW OMNETPP
  • Contact

How to Implement Mobile Cloud Computing in OMNeT++

To implement the Mobile Cloud Computing (MCC) in OMNeT++, we have to simulate an environment that has mobile devices, cloud servers, and communication networks, defining network models and executing MCC-specific protocols and algorithms by creating it. Here, we give the step-by-step process of MCC using OMNeT++ with samples:

Step-by-Step Implementation:

Step 1: Install OMNeT++ and INET Framework

  1. Download OMNeT++:
    • Download the latest version of OMNeT++.
  2. Install OMNeT++:
    • Follow the instructions to install it depends on your operating system.
  3. Download and Install INET Framework:
    • The INET framework offers models for internet protocols and is often used with OMNeT++.
    • Install the INET framework on the system.

Step 2: Set Up Your Project

  1. Create a New OMNeT++ Project:
    • Open the OMNeT++ IDE.
    • Go to File -> New -> OMNeT++ Project.
    • Enter a project name and pick proper options.
  2. Set Up Directory Structure:
    • Ensure the project has the essential folders like src for source files and simulations for NED files and configuration.
  3. Add INET to Your Project:
    • In the Project Explorer, Right-click on project.
    • Select Properties -> Project References.
    • Check the box for INET.

Step 3: Define Mobile Cloud Computing Network Models Using NED

  1. Create NED Files:
    • Create a new NED file (e.g., MobileCloudComputingNetwork.ned) in src directory.
    • Define the network topology in the NED file. Here’s a simple example:

package mobilecloudcomputing;

import inet.node.inet.StandardHost;

import inet.node.inet.Router;

import inet.networklayer.configurator.ipv4.Ipv4NetworkConfigurator;

import inet.physicallayer.common.packetlevel.RadioMedium;

import inet.mobility.single.RandomWaypointMobility;

network MobileCloudComputingNetwork

{

parameters:

int numMobileDevices = default(5);

int numCloudServers = default(2);

types:

channel radioChannel extends RadioMedium {}

submodules:

configurator: Ipv4NetworkConfigurator {

@display(“p=100,100”);

}

cloudRouter: Router {

@display(“p=200,100”);

}

cloudServer[numCloudServers]: StandardHost {

@display(“p=300+100*i,100”);

}

mobileDevice[numMobileDevices]: StandardHost {

@display(“p=300+100*i,300”);

mobility.typename = “RandomWaypointMobility”;

}

radioMedium: radioChannel {

@display(“p=400,100”);

}

connections allowunconnected:

for i=0..numMobileDevices-1 {

mobileDevice[i].wlan[0] <–> radioMedium <–> cloudRouter.wlan[0];

}

for i=0..numCloudServers-1 {

cloudServer[i].ethg++ <–> Ethernet100M <–> cloudRouter.ethg++;

}

}

Step 4: Implement Mobile Cloud Computing Logic

  1. Create C++ Modules for Mobile Devices and Cloud Servers:
    • In the src directory, create new C++ classes (for instance: MobileDeviceApp.cc and CloudServerApp.cc).
    • Contains essential OMNeT++ headers and define MCC logic.
  2. Mobile Device Implementation:

#include <omnetpp.h>

#include “inet/applications/base/ApplicationBase.h”

#include “inet/applications/udpapp/UdpBasicApp.h”

#include “inet/networklayer/common/L3AddressResolver.h”

#include “inet/networklayer/contract/ipv4/Ipv4Address.h”

#include “inet/networklayer/contract/IL3AddressType.h”

using namespace omnetpp;

using namespace inet;

class MobileDeviceApp : public ApplicationBase

{

protected:

virtual void initialize(int stage) override;

virtual void handleMessageWhenUp(cMessage *msg) override;

void sendRequest();

void handleResponse(cPacket *pkt);

cMessage *sendEvent = nullptr;

};

Define_Module(MobileDeviceApp);

void MobileDeviceApp::initialize(int stage)

{

ApplicationBase::initialize(stage);

if (stage == INITSTAGE_LOCAL) {

sendEvent = new cMessage(“sendRequest”);

scheduleAt(simTime() + par(“startTime”), sendEvent);

}

}

void MobileDeviceApp::handleMessageWhenUp(cMessage *msg)

{

if (msg == sendEvent) {

sendRequest();

scheduleAt(simTime() + par(“sendInterval”), sendEvent);

} else {

cPacket *pkt = check_and_cast<cPacket *>(msg);

handleResponse(pkt);

}

}

void MobileDeviceApp::sendRequest()

{

// Create and send a request packet to the cloud server

EV << “Sending request to cloud server” << endl;

cPacket *pkt = new cPacket(“Request”);

pkt->setByteLength(par(“requestSize”));

send(pkt, “lowerLayerOut”);

}

void MobileDeviceApp::handleResponse(cPacket *pkt)

{

// Handle received response packet from the cloud server

EV << “Received response from cloud server: ” << pkt->getName() << endl;

delete pkt;

}

  1. Cloud Server Implementation:

#include <omnetpp.h>

#include “inet/applications/base/ApplicationBase.h”

#include “inet/applications/udpapp/UdpBasicApp.h”

#include “inet/networklayer/common/L3AddressResolver.h”

#include “inet/networklayer/contract/ipv4/Ipv4Address.h”

#include “inet/networklayer/contract/IL3AddressType.h”

using namespace omnetpp;

using namespace inet;

class CloudServerApp : public ApplicationBase

{

protected:

virtual void initialize(int stage) override;

virtual void handleMessageWhenUp(cMessage *msg) override;

void handleRequest(cPacket *pkt);

};

Define_Module(CloudServerApp);

 

void CloudServerApp::initialize(int stage)

{

ApplicationBase::initialize(stage);

}

void CloudServerApp::handleMessageWhenUp(cMessage *msg)

{

if (msg->isSelfMessage()) {

delete msg;

} else {

cPacket *pkt = check_and_cast<cPacket *>(msg);

handleRequest(pkt);

}

}

void CloudServerApp::handleRequest(cPacket *pkt)

{

// Handle received request packet from the mobile device

EV << “Received request from mobile device: ” << pkt->getName() << endl;

// Process the request and send a response

cPacket *response = new cPacket(“Response”);

response->setByteLength(par(“responseSize”));

send(response, “lowerLayerOut”);

delete pkt;

}

Step 5: Configure Simulation Parameters

  1. Create omnetpp.ini:
    • Create an omnetpp.ini file within the simulation directory.
    • Define simulation parameters like duration and network parameters:

[General]

network = MobileCloudComputingNetwork

sim-time-limit = 100s

# Mobility

**.mobileDevice[*].mobility.bounds = “0,0,1000,1000”

**.mobileDevice[*].mobility.speed = uniform(1mps, 10mps)

# Mobile device parameters

**.mobileDevice[*].udpApp.startTime = uniform(0s, 10s)

**.mobileDevice[*].udpApp.sendInterval = exponential(1s)

**.mobileDevice[*].udpApp.requestSize = 512B

**.mobileDevice[*].udpApp.localPort = 1000

**.mobileDevice[*].udpApp.destPort = 2000

# Cloud server parameters

**.cloudServer[*].udpApp.localPort = 2000

**.cloudServer[*].udpApp.responseSize = 1024B

Step 6: Build and Run the Simulation

  1. Build the Project:
    • In the OMNeT++ IDE, right-click on the project and select Build Project.
  2. Run the Simulation:
    • Go to Run -> Run Configurations.
    • Build a new run configuration for the project and run the simulation.

Step 7: Analyze Results

  1. View Simulation Results:
    • Use OMNeT++’s tools to analyze the results, once the simulation ends.
    • Visualize and translate the data by opening the ANF (Analysis Framework) to visualize and interpret the data.

Above demonstration will help you get started with a basic MCC simulation in OMNeT++ using the INET framework and how to extend it. Whenever, you need details regarding this script, you can get them from us.

The integration of Mobile Cloud Computing in OMNeT++  are provided by us  as we gice you comprehensive simulation guidance. We focus on creating simulations of networks that encompass various environments featuring mobile devices, cloud servers, and communication networks. Our services include defining network models and implementing MCC-specific protocols and algorithms tailored to your projects. Reach out to us for expert guidance.

Related Topics

  • Network Intrusion Detection Projects
  • Computer Science Phd Topics
  • Iot Thesis Ideas
  • Cyber Security Thesis Topics
  • Network Security Research Topics

designed by OMNeT++ Projects .