Hi, I have been attempting for a while now to make a robot move in Gazebo with the PR2 controller plugins. I have noticed in the Pr2 it sends effort to the wheels which makes them spin, but what makes the robot move?
I have applied effort to the joints in the c++ module, however my robot's wheels just spins and it does not move.
Question 1:
How does the Pr2 move its base after receiving a Twist message?
Question 2:
How do I make my robot move, seemingly that applying effort to the wheels is not moving it forward?
Edit: Wow, this was a long time ago and I think I'm experienced enough to answer this for all interested.
To make a robot move, you must send velocity commands to it. There will be controllers loaded in the ROS ecosystem that subscribe to the /cmd_vel topic (sometimes remapped to a different name). These controllers will interpret the message and move the robot.
Upon receiving Twist messages, the controller will handle everything from turning the +X motion into wheel rotation to the error feedback specified by the drivers used in the URDF. The physics of Gazebo will handle the rest.
Originally posted by DevonW on ROS Answers with karma: 644 on 2013-02-21
Post score: 0
Original comments
Comment by Mrit91 on 2013-06-27:
Could you please share the c++ module? I want to rotate a sensor mounted on a quadrotor, which I think will be similar to your spinning the wheel, I am not getting how to do it. Thanks.