Here is a demo video showing what one can accomplish through this tutorial.
Note This tutorial is tested to work only with Python2.7 version on PyRobot
Make sure robot is turned ON
Launch the robot driver
roslaunch locobot_control main.launch use_arm:=true use_camera:=true
- Run the pushing example
pushing.py script accepts two parameters:
gripper_len. You need to tune these two parameters a bit.
floor_height means the
z-coordinate of the floor. Points with
z-coordinate smaller than
this value will be filtered. Only points heigher than the floor will be used for clustering.
means the length of the gripper (from
gripper_link to the tip of the gripper). You may need to tune these
two parameters when you run the example.
If the gripper goes down too much and it hits the floor while pushing the object, you can make the
gripper_len bigger. If the gripper doesn't go down enough and it doesn't touch the object, you can try making the
floor_height, you need to run the following script first.
python realtime_point_cloud.py --floor_height=0.01
This script shows the point cloud in the scene after filtering (points with depth more than 1.5m and points with
z coordinate (height) larger than
floor_height will be removed). The remaining point cloud will be used for clustering and pushing in
pushing.py. So you need to tune the
floor_height such that the floor is completely removed (which means its value cannot be too small) and as much points of the the objects as possible are remained (which means its value cannot be too big).
After tuning, you can run the pushing script in a new terminal as follows:
python pushing.py --floor_height=0.01 --gripper_len=0.12
Warning: we are using the analytical inverse kinematics in this example, which means no collision checking is performed here. So the robot arm may hit the robot itself sometimes.