Robotics StackExchange | Archived questions

ROS 2 Parameter bridge not working - Gazebo Fortress

I am trying to launch my custom robot urdf ion Gazebo Fortress but the "parameter bridge" is not working and I am not able to echo or publish to any topics.

here is my urdf file which also contains ignition gazebo plugins testrobotign.xacro

I first launch the robot_description.launch.py which contains the robot state publisher and joint state publisher.

After that, I launch the ignition.launch.py which - launches the igngazebo.launch.py file from rosigngazebo with a custom world sdf file - spawns the robot by running create node from rosigngazebo by subscribing the robotdescription topic - runs the parameterbridge from rosign_bridge

I am able to successfully see my robot and the custom sdf world file in gazebo Fortress but I am not able to control the robot using teleop.

I am only running the parameter bridge for /cmd_vel topic.

Even if I am not running the teleop node, I get 1 subscription count and 1 publisher count for /cmd_vel topic image description

Asked by nilutpolkashyap on 2023-06-04 05:04:34 UTC

Comments

Answers

In your URDF file, your differential drive plugin is not between gazebo tags like your GPU LiDAR plugin is. Following code block should work,

<gazebo>
    <plugin filename="libignition-gazebo-diff-drive-system" name="ignition::gazebo::systems::DiffDrive">
        <left_joint>joint_left_wheel</left_joint>
        <right_joint>joint_right_wheel</right_joint>
        <wheel_separation>1.25</wheel_separation>
        <wheel_radius>0.3</wheel_radius>
        <topic>/cmd_vel</topic>
        <odom_topic>/odom</odom_topic>
    </plugin>
</gazebo>

Also before bridging over to ROS, it might be helpful to first use ign topic to check the working of any plugins/sensors that you may have

Asked by Gaurav Gupta on 2023-06-04 05:33:53 UTC

Comments