The GRIPLINK-ROS2 Plugin is a C++ project that provides a ROS2 interface for managing communication between the ROS2 environment and Weiss Robotics' GRIPLINK technology. The GRIPLINK Unified Command Set (UCS) manual offers an overview of the commands used to control grippers or other devices connected to the GRIPLINK.
- GRIPLINK Node: Implements the GRIPLINK UCS as a ROS2 node, allowing other ROS2 nodes to control devices connected to the GRIPLINK via topics, services, and actions.
- Topics: Periodic publication of information from the GRIPLINK.
- Services: The entire GRIPLINK UCS is implemented as ROS2 services.
- Actions: Time-consuming commands like grip and release are implemented as ROS2 actions.
- Demo Node: A simple client node example demonstrating communication with the GRIPLINK node. It performs basic gripper operations such as homing, gripping, and releasing. Functions as a quick start.
The plugin has been tested with ROS2 Humble Hawksbill on Ubuntu 22.04.
- ROS2 Humble installed on Ubuntu 22.04.
-
Install Required Tools
sudo apt-get update sudo apt-get install python3-pip pip3 install -U rosdep
-
Initialize
rosdepsudo rosdep init rosdep update
-
Source ROS2 Underlay
source /opt/ros/humble/setup.bash -
Navigate to the Repository
cd GRIPLINK_ROS2/ -
Install Dependencies
rosdep install --from-paths src --ignore-src -r -y
-
Build the Workspace
colcon build --symlink-install --cmake-args -DCMAKE_BUILD_TYPE=Release
-
Source the Workspace
. install/local_setup.bash
The repository contains the following packages:
- griplink: Contains the source code for the GRIPLINK Node (
griplink_node.cpp) and the Demo Node (demo_node.cpp). It also includes the implementation of the communication between the GRIPLINK node and the GRIPLINK hardware (griplink.cpp). - griplink_interfaces: The interface definition package. It contains custom message, service, and action definitions used by the GRIPLINK node.
Ensure that your GRIPLINK or WPG-Series gripper hardware is set up correctly.
-
For GRIPLINK: Refer to the Weiss Robotics GRIPLINK Quickstart Guide for hardware setup instructions.
-
For WPG-Series Grippers (Gripper with Integrated GRIPLINK): Refer to the Weiss Robotics WPG Series Manual, particularly sections 5.2.1 and 5.2.2, for hardware setup instructions.
You can test the connection using the web interface (default IP address: http://192.168.1.40) when the GRIPLINK/WPG is connected to your computer's network interface via Ethernet.
Before running the nodes, make sure to source ROS2 and your workspace in each new terminal session.
source /opt/ros/humble/setup.bash
. install/local_setup.bash-
ros2 launch griplink launch.py
This command launches the GRIPLINK node, which starts communication with the GRIPLINK hardware.
-
For a quick start, you can launch both the GRIPLINK node and the demo node using:
ros2 launch griplink demo_launch.py
The demo node provides an example of a client node interacting with the GRIPLINK node. It runs a standard gripper cycle, starting with a homing command, and then periodically performing grip and release actions, with or without a workpiece. This demo is designed for a GRIPLINK with a Weiss Robotics servo gripper connected to port 0, or alternatively a WPG-Series gripper.
-
ip(default:192.168.1.40)The IP address of the GRIPLINK connection.
-
port(default:10001)The port number of the GRIPLINK connection.
-
/griplink_node/device_statesPublishes the current state of devices connected to the GRIPLINK.
The GRIPLINK node provides services corresponding to the GRIPLINK Unified Command Set (UCS). These services allow you to send commands to the GRIPLINK hardware. Documentation of each command is specified in the GRIPLINK UCS Manual.
All services have additional return values status and message, which is a status response from the GRIPLINK after the command. For service arguments and additional return values, refer to the service definitions.
-
System Information Services
/griplink_node/id(/griplink_node/srv/Id)/griplink_node/protocol(/griplink_node/srv/Protocol)/griplink_node/protassert(/griplink_node/srv/Protassert)/griplink_node/sn(/griplink_node/srv/Sn)/griplink_node/labelget(/griplink_node/srv/Labelget)/griplink_node/labelset(/griplink_node/srv/Labelset)/griplink_node/ver(/griplink_node/srv/Ver)/griplink_node/verbose(/griplink_node/srv/Verbose)
-
Device Information Services
/griplink_node/devvid(/griplink_node/srv/Devvid)/griplink_node/devpid(/griplink_node/srv/Devpid)/griplink_node/devassert(/griplink_node/srv/Devassert)/griplink_node/devname(/griplink_node/srv/Devname)/griplink_node/devvendor(/griplink_node/srv/Devvendor)/griplink_node/devsn(/griplink_node/srv/Devsn)/griplink_node/devtagget(/griplink_node/srv/Devtagget)/griplink_node/devtagset(/griplink_node/srv/Devtagset)/griplink_node/devver(/griplink_node/srv/Devver)
-
Controller Command Service
/griplink_node/bye(/griplink_node/srv/Bye)
-
Device Command Services
/griplink_node/enable(/griplink_node/srv/Enable)/griplink_node/disable(/griplink_node/srv/Disable)/griplink_node/home(/griplink_node/srv/Home)/griplink_node/grip(/griplink_node/srv/Grip)/griplink_node/release(/griplink_node/srv/Release)/griplink_node/flexgrip(/griplink_node/srv/Flexgrip)/griplink_node/flexrelease(/griplink_node/srv/Flexrelease)/griplink_node/led(/griplink_node/srv/Led)/griplink_node/clamp(/griplink_node/srv/Clamp)/griplink_node/wstr(/griplink_node/srv/Wstr)/griplink_node/setval(/griplink_node/srv/Setval)/griplink_node/waitval(/griplink_node/srv/Waitval)
-
Device Status and Diagnosis Services
/griplink_node/devstate(/griplink_node/srv/Devstate)/griplink_node/value(/griplink_node/srv/Value)
-
Device Configuration Services
/griplink_node/gripcfgget(/griplink_node/srv/Gripcfgget)/griplink_node/gripcfgset(/griplink_node/srv/Gripcfgset)
Some GRIPLINK commands are time-consuming and may interfere with subsequent commands if not managed properly. To handle this, these commands are implemented as ROS2 actions, which provide feedback and result reporting. Using the action interface ensures that these operations complete before new commands are processed, preventing mid-operation interruptions.
All actions have additional return values status and message, which is a status response from the GRIPLINK after the command.
-
/griplink_node/grip(/griplink_node/action/Grip) -
/griplink_node/release(/griplink_node/action/Release)For WPG-Series only:
/griplink_node/flexgrip(/griplink_node/action/Flexgrip)/griplink_node/flexrelease(/griplink_node/action/Flexrelease)
There are three types of GRIPLINK commands:
- Command: Executes an action on the device.
- Query: Retrieves information from the device.
- Assignment: Sets a parameter on the device.
Understanding these can help in troubleshooting and interacting with the GRIPLINK hardware and its response.
List available ROS2 topics, services, and actions:
ros2 topic list
ros2 service list
ros2 action listInspect data and interact with the node:
-
Example: View Published Topics
ros2 topic echo /griplink_node/device_states -
Example: Call Services
ros2 service call /griplink_node/home griplink_interfaces/srv/Home "{port: 0}" -
Example: Send Action Goals
ros2 action send_goal /griplink_node/grip griplink_interfaces/action/Grip "{port: 0, index: 0}" --feedback
- GRIPLINK UCS Manual: For detailed information about the GRIPLINK Unified Command Set.
- ROS2 Humble Tutorials: For general ROS2 guidance and troubleshooting.
This project is licensed under the MIT License - see the LICENSE file for details.