LWN Simulator

Build Status GitHub license made-with-Go GitHub go.mod Go version of a Go module GitHub release

A LoRaWAN nodes’ simulator to simulate a LoRaWAN Network.

General Info

LWN Simulator is a LoRaWAN nodes’ simulator equipped with web interface. It allows to comunicate with a real infrastructure LoRaWAN or ad-hoc infrastructure, such as Chirpstack.

dashboard

The project consists of three main components: devices, forwarder and gateways.

The device

  • Based specification LoRaWAN v1.0.3;
  • Supports all LoRaWAN Regional Parameters v1.0.3.
  • Implements class A,C and partially even the B class;
  • Implements ADR Algorithm;
  • Sends periodically a frame that including some configurable payload;
  • Supports MAC Command;
  • Implements FPending procedure;
  • It is possibile to interact with it in real-time;

The forwarder

It receives the frames from devices, creates a RXPK object including them within and forwards to gateways.

The gateway

There are two types of gateway:

  • A virtual gateway that comunicates with a real gateway bridge (if it exists);
  • A real gateway to which datagrams UDP are forwarded.

Requirements

Installation

From binary file

You can download from realeses section the pre-compiled binary file.

Releases Page

From source code

Requirements

  • You must install Go. Version >= 1.16

Firstly, you must clone this repository:

git clone https://github.com/UniCT-ARSLab/LWN-Simulator.git

After the download, you must enter in main directory:

cd LWNSimulator

You must install all dependencies to build the simulator:

make install-dep

Now you can launch the build of the simulator:

make build

Finally, there are two mode to start the simulator:

  • from source (without building the source)
make run
  • from the builded binary
make run-release

Configuration file

The simulator relises on a configuration file (config.json) whitch specifies some configurations for the simulator:

{
    "address":"0.0.0.0",
    "port":8000,
    "configDirname":"lwnsimulator"
}
  • address: specifies the IP mask from which the web UI is accessible.
  • port: the web server port.
  • configDirname: the directory name where all status files will be saved and will be created in the user home.

GitHub

View Github