Gazebo | Ignition | Community
Ask Your Question

Javi V's profile - activity

2018-06-01 08:02:09 -0500 received badge  Nice Question (source)
2017-01-25 12:09:58 -0500 received badge  Famous Question (source)
2017-01-23 03:16:09 -0500 commented answer Gazebo 5.4 premature release?

@Jose Luis Rivero Gazebo 5.4.0 up and running, thanks a lot!

2017-01-23 03:15:48 -0500 commented answer Gazebo 5.4 premature release?

@Jose Luis Rivero Gazebo 5.4.0 up and running, thanks a lot!

2017-01-20 11:30:39 -0500 received badge  Notable Question (source)
2017-01-20 10:35:20 -0500 received badge  Popular Question (source)
2017-01-20 06:54:11 -0500 asked a question Gazebo 5.4 premature release?

Today I got the following problem when launching Gazebo (Ubuntu 14.04):

[Err] [RTShaderSystem.cc:414] Unable to find shader lib. Shader generating will fail.[Err] [Server.cc:285] Could not open file[worlds/empty.world]
terminate called recursively
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::lock_error> >'
Aborted (core dumped)
[gazebo-2] process has died [pid 3322, exit code 134, cmd /opt/ros/indigo/lib/gazebo_ros/gzserver --verbose -e ode worlds/empty.world __name:=gazebo __log:=/home/jvgomez/.ros/log/7bf27612-df0f-11e6-a9b3-7824afa13789/gazebo-2.log].

After investigating a bit I saw that I have the following folders:

/usr/share/gazebo
/usr/share/gazebo-5.3
/usr/share/gazebo-5.4

The first two only have a setup.sh but the third one has media and worlds folder. After copying these to /usr/share/gazebo-5.3 everything was working again.

Investigating further, I saw that in /usr/bin there are ony 2 binaries : gazebo and gazebo-5.3.0. In fact, synaptic shows that gazebo5-common package has been updated to 5.4.0-1~trusty while the others are still 5.3.0-1~trusty.

Have been those packages released by error? Or for some reason my update is not complete?

2016-12-01 04:55:54 -0500 commented question Examples of registering a custom sensor (not plugin)

@dhood did you find the solution to this problem? I am having exactly the same problem. Basically I want to add a new sensor without having the recompile Gazebo.

2016-09-02 12:04:28 -0500 received badge  Famous Question (source)
2016-07-20 04:16:16 -0500 received badge  Famous Question (source)
2016-07-01 02:31:26 -0500 commented question Laser incorrect simulation, not REP117 compliant

@nkoenig could you please check this?

2016-06-24 12:24:27 -0500 received badge  Notable Question (source)
2016-06-24 10:56:16 -0500 received badge  Popular Question (source)
2016-06-23 05:25:14 -0500 asked a question Laser incorrect simulation, not REP117 compliant

Hi,

I am writing here instead of reporting a Gazebo issue because I am not sure if I am doing something wrong.

REP117 states that: "Detections that are too close to the sensor to quantify shall be represented by -Inf. Erroneous detections shall be represented by quiet (non-signaling) NaNs. Finally, out of range detections will be represented by +Inf." And this PR implemented it. I do not know which release is that, but Gazebo 5.3.0, the one I am using, has this fix.

However, if I simply insert a Hokuyo laser and place and object too close, we see that the measurements below minimum range are incorrect (they go within the obstacle) and ranges with max_range are reported as max_range:

image description

Furthermore, using the gazebo_ros plugin libgazebo_ros_laser.so I can see that it is reported exactly the same as in the topic visualization (wrong min_range instead of -inf and max_range instead of inf).

Is this a bug or I am doing something wrong?

EDIT: I have tested this in Gazebo7, and max range is converted to +inf correctly, but minimum range keeps doing the same (more or less).

Thanks a lot!

2016-06-05 17:58:40 -0500 received badge  Famous Question (source)
2016-05-27 11:41:41 -0500 marked best answer RGBD camera noise model

I saw there are many sensor models and plugins in order to simulate an RGB camera (either Asus, Kinect, etc). However, I do not see any way to include noise in both RGB and Depth, neither in Gazebo nor in the available plugins. I tried the <noise> tag in the sensor but it seems to have no effect.

Is there any gazebo_ros plugin (or Gazebo plugin) somewhere to simulate the RGB camera more accurately?

Thank you!

For completeness, I include the part of the sensor of my model:

    <sensor type="depth" name="rgbd_camera">
        <camera>
            <horizontal_fov>1.047</horizontal_fov>
            <image>
                <width>640</width>
                <height>480</height>
                <format>R8G8B8</format>
            </image>
            <clip>
                <near>0.05</near>
                <far>30</far>
            </clip>
            <noise>   <!-- This does apparently nothing neither RGB nor depth-->
                <type>gaussian</type>
                <mean>0.0</mean>
                <stddev>5.0</stddev>
            </noise>
        </camera>
        <update_rate>30.0</update_rate>
        <always_on>1</always_on>
        <plugin name="multirotor_rgbd_plugin" filename="libgazebo_ros_openni_kinect.so">
            <imageTopicName>rgb/image_raw</imageTopicName>
            <cameraInfoTopicName>rgb/camera_info</cameraInfoTopicName>
            <pointCloudTopicName>depth/points</pointCloudTopicName>
            <depthImageTopicName>depth/image_raw</depthImageTopicName>
            <depthImageCameraInfoTopicName>depth/camera_info</depthImageCameraInfoTopicName>
            <pointCloudCutoff>0.4</pointCloudCutoff>
            <pointCloudCutoffMax>5.0</pointCloudCutoffMax>
            <frameName>rgbd_camera_link</frameName>
            <cameraName>rgbd_camera</cameraName>
            <updateRate>30.0</updateRate>
        </plugin>
    </sensor>
2016-03-27 20:08:46 -0500 received badge  Notable Question (source)
2016-03-14 15:36:33 -0500 commented question Topic name or index in Subscriber callback
2016-03-14 15:36:14 -0500 received badge  Popular Question (source)
2016-03-14 11:59:07 -0500 commented question Topic name or index in Subscriber callback

@nkoenig I've updated the post.

2016-03-14 11:43:30 -0500 asked a question Topic name or index in Subscriber callback

Hi,

I am creating a model plugin that subscribes to many topics (same name, but only a number changes) and I want all the subscribers to call the same callback. However, if I do that I am not able to identify which subscriber (or topic name) triggered the callback at a given time.

In ROS I saw that it is possible to do this using boost::bind but I cannot make it work in Gazebo, basically because I think the API does not allow it.

Can somebody verify that this is not possible? Or much better, tell me how to identify which subscriber triggers the callback?

EDIT: Posting the code I have tried and corresponding error:

 std::vector<gazebo::transport::SubscriberPtr> _subs;
 size_t n = 10;
 for (size_t i = 0; i < n; ++i) {
    std::stringstream ss;
    ss << "~/ns/base_link/sensor_" << i;
    _subs.emplace_back(
         nh->Subscribe(ss.str(),
         boost::bind(&MyClass::cb, this, _1, i))
     );
}

And the error (removed verbose data):

error: no matching function for call to gazebo::transport::Node::Subscribe(std::basic_stringstream<char>::__string_type, boost::_bi::bind_t<void, boost::_mfi::mf2<void, MyClass, const boost::shared_ptr<const gazebo::msgs::LaserScanStamped>&, long unsigned int>, boost::_bi::list3<boost::_bi::value<MyClass*>, boost::arg<1>, boost::_bi::value<long unsigned int> > >)
      i)));
        ^
note: candidates are:
template<class M, class T> gazebo::transport::SubscriberPtr gazebo::transport::Node::Subscribe(const string&, void           (T::*)(const boost::shared_ptr<const T>&), T*, bool)
   SubscriberPtr Subscribe(const std::string &_topic,
                 ^
/usr/include/gazebo-5.1/gazebo/transport/Node.hh:175:21: note:   template argument deduction/substitution failed:
 mismatched types void (T::*)(const boost::shared_ptr<const T>&) and boost::_bi::bind_t<void, boost::_mfi::mf2<void, MyClass, const boost::shared_ptr<const gazebo::msgs::LaserScanStamped>&, long unsigned int>, boost::_bi::list3<boost::_bi::value<MyClass*>, boost::arg<1>, boost::_bi::value<long unsigned int> > >
      i)));

I get 4 similar errors, one for each Subscribe overload.

Thanks!

2016-03-14 09:00:51 -0500 received badge  Notable Question (source)
2016-03-14 02:54:10 -0500 commented answer Cylinder parameters: elements or attributes

Oops you are right! I am using URDF.

2016-03-14 02:49:53 -0500 received badge  Popular Question (source)
2016-03-11 06:04:29 -0500 asked a question Cylinder parameters: elements or attributes

In the cylinder SDF specification, the radius and length of a cylinder are children elements, as the example in that website shows:

<cylinder>
    <radius>1</radius>
    <length>1.2</length>
 </cylinder>

However, in Gazebo5 this throws the error:

[ERROR] [1457697849.467197389]: Cylinder shape must have both length and radius attributes

Therefore, it looks like Gazebo 5 requires those values as attributes:

<geometry>
    <cylinder length="1.2" radius="1"/>
</geometry>

And this works OK. Which one is correct? Is it a Gazebo bug?

2016-03-07 02:10:39 -0500 received badge  Famous Question (source)
2016-01-27 03:51:21 -0500 received badge  Enthusiast
2016-01-26 01:54:22 -0500 commented answer North East Down (NED) gazebo frame

@chapulina yes, that is what I thought. But the weirdest thing for me is that the behavior does not change if you rotate the ground plane 180deg around X.

2016-01-25 07:36:49 -0500 commented answer North East Down (NED) gazebo frame

Thank you so much for looking into this anyway. It is interesting that with the box instead of the ground plane the physics work.

2016-01-25 02:30:46 -0500 commented answer North East Down (NED) gazebo frame

@chapulina It is not only switching gravity. This would be just a workaround. Gravity switch is just a rotation about 180deg around X axis, while the actual transformation would be from East-North-Up to North-East-Down (180 deg around X and 90 around Z) and this would crete some problems if we really depend on the Earth model (WGS84 in Gazebo). Furthermore, in your video you have the same problem as me: the camera is not behaving OK.

2016-01-22 10:01:45 -0500 commented answer North East Down (NED) gazebo frame

Basically, everything will operate in this NED frame. That means that state estimation and control is done in this frame, camera and sensor inputs are mostly related to the corresponding robot link which is also expressed in the NED frame. Basically, just a full autonomous navigation setup for outdoor UAVs.

2016-01-22 09:50:27 -0500 received badge  Famous Question (source)
2016-01-22 09:50:02 -0500 received badge  Notable Question (source)
2016-01-22 09:49:09 -0500 received badge  Commentator
2016-01-22 09:49:09 -0500 commented answer North East Down (NED) gazebo frame

NED frames are common for outdoor applications. In my case, I want to simulate UAVs. Which kind of constraints you mean?

2016-01-22 09:22:32 -0500 commented answer North East Down (NED) gazebo frame

I am trying to set my simulation using North-East-Down frame, what I am trying to achieve is simply: http://answers.gazebosim.org/question/4514/gazebo-reference-frame-with-z-pointing-downward/?answer=12404#post-id-12404 which you already replied :)

2016-01-21 11:43:18 -0500 received badge  Popular Question (source)
2016-01-20 11:40:23 -0500 asked a question North East Down (NED) gazebo frame

Hi,

I am interested in having a North-East-Down inertial frame in Gazebo. AFAIK this is not possible by just setting an option, and this question remains unanswered.

As a workaround I was trying to flip the camera 180 deg around its X axis and spawn objects in negative Z, but whenever they are below the ground plane they are switched to the positive Z in the next iteration. I tried flipping 180 deg also the ground plane but still the same behavior. Also, the camera gets moved to a "normal"position whenever I try to move it (zoom works OK though, and FPS camera kind of work as well).

Can anybody give me some advice on how to achieve this? Thank you!

EDIT: I added the world I am using to test, contains a cylinder, a inverted gravity and cameras, and a ground plane also rotated (in case it makes any difference, because the same behavior is noticed without flipping the ground plane.

<?xml version="1.0" ?>
<sdf version="1.5">
<world name="test_world">
    <physics type="ode">
        <gravity>0.0 0.0 9.81</gravity>
        <ode>
            <solver>
                <type>quick</type>
                <iters>50</iters>
                <sor>0.8</sor>
            </solver>
        </ode>
        <real_time_update_rate>1000</real_time_update_rate>
        <max_step_size>0.001</max_step_size>
    </physics>

        <gui>
  <camera name="user_camera">
    <pose>1 0 -1 3.141592 0 0</pose>
  </camera>
</gui>

<model name='unit_cylinder_1'>
      <pose>0 0 -1.5 0 0 0</pose>
      <link name='link'>
        <inertial>
          <mass>1</mass>
          <inertia>
            <ixx>1</ixx>
            <ixy>0</ixy>
            <ixz>0</ixz>
            <iyy>1</iyy>
            <iyz>0</iyz>
            <izz>1</izz>
          </inertia>
        </inertial>
        <collision name='collision'>
          <geometry>
            <cylinder>
              <radius>0.5</radius>
              <length>1</length>
            </cylinder>
          </geometry>
          <max_contacts>10</max_contacts>
        </collision>
        <visual name='visual'>
          <geometry>
            <cylinder>
              <radius>0.5</radius>
              <length>1</length>
            </cylinder>
          </geometry>
          <material>
            <script>
              <uri>file://media/materials/scripts/gazebo.material</uri>
              <name>Gazebo/Grey</name>
            </script>
          </material>
        </visual>
        <self_collide>0</self_collide>
        <kinematic>0</kinematic>
      </link>
    </model>

    <include>
         <pose>0 0 0 3.141592 0 0</pose>
        <uri>model://ground_plane</uri>
    </include>
</world>

</sdf>

2016-01-20 09:14:07 -0500 commented question Referencing models from other package's launch files

Try using: <mesh filename="package://&lt;pkg_name&gt;/foo/mesh.dae"/> But make sure that it is finding the world file you are giving as parameter first.