What is R2?
The r2 robot, which is an acronym for Robonaut 2, is a dexterous humanoid robot created by NASA, with the goal of it aiding humans in space (Robonaut 2 is just an upgrade from its predecessor, the Robonaut). The robot was created to ressemble as close as a human (with a head, hands, fingers, etc), it will be used to expand our ability for construction and discovery.
See NASA-R2-poster.pdf for details.
Link
Blog post
Github repo
Youtube | NASA R2 (Robonaut 2) Robot Simulation in gazebo Step 1 | Humanoid mime
Youtube | NASA R2 (Robonaut 2) Robot Simulation in gazebo Step 2 | Humanoid arm gesture
Youtube | NASA R2 (Robonaut 2) Robot Simulation in gazebo Step 3 | Humanoid playing chess
Preview
See r2_sim/video/ for details.
Installation
install r2 gazebo model and r2 controler1
2
3
4
5mkdir -p ~/r2_sim/src
git clone -b indigo https://bitbucket.org/nasa_ros_pkg/deprecated_nasa_r2_simulator.git
git clone -b indigo https://bitbucket.org/nasa_ros_pkg/deprecated_nasa_r2_common.git
cd ~/r2_sim
catkin_make
start
在simulator中载入r2模型,并启动
1 | cd ~/r2_sim |
此时,在终端输入rqt_graph
显示如下:
这里,节点robot_state_publisher的作用是进行前向运动学计算,也就是说,它使用R2的几何描述和它的关节状态向量持续地计算并更新机器人上的所有坐标系。这种操作到标准ros实现是不依赖于机器人的,直接启动它,它就能为R2做正确到事情。
接下来,启动moveit:
1 | cd ~/r2_sim |
此时,在终端输入rqt_graph
显示如下:
Simulation of NASA Robonaut 2
The following codes are available in my_r2
package.
让R2随机挥动手臂
运行r2_mime.py
,利用moveit运动规划系统让R2随机挥动手臂
1 | r2_mime.py |
视频传送门:Youtube | NASA R2 (Robonaut 2) Robot Simulation in gazebo Step 1 | Humanoid mime
在棋盘上方移动R2的手臂
1 | #!/usr/bin/env python |
运行 r2_chessboard_cli.py,将r2的手臂移动到棋盘b3位置上4厘米处:1
$ ./r2_chessboard_cli.py b3 0.04
为R2定义下棋动作
定义手臂的三个状态:打开,预抓取,抓取:
1 | #!/usr/bin/env python |
运行r2_hand.py,进入预抓取状态:1
$ ./r2_hand.py pre-pinch
运行r2_hand.py,进入抓取状态:1
$ ./r2_hand.py pinch
视频传送门:Youtube | NASA R2 (Robonaut 2) Robot Simulation in gazebo Step 2 | Humanoid arm gesture
让R2在棋盘上下棋
运行spawn_chessboard.py,载入/重置棋盘1
$ ./spawn_chessboard
历史上的对局被记录成pgn格式。
安装第三方的pgn 文件解释器。1
sudo pip install pgnparser
运行r2_chess_pgn.py,载入对局文件 morgan_defeated_lan.pgn,开始对局:1
$ ./r2_chess_pgn.py morgan_defeated_lan.pgn
视频传送门:Youtube | NASA R2 (Robonaut 2) Robot Simulation in gazebo Step 3 | Humanoid playing chess