ingeniamc / ingenialink

Applications library for Ingenia servo drives
Other
15 stars 9 forks source link

[DEPRECATED]

This library is no longer being maintained. Please consider using ingenialink-python instead.

libingenialink - Motion and communications library for Ingenia servodrives

License: CC BY-NC-ND 4.0

libingenialink is a portable, pure C implementation library for simple motion control tasks and communications with Ingenia drives.

Ingenia Servodrives

What it can do

The library provides:

Building libingenialink

Actually, libingenialink only supports Windows OS, but Linux support is coming later this year.

libingenialink depends on libxml2 and SOEM. A couple of sections below you will find some instructions on how to build and install them. libingenialink can be built and installed on any system like this:

cmake -H. -B_build -DCMAKE_INSTALL_PREFIX=$INSTALL -DWITH_PROT_ETH=ON -DWITH_PROT_ECAT=ON
cmake --build _build
cmake --build _build --target install

Note that a INSTALL is the installation folder.

Build options

The following build options are available:

Furthermore, standard CMake build options can be used. You may find useful to read this list of useful CMake variables.

Dependencies

As mentioned before, libingenialink depends on libxml2 and SOEM, both referenced in the external folder as submodules. Therefore, if building them make sure to initialize the submodules first:

git submodule update --init --recursive

Below you can find some building instructions for dependencies. Note that INSTALL is the installation folder.

libxml2

Athough libxml2 is multiplatform, the building process can be somewhat painful on some systems, specially on Windows. This is why we provide a CMake script to build it on the systems we support. It can be built and installed like this:

cd external/libxml2
cmake -H. -B_build -DCMAKE_INSTALL_PREFIX=$INSTALL
cmake --build _build --target install

SOEM (EXPERIMENTAL)

In order to use the embbedded master communications of ingenialink (still in development), you must install SOEM libraries as an external package.

cd external/SOEM
cmake -H. -B_build -DCMAKE_INSTALL_PREFIX=$INSTALL -DCMAKE_POSITION_INDEPENDENT_CODE=ON
cmake --build _build --target install

Coding standards

libingenialink is written in ANSI C (C99), so any modern compiler should work.

Code is written following the Linux Kernel coding style. You can check for errors or suggestions like this (uses checkpatch.pl):

cmake --build build --target style_check