Home | Tutorials | Wiki | Issues
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

how does the gazebo_ros_skid_steer_drive plugin make robot move

I am new to gazebo.I have searched the question in here and anwser.ros ,but I don't find the anwser. I will be very sorry for the repeating if there is already an explanation. Recently I meet a strange problem.I design a four-wheels car and want to make it move by the gazebo_ros_skid_steer_drive plugin.Everything is right,but the linear velocity. When I input the command: rostopic pub cmd_vel geometry_msgs/Twist -r 3 -- '[2.0,0.0,0.0]' '[0.0, 0.0, 0.0]' I find my car move to the reverse direction . Namely if I want it move forward,it will move back(^_^#). my xacro file about the move is: <joint name="base_to_wheel1" type="continuous"> <parent link="base_link"/> <child link="wheel_1"/> <origin rpy="1.5707 0 0" xyz="0.1 0.15 0"/> <axis xyz="0 0 1"/> <limit effort="100" velocity="100"/> </joint>

<joint name="base_to_wheel2" type="continuous">
    <axis xyz="0 0 1" />
    <limit effort="100" velocity="100" />
    <parent link="base_link"/>
<child link="wheel_2"/>
<origin rpy="1.5707 0 0" xyz="-0.1 0.15 0"/>

<joint name="base_to_wheel3" type="continuous">
    <parent link="base_link"/>
<axis xyz="0 0 1" />
<child link="wheel_3"/>
<origin rpy="1.5707 0 0" xyz="0.1 -0.15 0"/>

<joint name="base_to_wheel4" type="continuous">
   <parent link="base_link"/>
<axis xyz="0 0 1" />
<child link="wheel_4"/>
<origin rpy="1.5707 0 0" xyz="-0.1 -0.15 0"/>

    <plugin name="skid_steer_drive_controller" filename="libgazebo_ros_skid_steer_drive.so">

I check my wheel and confirm that the front wheel joint and the rear joint are all right.Finally I find if I change the wheel joint's origin rpy to "-1.5707 0 0",the movement become right.

origin rpy="1.5707 0 0" xyz="-0.1 0.15 0" ------->> origin rpy="-1.5707 0 0" xyz="-0.1 0.15 0"

I guess the gazebo_ros_skid_steer_drive plugin make my car move forward through making the joint rotate. So I change the joint's roll , the move direction can be changed.But I couldn't find any file to confirm my suppose.Is there any explanation for the gazebo_ros_skid_steer_drive plugin?