Skip to content

A simulation for an Infrastructure-less Emergency Communication System based on Blockchain framework

Notifications You must be signed in to change notification settings

risc-lab/MANET-Emergency-Communication-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MANET Emergency Communication System Simulation

DOI

Table of contents

Introduction

This repository contains codes for simulating an Infrastructure-less Emergency Communication System based on Blockchain framework.

Installation

This project is developed using Pyhton. The requirements to run this project is included in the requirements.txt file in the repository.

pip install -r requirements.txt

Run this command in your shell to install the required libraries.

External Libraries

Visuals

demo1.mp4
demo2.mp4

Pseudocode

Person {

	// Initial data stored for every person
	DLT = ∅
	Position = (x,y)
	Info = UniqeID

}

Initialize(Graph G) {

	// Start
	For each Device D ∈ G.People {
	    Create-UniqeID(D)
	    Create-DLT(D)
	    Start-WiFiScan(G, D)
	}

}

Start-WiFiScan(Graph G, Person P) {

	// Searching for other devices
	Start-Timer
	Start-Scanning

	if FIND-PEOPLE-NEARBY(G) :
		SEND-REQUEST
		UPDATE-DLT(G)

	else:
		if TIME-LIMIT-EXCEEDED:
			END

		else:
			Start-Scanning	// Again

		Endif

	Endif

}

UPDATE-DLT(Graph G) {

	// Update and merge of digital ledgers
	MAX-DISTANCE = 100 ft
	DLT = ∅

	For each Device D ∈ G.People {
	    MAKE-DISJOINT-CLUSTER-SET(D)
	}

	For each path (u, v) ∈ G.Paths ordered by increasing order by DISTANCE(u, v) {
	    if FIND-CLUSTER-SET(u) ≠ FIND-CLUSTER-SET(v):	// Checking if they are already from the same cluster or not in order to avoid cycles
	    	if DISTANCE(u, v) < MAX-DISTANCE:              // Checking if they can be merged or not based on the maximum distance
	    		DLT = DLT ∪ {(u, v)}	              // Merge
	    		UNION(u, v)
	    	Endif
	    Endif
	}
	    		
	return DLT

}

Credits

Developer


Ramtin Ehsani

📖 💻

About

A simulation for an Infrastructure-less Emergency Communication System based on Blockchain framework

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages