Git Product home page Git Product logo

azatvaleev / lib60870 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mz-automation/lib60870

0.0 1.0 0.0 1.3 MB

Official repository for lib60870 an implementation of the IEC 60870-5-101/104 protocol

Home Page: https://www.mz-automation.de/communication-protocols/iec-60870-5-101-104-c-source-code-library/

License: GNU General Public License v3.0

CMake 1.36% Makefile 0.97% C 97.67%

lib60870's Introduction

README lib60870-C {#mainpage}

lib60870 library for IEC 60870-5 based protocols in C

The current implementation contains code for the IEC 60870-5-101 (application layer and serial link layer) and IEC 60870-5-104 (protocool over TCP/IP) specifications.

Features:

  • support for all application layer message types
  • master and slave
  • balanced and unbalanced link layers (for CS 101 serial communication)
  • client/server for CS 104 TCP/IP communication
  • CS 104 redundancy group support
  • portable C99 code

Please also consider the User Guide and the API reference documentation (https://support.mz-automation.de/doc/lib60870/latest/)

Compiling and running the examples:

In the lib60870-C folder build the library with

make

Go to the examples folder and build the examples with

make

in each examples' directory.

The library and examples can also be build with CMake.

To build the library in a separate folder create a new folder as subdirectory of the project folder and run cmake to create the build files:

mkdir build cd build cmake ..

Building without common code and HAL

The library contains some common code and a platform abstraction layer (HAL) that is shared with other protocol libraries of MZ Automation (e.g. libiec61850). In order to simplify using these protocol libraries together it is possible to compile the library without the common parts.

This can be done by using the WITHOUT_HAL and WITHOUT_COMMON defines when calling make:

make WITHOUT_HAL=1 WITHOUT_COMMON=1

Building with TLS support

The library can be build with support for TLS. In order to do so you have to download mbedtls version 2.16.12.

Unpack the mbedtls tarball in the dependencies folder so that a folder

dependencies/mbedtls-2.16.12

exists.

The cmake build system will automatically detect the mbedtls source and build the library with TLS support and mbedtls included

When using make you have to call make with WITH_MBEDTLS=1

make WITH_MBEDTLS=1

Library configuration

There are different runtime and compile-time configuration options.

Compile time configuration options can be used to shrink down the library for small embedded systems. Compile time configuration can be changed by modifying the file config/lib60870_config.h.

Memory allocation

The library uses dynamic memory allocation (malloc/calloc wrapped by own functions that can be replaced when required).

The CS104 slave uses dynamic memory allocation only at setup time (when calling the function CS104_Slave_create and CS104_Slave_start/CS104_Slave_startThreadless.

For details please have a look at the User Guide.

Contact:

The library is developed and supported my MZ Automation GmbH.

For bug reports, hints or support please contact [email protected]

Licensing

This software can be dual licensed under the GPLv3 (https://www.gnu.org/licenses/gpl-3.0.en.html) and a commercial license agreement.

When using the library in commercial and non-GPL applications you should buy a commercial license.

Commercial licenses and support

Support and commercial license options are provided by MZ Automation GmbH. Please contact [email protected] for more details.

Contributing

If you want to contribute to the improvement and development of the library please send me comments, feature requests, bug reports, or patches.

For more than trivial contributions I require you to sign a Contributor License Agreement. Please contact [email protected].

lib60870's People

Contributors

mzillgith avatar ellepdesk avatar m-unkel avatar fedepell avatar gythialy avatar lodup29 avatar nowlar avatar pangweishen avatar

Watchers

 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.