Gazebo | Ignition | Community
Ask Your Question

Jim Rothrock's profile - activity

2018-10-01 10:11:13 -0500 received badge  Nice Answer (source)
2018-02-19 16:52:16 -0500 received badge  Guru (source)
2018-02-19 16:52:16 -0500 received badge  Great Answer (source)
2015-10-31 12:30:32 -0500 marked best answer Gazebo 1.9.1 does not cast shadows on COLLADA meshes

I rendered this image with Gazebo 1.9.1, ROS Hydro, and Ubuntu 12.04 LTS:

image description

The robot casts shadows, and the robot and terrain receive them, but the starting platform and the chair (both COLLADA meshes) do not, but should. I thought there might be a problem with my SketchUp-generated starting platform DAE file, so I put the chair from /opt/ros/hydro/share/gazebo_plugins/Media/models/chair/models/Chair.dae into the scene. Is there an element that I need to add to my DAE files in order for them to receive shadows, or is receiving shadows on DAE meshes a missing feature in OGRE or Gazebo?

2015-07-30 04:09:09 -0500 received badge  Nice Answer (source)
2015-05-29 01:31:02 -0500 received badge  Good Answer (source)
2015-05-29 01:30:35 -0500 received badge  Good Answer (source)
2015-05-29 01:30:35 -0500 received badge  Enlightened (source)
2015-05-29 01:30:32 -0500 received badge  Student (source)
2015-03-17 19:28:32 -0500 answered a question Simple mobile base simulation not working in Gazebo

base_caster_joint is fixed, so caster_wheel cannot rotate. The friction between it and the ground probably is keeping the robot from moving. You can try setting caster_wheel's friction to zero. Alternatively, you can add a gazebo element and set base_caster_joint's type to "ball". See http://answers.ros.org/question/138736/urdf-alternative-of-sdf-revolute2-joint-type.

2015-01-12 12:52:46 -0500 answered a question Is it possible to add custom texture file?

If you are running Gazebo from a ROS launch file, add the following to package.xml in the package that contains the launch file:

<export>
  <gazebo_ros gazebo_media_path="${prefix}"/>
</export>

This causes Gazebo to search <package directory>/models for models and <package directory>/media for materials.

2014-12-04 04:47:44 -0500 received badge  Famous Question (source)
2014-11-19 11:55:16 -0500 commented answer Contact sensor error when using Gazebo 2.2.3

You need a collision block in your link. Also, in order to determine the name to put in the Gazebo contact sensor's <collision> element, you need to generate an SDF from the URDF, then search for "LFootBumperLeft_frame". There should be a collision block in the SDF that includes that text as part of its name.

2014-11-19 11:51:30 -0500 commented answer Create Vehicle with Suspension?

Yes, that's right.

2014-11-14 05:42:28 -0500 received badge  Famous Question (source)
2014-11-14 05:42:28 -0500 received badge  Notable Question (source)
2014-11-03 12:28:32 -0500 answered a question Create Vehicle with Suspension?

The vehicle defined in the ackermann_vehicle metapackage (http://wiki.ros.org/ackermann_vehicle) has a shock absorber for each wheel.

2014-10-17 04:21:30 -0500 received badge  Famous Question (source)
2014-10-13 12:00:43 -0500 received badge  Nice Answer (source)
2014-10-10 19:14:21 -0500 received badge  Necromancer (source)
2014-10-10 19:14:21 -0500 received badge  Self-Learner (source)
2014-10-10 13:57:02 -0500 answered a question Contact sensor error when using Gazebo 2.2.3

I was given the solution to this problem by Felix Messmer. The name within the <collision> element must be of the form <link name>_collision. Here is a contact specification that works:

<gazebo reference="gripper_fixed_jaw">
  <sensor name="fixed_jaw_contact_sensor" type="contact">
    <always_on>true</always_on>
    <update_rate>${contact_sensor_update_rate}</update_rate>
    <contact>
      <!-- When using ROS Indigo and Gazebo 2.2.3, the name specified here
           must be <link name>_collision. -->
      <collision>gripper_fixed_jaw_collision</collision>
    </contact>
    <plugin name="fixed_jaw_bumper" filename="libgazebo_ros_bumper.so">
      <bumperTopicName>fixed_jaw_contact_sensor_state</bumperTopicName>
      <frameName>gripper_fixed_jaw</frameName>
    </plugin>
  </sensor>
</gazebo>
2014-10-08 17:20:27 -0500 commented answer Strange behaviour of robot model when using Joint::SetVelocity (VelocityJointInterface)

When I wrote "set each controller's PID parameters to appropriate values," I was referring to /gazebo_ros_control/pid_gains. Sorry for the confusion. Also, I was incorrect in saying that you should replace velocity_controllers/JointVelocityController with effort_controllers/JointVelocityController. You should use velocity_controllers/JointVelocityController, but set PID parameters in /gazebo_ros_control/pid_gains.

2014-10-07 13:15:54 -0500 answered a question Strange behaviour of robot model when using Joint::SetVelocity (VelocityJointInterface)

To help debug the problem, you could replace velocity_controllers/JointVelocityController with effort_controllers/JointVelocityController, then set each controller's PID parameters to appropriate values. This will cause DefaultRobotHWSim to use SetForce() instead of SetVelocity(). Links will still drop, however, because each PID controller will not apply any force to its joint until the joint has a non-zero velocity. The links will just drop slowly. The only way to prevent this with PID control is to use effort_controllers/JointPositionController, then set joint positions instead of velocities.

2014-09-28 08:55:24 -0500 received badge  Notable Question (source)
2014-09-21 04:05:37 -0500 received badge  Popular Question (source)
2014-09-01 16:36:20 -0500 received badge  Critic
2014-09-01 16:35:55 -0500 received badge  Citizen Patrol
2014-08-30 17:05:00 -0500 asked a question Contact sensor error when using Gazebo 2.2.3

I have just moved my code from Ubuntu 12.04 LTS and ROS Hydro to Ubuntu 14.04 LTS and ROS Indigo. My robot is using Gazebo contact sensors with the libgazebo_ros_bumper.so plugin. The sensors worked correctly with the version of Gazebo used by Hydro (1.9.6), but with Indigo I get the following error:

***** Internal Program Error - assertion (this->customContactPublishers.count(name) > 0)
failed in std::string gazebo::physics::ContactManager::CreateFilter(const string&, const
std::vector<std::basic_string<char> >&):
/tmp/buildd/gazebo2-2.2.3/gazebo/physics/ContactManager.cc(329): Failed to create a custom
filter
Service call failed: transport error completing service call: unable to receive data from
sender, check sender's logs for details
Aborted (core dumped)

Here is a contact specification from the robot's URDF file:

<gazebo reference="gripper_fixed_jaw">
  <sensor name="fixed_jaw_contact_sensor" type="contact">
    <always_on>true</always_on>
    <update_rate>${contact_sensor_update_rate}</update_rate>
    <contact>
      <collision>collision</collision>
    </contact>
    <plugin name="fixed_jaw_bumper" filename="libgazebo_ros_bumper.so">
      <bumperTopicName>fixed_jaw_contact_sensor_state</bumperTopicName>
      <frameName>gripper_fixed_jaw</frameName>
    </plugin>
  </sensor>
</gazebo>

Is there something that needs to be changed in this specification in order to work with Gazebo 2.2.3?

2014-08-28 13:04:53 -0500 received badge  Famous Question (source)
2014-05-17 14:01:23 -0500 received badge  Notable Question (source)
2014-05-17 14:01:23 -0500 received badge  Popular Question (source)
2014-02-21 18:55:48 -0500 received badge  Popular Question (source)
2014-02-13 11:48:59 -0500 received badge  Commentator
2014-02-13 11:47:56 -0500 commented answer Gazebo_ros_pkgs: No p gain specified for pid in PositionJointInterface

The fix requires a change to Gazebo. If a joint doesn't have a PID controller, gazebo_ros_control calls joint->SetAngle(). Gazebo doesn't handle friction well when SetAngle() is used. The ability to specify a PID controller for each joint was added as a work-around for this issue.

2014-02-11 15:49:51 -0500 answered a question Gazebo_ros_pkgs: No p gain specified for pid in PositionJointInterface

What type of hardware interface did you specify in your URDF file? PositionJointInterface? EffortJointInterface? If you are using PositionJointInterface, try specifying PID controller gains in a file similar to this:

# gazebo_ros_control_params.yaml
gazebo_ros_control/pid_gains:
  shoulder_joint: {p: 1.0, i: 0.0, d: 1.0}
  # More joints...

In your launch file, load the PID gains in a manner similar to this:

<rosparam file="$(find yourrobot_gazebo)/config/gazebo_ros_control_params.yaml" command="load"/>

Using PositionJointInterface without a PID controller works sometimes, but not always. In particular, friction does not work well without a PID controller. This problem is discussed in the comments for pull request #135, which you mentioned above.

2014-02-11 12:28:02 -0500 asked a question Does gazebo_ros_depth_camera with "points" output produce a color point cloud?

I am using gazebo_ros_depth_camera to generate a point cloud with Gazebo 1.9.2, ROS Hydro, and Ubuntu 12.04 LTS. Here is the relevant section of my URDF file:

<gazebo reference="bottom_mast_camera">
  <sensor name="bottom_mast_camera" type="depth">
    <always_on>true</always_on>
    <update_rate>${mast_cam_frame_rate}</update_rate>

    <camera>
      <horizontal_fov>${mast_cam_h_fov}</horizontal_fov>
      <image>
        <width>${mast_cam_img_width}</width>
        <height>${mast_cam_img_height}</height>
        <format>R8G8B8</format>
      </image>
      <clip>
        <near>${mast_cam_near_clip}</near>
        <far>${mast_cam_far_clip}</far>
      </clip>
      <depth_camera>
        <output>points</output>
      </depth_camera>
    </camera>

    <plugin name="bottom_mast_depth_camera"
            filename="libgazebo_ros_depth_camera.so">
      <cameraName>bottom_mast_camera</cameraName>
      <frameName>bottom_mast_camera_frame</frameName>
      <updateRate>${mast_cam_frame_rate}</updateRate>
      <pointCloudCutoff>2.0</pointCloudCutoff>
    </plugin>
  </sensor>
</gazebo>

Notice that I am using "points" in the <output> element, not "depths". Is such a point cloud supposed to be a color point cloud? I found the Gazebo source code that creates the point cloud, and it is producing a color point cloud. However, when I subscribe to the cloud on a ROS topic, the green and blue values are always zero. Red is usually 128 or 160. <output>depths</output> results in a correct color point cloud.