User Tools

Site Tools


eeros_architecture:ethercat:start

This is an old revision of the document!


EhterCAT

Overview

Understanding the inner working of EtherCAT is crucial for using EtherCAT effectively. Read this article to get a better understanding of EtherCAT.

Components

In order to use an EEROS application with EtherCAT, the following components are required: * EEROS: The robotic framework

  • EtherCAT stack: The EtherCAT stack from Acontis. Detailed describtion here
  • ecmasterlib: This library provides an easy interface to the EtherCAT stack. The library initializes the stack and takes over the periodic sending and receiving of the bus data. It provides the following interfaces:
    • EtherCATInterfaceBase: Basic interface for ecmasterlib
    • EtherCATInterfaceElmo: Based on EtherCATInterfaceBase. An interface designed for Elmo drives. You may need to implement your own interface for different drives.
    • EtherCATInterfaceElmo_config
  • getDrivesBlock: Block in control system. I has a signal output for every PDO input value (i.e. encoder values). You may need to modify this block in your application.
  • setDrivesBlock: Block in control system. I has a signal input for every PDO output value (i.e. setTorque). You may need to modify this block in your application.

Preperations

Install EtherCAT

First, read this article on how to install EtherCAT on your system and how to run a demo application without EEROS.

If the demo application runs successfully, you can write your own EEROS application with EtherCAT.

Install EEROS

Once the EtherCAT stack has been installed and the demo application is running, the ecmasterlib can be installed.

Clone, build and install ecmasterlib TODO:

$ cd path/to/working/directory
$ git clone url-to-ecmasterlib
$ cd ecmasterlib
$ mkdir build-x86-64
$ cd build-x86-64
$ cmake -DCMAKE_INSTALL_PREFIX=/absolute/path/to/working/directory/install-x86-64 ..
$ make
$ make install

Build and install EEROS after you have installed ecmasterlib Install EEROS as described in this tutorial, but use the command line option -DUSE_ETHERCAT=TRUE when calling cmake.

...
cmake -DCMAKE_INSTALL_PREFIX=/absolute/path/to/working/directory/install-x86-64 -DUSE_ETHERCAT=TRUE ..
...

Necessary adaptions

Overview

The components EtherCATInterfaceElmo_config, getDrivesBlock and setDrivesBlock need to be adjusted, if you change the variables, which are transmitted via PDOs (periodic sent/received messages by the EtherCAT bus). These components must also be adapted when creating a new EEROS application.

eeros_architecture/ethercat/start.1554278214.txt.gz · Last modified: 2019/04/03 09:56 by gehrig