A ROS-Gazebo package to control and simulate a robotic hand.
The following repository holds a ROS package that simulates a 15DOF robotic hand with some available gestures. The available hand gestures so far are:
- Open hand
- Close hand
- Thumbs up
- Cound down
Just follow the next steps:
- Install the package
- Plug in the joystick
- Execute
roslaunch launchMe.launch
- Wait until Gazebo is loaded
- Press the joystick's buttons
- The hand will start doing some gestures
There are three main parts you should care look around:
- script: It holds the code for remapping the joystick's keystrokes into gesture commands to be done by the robot hand.
- urdf: It holds the URDF file that defines the robot hand's dynamics and kinematics.
- launch file: It holds the code that will be executed by roslaunch and it will set up all the nodes and simulation accordingly.
This repository can be divided into two main components, the simulation and the ROS environment. Below code is for a more in-depth explanation, which you shouldn't care about as it is done automatically by the system when using roslaunch launchMe.launch
.
For controlling the "robot", we want to pass a some positional commands to control the 15DOF of the system. As in this case we will be connecting the ROS enviroment to a simulated world, we add the libgazebo_ros_control.so
plugin to the URDF to allow a communication between ROS and Gazebo and we add some transmission_interface
s to allow for a positional control.
Once the urdf is prepared, we create a simple script ("joy_to_handGestures.py") that converts the readings from a joysticks into an actual commands for the "robot". The reading of the joysticks is handled by the "Joy_node" which is loaded from the "Joy" ROS package. All this gives a result the following graph:
The robot hand is composed of 16 links and 15 joints as seen in below images.
Once everything is setup, the whole result should be the following (for a more detailed view check here):
You should install the following:
- ROS-lunar
- Gazebo
- Python
- Joy (ROS package)
- USB joystick