Gazebo | Ignition | Community
Ask Your Question

Can´t launch two plugins in gazebo ros-kinetic

asked 2020-04-29 10:32:44 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

Hello there i´m new to ros and gazebo and have some question to my "project" I want my custom robto to drive and scan the location. I managed to integrate the driving part. But when i want to integrate the Laserscans i can´t drive my robot anymore but i see the laserscans. When i check rostopic there is no cmd_vel anymore and also no odom. What´s the mistake in the code ?

This is my model.gazebo file: The part for the diff_drive

    <plugin filename="" name="differential_drive_controller">

And the Part for the Laserscan:

<gazebo reference="lidar_link">
    <sensor type="ray" name="head_hokuyo_sensor">
      <pose>0 0 0 0 0 0</pose>
      <plugin name="gazebo_ros_head_hokuyo_controller" filename="">

I launch it with launch file

<?xml version="1.0" encoding="UTF-8"?>
  <arg name="model" default="$(find test_description)/urdf/model_file.urdf.xacro" />
  <arg name="rvizconfig" default="$(find test_description)/rviz/urdf.rviz" />
  <arg name="paused" default="false"/>
  <arg name="use_sim_time" default="true"/>
  <arg name="gui" default="true"/>
  <arg name="gui_state_publisher" default="false"/>
  <arg name="headless" default="false"/>
  <arg name="debug" default="false"/>

  <include file="$(find gazebo_ros)/launch/empty_world.launch">
    <arg name="debug" value="$(arg debug)" />
    <arg name="gui" value="$(arg gui)" />
    <arg name="paused" value="$(arg paused)"/>
    <arg name="use_sim_time" value="$(arg use_sim_time)"/>
    <arg name="headless" value="$(arg headless)"/>

  <node name="urdf_spawner" pkg="gazebo_ros" type="spawn_model"
        args="-z 1.0 -unpause -urdf -model robot -param robot_description" respawn="false" output="screen" />
  <include file="$(find test_description)/launch/test_rviz.launch"></include>
  <include file="$(find test_description)/launch/test_gazebo.launch"></include>
  <param name="robot_description" command="$(find xacro)/xacro --inorder $(arg model)"/>
  <node pkg="robot_state_publisher" type="robot_state_publisher"  name="robot_state_publisher">
    <param name="publish_frequency" type="double" value="30.0" />
  <node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher">
    <param name="use_gui" value="False"/>
  <node name="rviz" pkg="rviz" type="rviz" args="-d $(arg rvizconfig)"/>

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted

answered 2020-05-05 09:01:38 -0500

ahcorde gravatar image


can you provide more details? Do you see any errors in the terminal? Can you include in your launch file <arg name="verbose" value="true" /> bellow <arg name="headless" value="$(arg headless)"/> ? Please check the output and provide more details about the links and the robot model.


edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower


Asked: 2020-04-29 10:32:44 -0500

Seen: 22 times

Last updated: Apr 29