Getting started with ROS2
The MANUS ROS2 package is a ROS2 wrapper around the MANUS C++ SDK. This package allows you to easily integrate MANUS gloves into your ROS2 project and provides a ROS2 interface for MANUS glove data.
Overview
The ROS2 package publishes MANUS glove data as ROS2 topics. A custom message type is used to represent glove data and exposes the following data for each glove connected.
- Raw skeleton data: The raw skeleton data represented as a list of joint positions.
- Ergonomics values: The ergonomics values represented as a list of joint angular rotations.
- Raw sensor data: The raw sensor data represented as a list of sensor positions and rotation relative to the glove source (only available for MANUS Metagloves Pro series gloves).
Please refer to the ros2 package documentation for more information on the package.
Installation
-
Install ROS2: Ensure you have ROS2 installed on your system. You can follow the installation guide on the ROS2 website.
-
Install MANUS prerequisites: Ensure you have the MANUS C++ SDK installed on your system. The ROS2 package is shipped as part of the MANUS C++ SDK. Please refer to the Linux installation for more information.
-
Create a ROS2 Workspace: Create a new ROS2 workspace and navigate into it.
-
Copy the package: Take the contents of the
ROS2
folder and copy it to thesrc
folder of your workspace. The ROS2 package is shipped as part of the MANUS C++ SDK. Please refer to the Getting started guide for download instructions. -
Set permissions: Ensure the
manus_ros2
folder has the correct permissions. You can do this by running the following command: -
Build the Package: Use
colcon
to build the package. -
Source the Setup Script: Source the setup script to overlay this workspace on your environment.
-
Run the Manus Data Publisher: Execute the Manus data publisher to start publishing glove data messages.
Usage
The MANUS ROS2 package publishes glove data as ROS2 topics. For each glove connected a subsequent topic is created. The topics are named according to an incremental naming scheme, starting from manus_glove_0
and incrementing for each glove connected.
Each glove is represented as a ManusGlove
message type. The message types are structured as follows:
ManusGlove
glove_id
(int32): The ID of the MANUS glove deviceside
(string): The side of the glove (left or right)raw_node_count
(int32): The number of raw skeleton nodesraw_nodes
(ManusRawNode[]): Array of raw skeleton nodesergonomics_count
(int32): The number of ergonomics data pointsergonomics
(ManusErgonomics[]): Array of ergonomics dataraw_sensor_orientation
(geometry_msgs/Quaternion): Orientation of the raw wrist (Only for Metaglove Pro series gloves)raw_sensor_count
(int32): The number of raw sensors (Only for Metaglove Pro series gloves)raw_sensor
(geometry_msgs/Pose[]): Array of raw sensor data (Only for Metaglove Pro series gloves)
ManusRawNode
node_id
(int32): The ID of the nodeparent_node_id
(int32): The ID of the parent nodejoint_type
(string): The type of joint (e.g., wrist, finger, etc.)chain_type
(string): The type of chain (e.g., mcp, pip, etc.)pose
(geometry_msgs/Pose): The pose of the node in 3D space
ManusErgonomics
type
(string): The type of ergonomics data (which joint)value
(float32): The value of the ergonomics data (what angle)
This data is published at a rate of 120Hz by default and can be subscribed to by other ROS2 nodes.
The joint_type
, chain_type
, and side
fields are string representations of the SDK enumerators and their values can be found in the ROS2 package article.
Example Visualization
The MANUS ROS2 package comes with an example visualization node that subscribes to the glove data topics and visualizes the raw skeleton data in Open3D. To run the example visualization node, execute the following command:
Running the Python Visualization Example
To run the Python visualization example, follow these steps:
It's probably necessary to install the open3d
and loop_rate_limiters
Python packages. You can install them using pip:
-
Install Prerequisites: Ensure you have the required Python packages installed.
-
Run the Python Script: Execute the Python script to start visualizing the glove data.
It will draw an Open3D view for each glove, showing the raw skeleton nodes in 3D space.