This repository provides a YARP device plugin for EtherCAT CiA402 drives.
Ensure the following dependencies are installed:
Note: This device has been tested only on Linux systems.
-
Clone the repository:
git clone https://github.com/your-repo/yarp-device-ethercat-cia402.git cd yarp-device-ethercat-cia402
-
Create a build directory and navigate into it:
mkdir build && cd build
-
Configure the project with CMake:
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/path/to/install
-
Build the project:
make
-
Install the plugin:
make install
After building the project, the plugin can be loaded into a YARP-based application. Make sure the YARP_DATA_DIRS
environment variable includes the path to the plugin's configuration files:
export YARP_DATA_DIRS=/path/to/install:$YARP_DATA_DIRS
The plugin requires a configuration file defining the EtherCAT network and device parameters. An example can be found at: config/robot/template_1_motor/config.xml
To ensure that the yarprobotinterface
binary has the correct permissions and can locate its dependencies, execute:
patchelf --add-rpath $(dirname $(dirname $(which yarprobotinterface)))/lib $(which yarprobotinterface)
sudo setcap cap_net_raw,cap_net_admin+ep $(which yarprobotinterface)
To run the plugin with a specific configuration:
yarprobotinterface --config config/robot/template_1_motor/config.xml
This plugin has been primarily tested with Synapticon drives. While it may be compatible with other EtherCAT drive models or manufacturers, some modifications might be necessary to ensure proper functionality. This is due to the plugin’s use of a custom Process Data Object (PDO) mapping, which extends beyond the standard CiA402 specification.
If you're looking to adapt the plugin for different hardware, we encourage you to open an issue or contribute improvements.
For more details, see:
- Protocol map — PDOs, SDOs, and conversion formulas: doc/protocol_map.md
- Modes and setpoints — available control modes and targets: doc/modes_and_setpoints.md
- Dual encoder handling — mounts, sources, and transformations: doc/dual_encoder_handling.md
This project is licensed under the BSD-3-Clause License. See the LICENSE
file for details.