Ask Your Question
0

Simulation in PR2 robot

asked 2012-11-20 03:12:03 -0500

Albert K gravatar image

Can I run simulation in gazebo and all of them are on the PR2 robot? My scenario is that when a robot generates a plan, it might be safer if it can simulate first in its "mind" before execution. After it gets a successful plan, we can apply the plan to the real robot and the physical world. If it fails in the physical world, then we can modify the world model in the simulator and finally build up a good-enough world model.

But I found that most of the nodes and topics generated when I roslaunch pr2_empty_world.launch, will duplicate with those in the robot. So once I launch it in the robot, it will replace the ones belong to the robot and cause lots of errors.

So my question is how to run the simulation in PR2? When we get the good plan, how to synchronize the simulator and the robot? Or if there is a better approach to do the simulation in robot?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2012-11-20 03:23:07 -0500

Lorenz gravatar image

I would run gazebo and the real robot on two different roscore instances. That's probably the easiest solution. The hardest part is probably to allow your planning node to access both cores but you can use some multimaster approach for that.

Alternatively, you can try to run all gazebo-related nodes in a separate namespace but that's definitely not trivial because you need to make sure that topics such as tf and joint_states are put in the namespace as well. Have a look at roslaunch's <group> tag.

edit flag offensive delete link more

Comments

Any recommended package for multimaster? I've checked ros.org and the related package seemed to be experimental. And the only package I can install using apt-get is ros-fuerte-multimaster-experimental. Any suggestion? Thanks~

Albert K gravatar image Albert K  ( 2012-11-20 03:59:29 -0500 )edit

There were a few questions on that topic here on answers.ros.org. Maybe you find a few good answers there. Unfortunately, I didn't have a chance to have a closer look at that topic though.

Lorenz gravatar image Lorenz  ( 2012-11-20 04:01:26 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2012-11-20 03:12:03 -0500

Seen: 140 times

Last updated: Nov 20 '12