Giter Site home page Giter Site logo

knot-thing-simulator's Introduction

knot-modbus-simulator

KNoT Modbus Simulator is part of the KNoT project. It aims to provide an industry protocol simulator by creating a tcp server instance so that KNoT Things can be described and tested by KNoT ecosystem. At this moment, the supported industrial protocols are:

  • Modbus

Dependencies

Build:

  • python3 or higher
  • pyserial v3.1
  • modbus-tk v1.1.1

How to install dependencies:

  • Install with pip: sudo pip3 install -r requirements.txt

Configure the simulator

The simulator provides an easy configuration template (config/config.json). In order to create a data server model of industrial things you need to follow the config template, where the fields are explained bellow:

  • id: Specifies the data-server id to be modeled, id > 0.
  • register_data: Represents a non-discrete (non-binary) data-block.
    • Each register_data has the following fields:
      • address: Identifies data inside the data-block related to non-discrete block.
      • value: List of values with little-endian representation in Hexa-decimal.
  • digital_data: Represents a discrete (binary) data-block.
    • Each digital_data has the following fields:
      • address: Identifies data inside the data-block related to discrete block.
      • value: List of values with little-endian representation in binary.

Running the Simulator

  • Running the simulator with template config: sudo python3 main.py

  • Running a simulator with a custom config file: sudo python3 main.py -c <config_file>.json

License

All KNoT Simulator files are under LGPL v2.1 license, you can check COPYING file for details.

knot-thing-simulator's People

Contributors

agms-cesar avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.