libgazeboplugin

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

libgazeboplugin

BenW2
Hi,

Ive been trying to get gazebo and player working together. I have gazebo installed and able to open some of the example files, but cannot get player to connect with gazebo due to it not finding libgazeboplugin. On investigation it seems that gazebo does not generate this file when it compiles. I select the option in the config to do so, but nothing happens. Could anyone tell me how I can ensure that I am creating libgazeboplugin please? or perhaps a reason why it might not be made.

Thanks

:)
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

BenW2
So I have managed to ensure libgazeboplugin is built now. But I still have problems finding it. Iv stopped using SVN versions of player and am now using the release version 3.0.0. It seems to work fine with stage. Gazebo is still that latest SVN version.

First I run gazebo with the pioneer2dx.world file. This loads fine. I then try to start player and get the following

player /usr/local/share/player/config/gazebo.cfg
Registering driver
Player v.3.0.0-rc3

* Part of the Player/Stage/Gazebo Project [http://playerstage.sourceforge.net].
* Copyright (C) 2000 - 2009 Brian Gerkey, Richard Vaughan, Andrew Howard,
* Nate Koenig, and contributors. Released under the GNU General Public License.
* Player comes with ABSOLUTELY NO WARRANTY.  This is free software, and you
* are welcome to redistribute it under certain conditions; see COPYING
* for details.

error   : Failed to load plugin libgazeboplugin.
error   : libtool reports error: file not found
error   : plugin search path: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/share/stage/worlds:/home/ben:/usr/local/share/player/config:/usr/local/lib/
error   : failed to load plugin: libgazeboplugin
error   : failed to parse config file /usr/local/share/player/config/gazebo.cfg driver blocks

the pioneer2dx.world looks like so...

<?xml version="1.0"?>

<gazebo:world
  xmlns:xi="http://www.w3.org/2001/XInclude"
  xmlns:gazebo="http://playerstage.sourceforge.net/gazebo/xmlschema/#gz" 
  xmlns:model="http://playerstage.sourceforge.net/gazebo/xmlschema/#model" 
  xmlns:sensor="http://playerstage.sourceforge.net/gazebo/xmlschema/#sensor" 
  xmlns:window="http://playerstage.sourceforge.net/gazebo/xmlschema/#window" 
  xmlns:param="http://playerstage.sourceforge.net/gazebo/xmlschema/#param" 
  xmlns:body="http://playerstage.sourceforge.net/gazebo/xmlschema/#body" 
  xmlns:geom="http://playerstage.sourceforge.net/gazebo/xmlschema/#geom" 
  xmlns:joint="http://playerstage.sourceforge.net/gazebo/xmlschema/#joint" 
  xmlns:interface="http://playerstage.sourceforge.net/gazebo/xmlschema/#interface" 
  xmlns:ui="http://playerstage.sourceforge.net/gazebo/xmlschema/#ui"
  xmlns:rendering="http://playerstage.sourceforge.net/gazebo/xmlschema/#rendering" 
  xmlns:controller="http://playerstage.sourceforge.net/gazebo/xmlschema/#controller"
  xmlns:physics="http://playerstage.sourceforge.net/gazebo/xmlschema/#physics" >

  <verbosity>5</verbosity>

  <physics:ode>
    <stepTime>0.03</stepTime>
    <gravity>0 0 -9.8</gravity>
    <cfm>10e-5</cfm>
    <erp>0.3</erp>
     
    <updateRate>-1</updateRate>
  </physics:ode>

  <rendering:gui>
    <type>fltk</type>
    <size>800 600</size>
    <pos>0 0</pos>
    <xyz>0 0 0</xyz>
    <rpy>0 0 0</rpy>
  </rendering:gui>

  <rendering:ogre>
    <ambient>0.2 0.2 0.2 0.2</ambient>
    <sky>
      <material>Gazebo/CloudySky</material>
    </sky>

    <fog>
      <color>1.0 1.0 1.0</color>
      <linearStart>10</linearStart>
      <linearEnd>100</linearEnd>
    </fog>

    <grid>false</grid>

    <shadowTechnique>stencilModulative</shadowTechnique>
  </rendering:ogre>

   
  <model:physical name="plane1_model">
    <xyz>0 0 0</xyz>
    <rpy>0 0 0</rpy>
    <static>true</static>

    <body:plane name="plane1_body">
      <geom:plane name="plane1_geom">
        <normal>0 0 1</normal>
        <size>2000 2000</size>
        <segments>10 10</segments>
        <uvTile>2000 2000</uvTile>
        <material>Gazebo/GrayGrid</material>
      </geom:plane>
    </body:plane>
  </model:physical>

  <model:physical name="sphere1_model">
    <xyz>2.15 -1.68 .3</xyz>
    <rpy>0.0 0.0 0.0</rpy>
    <static>false</static>
    <laserFiducialId>1</laserFiducialId>
    <laserRetro>0.5</laserRetro>

    <body:sphere name="sphere1_body">
      <geom:sphere name="sphere1_geom">
        <size>0.1</size>

        <visual>
          <scale>0.1 0.1 0.1</scale>
          <mesh>unit_sphere</mesh>
          <material>Gazebo/Rocky</material>
        </visual>
      </geom:sphere>
    </body:sphere>
  </model:physical>


 
 

  <model:physical name="pioneer2dx_model1">
    <xyz>0 0 .145</xyz>
    <rpy>0.0 0.0 90.0</rpy>
    <collide>all</collide>

    <model:physical name="laser">
      <xyz>0.15 0 0.18</xyz>

      <attach>
        <parentBody>chassis_body</parentBody>
        <myBody>laser_body</myBody>
      </attach>

      <include embedded="true">
        <xi:include href="models/sicklms200.model" />
      </include>
    </model:physical>

    <include embedded="true">
      <xi:include href="models/pioneer2dx.model" />
    </include>
  </model:physical>

  <model:physical name="pioneer2dx_model2">
    <xyz>0 -1 .145</xyz>
    <rpy>0.0 0.0 -90.0</rpy>
    <collide>all</collide>

    <model:physical name="laser">
      <xyz>0.15 0 0.18</xyz>

      <attach>
        <parentBody>chassis_body</parentBody>
        <myBody>laser_body</myBody>
      </attach>

      <include embedded="true">
        <xi:include href="models/sicklms200.model" />
      </include>
    </model:physical>

    <include embedded="true">
      <xi:include href="models/pioneer2dx.model" />
    </include>
  </model:physical>


  <model:physical name="box1_model">
    <xyz>1 1.5 0.5</xyz>
    <canonicalBody>box1_body</canonicalBody>
    <static>true</static>
    <laserFiducialId>2</laserFiducialId>
    <laserRetro>0.5</laserRetro>

    <body:box name="box1_body">
      <geom:box name="box1_geom">
        <size>1 1 1</size>
        <mass>0.1</mass>
        <visual>
          <size>1 1 1</size>
          <mesh>unit_box</mesh>
          <material>Gazebo/SmileyHappy</material>
        </visual>
      </geom:box>
    </body:box>
  </model:physical>


 
  <model:renderable name="directional_white">
    <enableGravity>false</enableGravity>

    <light>
      <type>directional</type>
      <direction>0 0 -1</direction>
      <diffuseColor>0.4 0.4 0.4</diffuseColor>
      <specularColor>0.1 0.1 0.1</specularColor>
      <range>40</range>

     
      <attenuation>0 0 0</attenuation>
    </light>
  </model:renderable>


 
  <model:renderable name="point_white">
    <xyz>0 3 5</xyz>
    <enableGravity>false</enableGravity>

    <light>
      <type>point</type>
      <diffuseColor>0.8 0.8 0.8</diffuseColor>
      <specularColor>0.1 0.1 0.1</specularColor>
      <range>20</range>

     
      <attenuation>0.3 0.01 0</attenuation>
    </light>
  </model:renderable>


</gazebo:world>





and the gazebo.cfg


# Desc: Player sample configuration file for controlling Gazebo devices
# Date: 18 Apr 2003
# CVS: $Id: gazebo.cfg,v 1.4.2.1 2006/12/16 22:43:23 natepak Exp $

driver
(
  name "gazebo"
  provides ["simulation:0"]
  plugin "libgazeboplugin"
  server_id "default"
)

driver
(
  name "gazebo"
  provides ["position2d:0"]
  gz_id "position_iface_0"
)

driver
(
  name "gazebo"
  provides ["laser:0"]
  gz_id "laser_iface_0"
)

driver
(
  name "vfh"
  provides ["position2d:1"]
  requires ["position2d:0" "laser:0"]
  cell_size 0.1
  window_diameter 61
  sector_angle 1
  safety_dist_0ms 0.2
  safety_dist_1ms 0.4
  max_speed 0.3
  max_turnrate_0ms 75
  max_turnrate_1ms 50
  weight_desired_dir 5.0
  weight_current_dir 3.0
)

driver
(
  name "gazebo"
  provides ["fiducial:0"]
  gz_id "fiducial_iface_0"
)

#driver
#(
#  name "gazebo"
#  provides ["camera:0"]
#  gz_id "camera_iface_1"
#  alwayson 1
#  save 0
#)

#driver
#(
#  name "gazebo"
#  provides ["power:0"]
#  gz_id "robot1"
#)
#

#
#driver
#(
#  name "gazebo"
#  provides ["sonar:0"]
#  gz_id "robot1"
#)
#
#driver
#(
#  name "gazebo"
#  provides ["ptz:0"]
#  gz_id "camera1"
#)
#

#
#driver
#(
#  name "gazebo"
#  provides ["gripper:0"]
#  gz_id "gripper1"
#)
#

#driver
#(
#  name "gazebo"
#  provides ["truth:0"]
#  gz_id "truth1"
#)
#
#driver
#(
#  name "gazebo"
#  provides ["left_disparity::camera:1"]
#  gz_id "stereo1"
#)

Any obvious mistakes?

BenW2 wrote
Hi,

Ive been trying to get gazebo and player working together. I have gazebo installed and able to open some of the example files, but cannot get player to connect with gazebo due to it not finding libgazeboplugin. On investigation it seems that gazebo does not generate this file when it compiles. I select the option in the config to do so, but nothing happens. Could anyone tell me how I can ensure that I am creating libgazeboplugin please? or perhaps a reason why it might not be made.

Thanks

:)
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

BenW2
In reply to this post by BenW2
So I have had a little more luck with a reinstall of gazebo.  Im still using player svn, and Gazebo 8255. The sequence i follow is

1 - player gazebo.cfg
2 - gazebo pioneer2at.world
3 - playerjoy

output from player is ...

invoking player_driver_init()...

 * Part of the Player/Stage Project [http://p
 * Copyright 2000-2006 Richard Vaughan, Andre
ig
 * and contributors. Released under the GNU G
success
  Gazebo Plugin driver creating 1 device
    6665.31.0 is  a simulation interface.
opening /tmp/gazebo-ben-0
opening /tmp/gazebo-ben-0/simulation.default
opening /tmp/gazebo-ben-0/simulation.default
  Gazebo Plugin driver creating 1 device
    6665.4.0 is  a position2d interface.
  Gazebo Plugin driver creating 1 device
    6665.6.0 is  a laser interface.
  Gazebo Plugin driver creating 1 device
    6665.10.0 is  a fiducial interface.

gazebo...

/usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined
<controller:differential_position2d name="controller1">
                                                      ^
/usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined
  <interface:position name="position_iface_0"/>
                                             ^
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103]
  Gazebo Path[/usr/local/share/gazebo]
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115]
  Ogre Path[/usr/local/lib/OGRE]
Gazebo successfully initialized


(could the namespace error be a clue? )

and finally playerjoy...

Connecting to Player at localhost:6665 - playerc warning   : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3

playerc error   : timed out waiting for server reply to request player:0:request:3
playerc error   : failed to get response
terminate called after throwing an instance of 'PlayerCc::PlayerError'
Aborted

listening on 6665
Listening on ports: 6665
accepted TCP client 0 on port 6665, fd 7
Error Subscribing to Gazebo Position2d Interf
error opening device file /tmp/gazebo-ben-0/p
file or directory

I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated.

Thanks

Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

Neostek
I've a similar problem. I have the last section of your problem ("timed out for server reply"). Do you succeed to solve this problem? Please, if you had solved this problem, contact me!! Thanks a lot
BenW2 wrote
So I have had a little more luck with a reinstall of gazebo. Im still using player svn, and Gazebo 8255. The sequence i follow is 1 - player gazebo.cfg 2 - gazebo pioneer2at.world 3 - playerjoy output from player is ... invoking player_driver_init()... * Part of the Player/Stage Project [http://p * Copyright 2000-2006 Richard Vaughan, Andre ig * and contributors. Released under the GNU G success Gazebo Plugin driver creating 1 device 6665.31.0 is a simulation interface. opening /tmp/gazebo-ben-0 opening /tmp/gazebo-ben-0/simulation.default opening /tmp/gazebo-ben-0/simulation.default Gazebo Plugin driver creating 1 device 6665.4.0 is a position2d interface. Gazebo Plugin driver creating 1 device 6665.6.0 is a laser interface. Gazebo Plugin driver creating 1 device 6665.10.0 is a fiducial interface. gazebo... /usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined ^ /usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined ^ [/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103] Gazebo Path[/usr/local/share/gazebo] [/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115] Ogre Path[/usr/local/lib/OGRE] Gazebo successfully initialized (could the namespace error be a clue? ) and finally playerjoy... Connecting to Player at localhost:6665 - playerc warning : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3 playerc error : timed out waiting for server reply to request player:0:request:3 playerc error : failed to get response terminate called after throwing an instance of 'PlayerCc::PlayerError' Aborted listening on 6665 Listening on ports: 6665 accepted TCP client 0 on port 6665, fd 7 Error Subscribing to Gazebo Position2d Interf error opening device file /tmp/gazebo-ben-0/p file or directory I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated. Thanks
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

BenW2
Hi,

Unfortunately not. I have made a number of posts, but no-one seems interested in passing over any ideas. It would be great if you have any success with this problem, as its a major hold up on some of my work.


Neostek wrote
I've a similar problem.
I have the last section of your problem ("timed out for server reply").
Do you succeed to solve this problem?
Please, if you had solved this problem, contact me!!
Thanks a lot

BenW2 wrote
So I have had a little more luck with a reinstall of gazebo.  Im still using player svn, and Gazebo 8255. The sequence i follow is

1 - player gazebo.cfg
2 - gazebo pioneer2at.world
3 - playerjoy

output from player is ...

invoking player_driver_init()...

 * Part of the Player/Stage Project [http://p
 * Copyright 2000-2006 Richard Vaughan, Andre
ig
 * and contributors. Released under the GNU G
success
  Gazebo Plugin driver creating 1 device
    6665.31.0 is  a simulation interface.
opening /tmp/gazebo-ben-0
opening /tmp/gazebo-ben-0/simulation.default
opening /tmp/gazebo-ben-0/simulation.default
  Gazebo Plugin driver creating 1 device
    6665.4.0 is  a position2d interface.
  Gazebo Plugin driver creating 1 device
    6665.6.0 is  a laser interface.
  Gazebo Plugin driver creating 1 device
    6665.10.0 is  a fiducial interface.

gazebo...

/usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined
<controller:differential_position2d name="controller1">
                                                      ^
/usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined
  <interface:position name="position_iface_0" />
                                             ^
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103]
  Gazebo Path[/usr/local/share/gazebo]
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115]
  Ogre Path[/usr/local/lib/OGRE]
Gazebo successfully initialized


(could the namespace error be a clue? )

and finally playerjoy...

Connecting to Player at localhost:6665 - playerc warning   : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3

playerc error   : timed out waiting for server reply to request player:0:request:3
playerc error   : failed to get response
terminate called after throwing an instance of 'PlayerCc::PlayerError'
Aborted

listening on 6665
Listening on ports: 6665
accepted TCP client 0 on port 6665, fd 7
Error Subscribing to Gazebo Position2d Interf
error opening device file /tmp/gazebo-ben-0/p
file or directory

I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

Neostek
I didn't succeed to solve it. But, I've seen that many people have the same problem but anyone has an answer.... I hope that someone can tell to Nate about this problem because I'm trying to solve it about one week ago.
If you succeed to solve it, please contact me.
Thanks a lot!

BenW2 wrote
Hi,

Unfortunately not. I have made a number of posts, but no-one seems interested in passing over any ideas. It would be great if you have any success with this problem, as its a major hold up on some of my work.


Neostek wrote
I've a similar problem.
I have the last section of your problem ("timed out for server reply").
Do you succeed to solve this problem?
Please, if you had solved this problem, contact me!!
Thanks a lot

BenW2 wrote
So I have had a little more luck with a reinstall of gazebo.  Im still using player svn, and Gazebo 8255. The sequence i follow is

1 - player gazebo.cfg
2 - gazebo pioneer2at.world
3 - playerjoy

output from player is ...

invoking player_driver_init()...

 * Part of the Player/Stage Project [http://p
 * Copyright 2000-2006 Richard Vaughan, Andre
ig
 * and contributors. Released under the GNU G
success
  Gazebo Plugin driver creating 1 device
    6665.31.0 is  a simulation interface.
opening /tmp/gazebo-ben-0
opening /tmp/gazebo-ben-0/simulation.default
opening /tmp/gazebo-ben-0/simulation.default
  Gazebo Plugin driver creating 1 device
    6665.4.0 is  a position2d interface.
  Gazebo Plugin driver creating 1 device
    6665.6.0 is  a laser interface.
  Gazebo Plugin driver creating 1 device
    6665.10.0 is  a fiducial interface.

gazebo...

/usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined
<controller:differential_position2d name="controller1">
                                                      ^
/usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined
  <interface:position name="position_iface_0" />
                                             ^
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103]
  Gazebo Path[/usr/local/share/gazebo]
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115]
  Ogre Path[/usr/local/lib/OGRE]
Gazebo successfully initialized


(could the namespace error be a clue? )

and finally playerjoy...

Connecting to Player at localhost:6665 - playerc warning   : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3

playerc error   : timed out waiting for server reply to request player:0:request:3
playerc error   : failed to get response
terminate called after throwing an instance of 'PlayerCc::PlayerError'
Aborted

listening on 6665
Listening on ports: 6665
accepted TCP client 0 on port 6665, fd 7
Error Subscribing to Gazebo Position2d Interf
error opening device file /tmp/gazebo-ben-0/p
file or directory

I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

BenW2
So I have spent pretty much all day going through the code trying to understand whats going on to find the problem.

It seems that on start up the seperate devices should have files created for them in /tmp/gazebo-USER-0/, but the only one that gets created is simulation and a few graphics references. I think it is gazebo/trunk/player/GazeboDriver.cc that creates an instance of each device based on what is defined in gazebo.cfg. I have tried printing debug statements to check that the devices are read in, and it seems that they are and are understood by gazebo. Commenting out the initialisation within the big switch case statement, causes the start up to fail because the device cannot be created. So obviously it thinks that it is creating these files correctly, but I cannot seem to identify why the files are not created.

Can anyone with more knowledge of the code point me towards where in the code I can check this process?

Thanks



Neostek wrote
I didn't succeed to solve it. But, I've seen that many people have the same problem but anyone has an answer.... I hope that someone can tell to Nate about this problem because I'm trying to solve it about one week ago.
If you succeed to solve it, please contact me.
Thanks a lot!

BenW2 wrote
Hi,

Unfortunately not. I have made a number of posts, but no-one seems interested in passing over any ideas. It would be great if you have any success with this problem, as its a major hold up on some of my work.


Neostek wrote
I've a similar problem.
I have the last section of your problem ("timed out for server reply").
Do you succeed to solve this problem?
Please, if you had solved this problem, contact me!!
Thanks a lot

BenW2 wrote
So I have had a little more luck with a reinstall of gazebo.  Im still using player svn, and Gazebo 8255. The sequence i follow is

1 - player gazebo.cfg
2 - gazebo pioneer2at.world
3 - playerjoy

output from player is ...

invoking player_driver_init()...

 * Part of the Player/Stage Project [http://p
 * Copyright 2000-2006 Richard Vaughan, Andre
ig
 * and contributors. Released under the GNU G
success
  Gazebo Plugin driver creating 1 device
    6665.31.0 is  a simulation interface.
opening /tmp/gazebo-ben-0
opening /tmp/gazebo-ben-0/simulation.default
opening /tmp/gazebo-ben-0/simulation.default
  Gazebo Plugin driver creating 1 device
    6665.4.0 is  a position2d interface.
  Gazebo Plugin driver creating 1 device
    6665.6.0 is  a laser interface.
  Gazebo Plugin driver creating 1 device
    6665.10.0 is  a fiducial interface.

gazebo...

/usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined
<controller:differential_position2d name="controller1">
                                                      ^
/usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined
  <interface:position name="position_iface_0" />
                                             ^
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103]
  Gazebo Path[/usr/local/share/gazebo]
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115]
  Ogre Path[/usr/local/lib/OGRE]
Gazebo successfully initialized


(could the namespace error be a clue? )

and finally playerjoy...

Connecting to Player at localhost:6665 - playerc warning   : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3

playerc error   : timed out waiting for server reply to request player:0:request:3
playerc error   : failed to get response
terminate called after throwing an instance of 'PlayerCc::PlayerError'
Aborted

listening on 6665
Listening on ports: 6665
accepted TCP client 0 on port 6665, fd 7
Error Subscribing to Gazebo Position2d Interf
error opening device file /tmp/gazebo-ben-0/p
file or directory

I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

Neostek
I've succeded to solve it.
The problem is in the .cfg file.
You must specify which body contains the interface. So you must change the "gz_id" field with:

model_name::interface_name

and so not only interface_name.

I hope I helped you. If you have other problems or you haven't understood me, please contact me.


BenW2 wrote
So I have spent pretty much all day going through the code trying to understand whats going on to find the problem.

It seems that on start up the seperate devices should have files created for them in /tmp/gazebo-USER-0/, but the only one that gets created is simulation and a few graphics references. I think it is gazebo/trunk/player/GazeboDriver.cc that creates an instance of each device based on what is defined in gazebo.cfg. I have tried printing debug statements to check that the devices are read in, and it seems that they are and are understood by gazebo. Commenting out the initialisation within the big switch case statement, causes the start up to fail because the device cannot be created. So obviously it thinks that it is creating these files correctly, but I cannot seem to identify why the files are not created.

Can anyone with more knowledge of the code point me towards where in the code I can check this process?

Thanks



Neostek wrote
I didn't succeed to solve it. But, I've seen that many people have the same problem but anyone has an answer.... I hope that someone can tell to Nate about this problem because I'm trying to solve it about one week ago.
If you succeed to solve it, please contact me.
Thanks a lot!

BenW2 wrote
Hi,

Unfortunately not. I have made a number of posts, but no-one seems interested in passing over any ideas. It would be great if you have any success with this problem, as its a major hold up on some of my work.


Neostek wrote
I've a similar problem.
I have the last section of your problem ("timed out for server reply").
Do you succeed to solve this problem?
Please, if you had solved this problem, contact me!!
Thanks a lot

BenW2 wrote
So I have had a little more luck with a reinstall of gazebo.  Im still using player svn, and Gazebo 8255. The sequence i follow is

1 - player gazebo.cfg
2 - gazebo pioneer2at.world
3 - playerjoy

output from player is ...

invoking player_driver_init()...

 * Part of the Player/Stage Project [http://p
 * Copyright 2000-2006 Richard Vaughan, Andre
ig
 * and contributors. Released under the GNU G
success
  Gazebo Plugin driver creating 1 device
    6665.31.0 is  a simulation interface.
opening /tmp/gazebo-ben-0
opening /tmp/gazebo-ben-0/simulation.default
opening /tmp/gazebo-ben-0/simulation.default
  Gazebo Plugin driver creating 1 device
    6665.4.0 is  a position2d interface.
  Gazebo Plugin driver creating 1 device
    6665.6.0 is  a laser interface.
  Gazebo Plugin driver creating 1 device
    6665.10.0 is  a fiducial interface.

gazebo...

/usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined
<controller:differential_position2d name="controller1">
                                                      ^
/usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined
  <interface:position name="position_iface_0" />
                                             ^
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103]
  Gazebo Path[/usr/local/share/gazebo]
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115]
  Ogre Path[/usr/local/lib/OGRE]
Gazebo successfully initialized


(could the namespace error be a clue? )

and finally playerjoy...

Connecting to Player at localhost:6665 - playerc warning   : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3

playerc error   : timed out waiting for server reply to request player:0:request:3
playerc error   : failed to get response
terminate called after throwing an instance of 'PlayerCc::PlayerError'
Aborted

listening on 6665
Listening on ports: 6665
accepted TCP client 0 on port 6665, fd 7
Error Subscribing to Gazebo Position2d Interf
error opening device file /tmp/gazebo-ben-0/p
file or directory

I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

amir007
hi,
i have the same problom but i cannot undesrtand ur solution
please explaine ur solution more clearly, i am new to linux and gazebo player .
how i should change this commend line:

1. gazebo pioneer2dx.world
2. player gazebo.cfg
3.playerv -h localhost

thanks for ur consideration
BR
Neostek wrote
I've succeded to solve it.
The problem is in the .cfg file.
You must specify which body contains the interface. So you must change the "gz_id" field with:

model_name::interface_name

and so not only interface_name.

I hope I helped you. If you have other problems or you haven't understood me, please contact me.


BenW2 wrote
So I have spent pretty much all day going through the code trying to understand whats going on to find the problem.

It seems that on start up the seperate devices should have files created for them in /tmp/gazebo-USER-0/, but the only one that gets created is simulation and a few graphics references. I think it is gazebo/trunk/player/GazeboDriver.cc that creates an instance of each device based on what is defined in gazebo.cfg. I have tried printing debug statements to check that the devices are read in, and it seems that they are and are understood by gazebo. Commenting out the initialisation within the big switch case statement, causes the start up to fail because the device cannot be created. So obviously it thinks that it is creating these files correctly, but I cannot seem to identify why the files are not created.

Can anyone with more knowledge of the code point me towards where in the code I can check this process?

Thanks



Neostek wrote
I didn't succeed to solve it. But, I've seen that many people have the same problem but anyone has an answer.... I hope that someone can tell to Nate about this problem because I'm trying to solve it about one week ago.
If you succeed to solve it, please contact me.
Thanks a lot!

BenW2 wrote
Hi,

Unfortunately not. I have made a number of posts, but no-one seems interested in passing over any ideas. It would be great if you have any success with this problem, as its a major hold up on some of my work.


Neostek wrote
I've a similar problem.
I have the last section of your problem ("timed out for server reply").
Do you succeed to solve this problem?
Please, if you had solved this problem, contact me!!
Thanks a lot

BenW2 wrote
So I have had a little more luck with a reinstall of gazebo.  Im still using player svn, and Gazebo 8255. The sequence i follow is

1 - player gazebo.cfg
2 - gazebo pioneer2at.world
3 - playerjoy

output from player is ...

invoking player_driver_init()...

 * Part of the Player/Stage Project [http://p
 * Copyright 2000-2006 Richard Vaughan, Andre
ig
 * and contributors. Released under the GNU G
success
  Gazebo Plugin driver creating 1 device
    6665.31.0 is  a simulation interface.
opening /tmp/gazebo-ben-0
opening /tmp/gazebo-ben-0/simulation.default
opening /tmp/gazebo-ben-0/simulation.default
  Gazebo Plugin driver creating 1 device
    6665.4.0 is  a position2d interface.
  Gazebo Plugin driver creating 1 device
    6665.6.0 is  a laser interface.
  Gazebo Plugin driver creating 1 device
    6665.10.0 is  a fiducial interface.

gazebo...

/usr/local/share/gazebo/worlds/models/pioneer2at.model:18: namespace error : Namespace prefix controller on differential_position2d is not defined
<controller:differential_position2d name="controller1">
                                                      ^
/usr/local/share/gazebo/worlds/models/pioneer2at.model:24: namespace error : Namespace prefix interface on position is not defined
  <interface:position name="position_iface_0" />
                                             ^
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:103]
  Gazebo Path[/usr/local/share/gazebo]
[/home/ben/player_SVN/playerstage/code/gazebo/trunk/server/GazeboConfig.cc:115]
  Ogre Path[/usr/local/lib/OGRE]
Gazebo successfully initialized


(could the namespace error be a clue? )

and finally playerjoy...

Connecting to Player at localhost:6665 - playerc warning   : warning : [Player v.3.0.0-rc2~svn] connected on [localhost:6665] with sock 3

playerc error   : timed out waiting for server reply to request player:0:request:3
playerc error   : failed to get response
terminate called after throwing an instance of 'PlayerCc::PlayerError'
Aborted

listening on 6665
Listening on ports: 6665
accepted TCP client 0 on port 6665, fd 7
Error Subscribing to Gazebo Position2d Interf
error opening device file /tmp/gazebo-ben-0/p
file or directory

I have searched and searched the forums with no luck. For some reason I cant talk to gazebo through player but have no clue why, it works find with Stage 3.0. Any suggestions will be much appreciated.

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: libgazeboplugin

ahmad33
In reply to this post by BenW2
Hi,
how did you build libgazeboplugin
thanks



BenW2 wrote
So I have managed to ensure libgazeboplugin is built now. But I still have problems finding it. Iv stopped using SVN versions of player and am now using the release version 3.0.0. It seems to work fine with stage. Gazebo is still that latest SVN version.

First I run gazebo with the pioneer2dx.world file. This loads fine. I then try to start player and get the following

player /usr/local/share/player/config/gazebo.cfg
Registering driver
Player v.3.0.0-rc3

* Part of the Player/Stage/Gazebo Project [http://playerstage.sourceforge.net].
* Copyright (C) 2000 - 2009 Brian Gerkey, Richard Vaughan, Andrew Howard,
* Nate Koenig, and contributors. Released under the GNU General Public License.
* Player comes with ABSOLUTELY NO WARRANTY.  This is free software, and you
* are welcome to redistribute it under certain conditions; see COPYING
* for details.

error   : Failed to load plugin libgazeboplugin.
error   : libtool reports error: file not found
error   : plugin search path: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/share/stage/worlds:/home/ben:/usr/local/share/player/config:/usr/local/lib/
error   : failed to load plugin: libgazeboplugin
error   : failed to parse config file /usr/local/share/player/config/gazebo.cfg driver blocks

the pioneer2dx.world looks like so...

<?xml version="1.0"?>

<gazebo:world
  xmlns:xi="http://www.w3.org/2001/XInclude"
  xmlns:gazebo="http://playerstage.sourceforge.net/gazebo/xmlschema/#gz" 
  xmlns:model="http://playerstage.sourceforge.net/gazebo/xmlschema/#model" 
  xmlns:sensor="http://playerstage.sourceforge.net/gazebo/xmlschema/#sensor" 
  xmlns:window="http://playerstage.sourceforge.net/gazebo/xmlschema/#window" 
  xmlns:param="http://playerstage.sourceforge.net/gazebo/xmlschema/#param" 
  xmlns:body="http://playerstage.sourceforge.net/gazebo/xmlschema/#body" 
  xmlns:geom="http://playerstage.sourceforge.net/gazebo/xmlschema/#geom" 
  xmlns:joint="http://playerstage.sourceforge.net/gazebo/xmlschema/#joint" 
  xmlns:interface="http://playerstage.sourceforge.net/gazebo/xmlschema/#interface" 
  xmlns:ui="http://playerstage.sourceforge.net/gazebo/xmlschema/#ui"
  xmlns:rendering="http://playerstage.sourceforge.net/gazebo/xmlschema/#rendering" 
  xmlns:controller="http://playerstage.sourceforge.net/gazebo/xmlschema/#controller"
  xmlns:physics="http://playerstage.sourceforge.net/gazebo/xmlschema/#physics" >

  <verbosity>5</verbosity>

  <physics:ode>
    <stepTime>0.03</stepTime>
    <gravity>0 0 -9.8</gravity>
    <cfm>10e-5</cfm>
    <erp>0.3</erp>
     
    <updateRate>-1</updateRate>
  </physics:ode>

  <rendering:gui>
    <type>fltk</type>
    <size>800 600</size>
    <pos>0 0</pos>
    <xyz>0 0 0</xyz>
    <rpy>0 0 0</rpy>
  </rendering:gui>

  <rendering:ogre>
    <ambient>0.2 0.2 0.2 0.2</ambient>
    <sky>
      <material>Gazebo/CloudySky</material>
    </sky>

    <fog>
      <color>1.0 1.0 1.0</color>
      <linearStart>10</linearStart>
      <linearEnd>100</linearEnd>
    </fog>

    <grid>false</grid>

    <shadowTechnique>stencilModulative</shadowTechnique>
  </rendering:ogre>

   
  <model:physical name="plane1_model">
    <xyz>0 0 0</xyz>
    <rpy>0 0 0</rpy>
    <static>true</static>

    <body:plane name="plane1_body">
      <geom:plane name="plane1_geom">
        <normal>0 0 1</normal>
        <size>2000 2000</size>
        <segments>10 10</segments>
        <uvTile>2000 2000</uvTile>
        <material>Gazebo/GrayGrid</material>
      </geom:plane>
    </body:plane>
  </model:physical>

  <model:physical name="sphere1_model">
    <xyz>2.15 -1.68 .3</xyz>
    <rpy>0.0 0.0 0.0</rpy>
    <static>false</static>
    <laserFiducialId>1</laserFiducialId>
    <laserRetro>0.5</laserRetro>

    <body:sphere name="sphere1_body">
      <geom:sphere name="sphere1_geom">
        <size>0.1</size>

        <visual>
          <scale>0.1 0.1 0.1</scale>
          <mesh>unit_sphere</mesh>
          <material>Gazebo/Rocky</material>
        </visual>
      </geom:sphere>
    </body:sphere>
  </model:physical>


 
 

  <model:physical name="pioneer2dx_model1">
    <xyz>0 0 .145</xyz>
    <rpy>0.0 0.0 90.0</rpy>
    <collide>all</collide>

    <model:physical name="laser">
      <xyz>0.15 0 0.18</xyz>

      <attach>
        <parentBody>chassis_body</parentBody>
        <myBody>laser_body</myBody>
      </attach>

      <include embedded="true">
        <xi:include href="models/sicklms200.model" />
      </include>
    </model:physical>

    <include embedded="true">
      <xi:include href="models/pioneer2dx.model" />
    </include>
  </model:physical>

  <model:physical name="pioneer2dx_model2">
    <xyz>0 -1 .145</xyz>
    <rpy>0.0 0.0 -90.0</rpy>
    <collide>all</collide>

    <model:physical name="laser">
      <xyz>0.15 0 0.18</xyz>

      <attach>
        <parentBody>chassis_body</parentBody>
        <myBody>laser_body</myBody>
      </attach>

      <include embedded="true">
        <xi:include href="models/sicklms200.model" />
      </include>
    </model:physical>

    <include embedded="true">
      <xi:include href="models/pioneer2dx.model" />
    </include>
  </model:physical>


  <model:physical name="box1_model">
    <xyz>1 1.5 0.5</xyz>
    <canonicalBody>box1_body</canonicalBody>
    <static>true</static>
    <laserFiducialId>2</laserFiducialId>
    <laserRetro>0.5</laserRetro>

    <body:box name="box1_body">
      <geom:box name="box1_geom">
        <size>1 1 1</size>
        <mass>0.1</mass>
        <visual>
          <size>1 1 1</size>
          <mesh>unit_box</mesh>
          <material>Gazebo/SmileyHappy</material>
        </visual>
      </geom:box>
    </body:box>
  </model:physical>


 
  <model:renderable name="directional_white">
    <enableGravity>false</enableGravity>

    <light>
      <type>directional</type>
      <direction>0 0 -1</direction>
      <diffuseColor>0.4 0.4 0.4</diffuseColor>
      <specularColor>0.1 0.1 0.1</specularColor>
      <range>40</range>

     
      <attenuation>0 0 0</attenuation>
    </light>
  </model:renderable>


 
  <model:renderable name="point_white">
    <xyz>0 3 5</xyz>
    <enableGravity>false</enableGravity>

    <light>
      <type>point</type>
      <diffuseColor>0.8 0.8 0.8</diffuseColor>
      <specularColor>0.1 0.1 0.1</specularColor>
      <range>20</range>

     
      <attenuation>0.3 0.01 0</attenuation>
    </light>
  </model:renderable>


</gazebo:world>





and the gazebo.cfg


# Desc: Player sample configuration file for controlling Gazebo devices
# Date: 18 Apr 2003
# CVS: $Id: gazebo.cfg,v 1.4.2.1 2006/12/16 22:43:23 natepak Exp $

driver
(
  name "gazebo"
  provides ["simulation:0"]
  plugin "libgazeboplugin"
  server_id "default"
)

driver
(
  name "gazebo"
  provides ["position2d:0"]
  gz_id "position_iface_0"
)

driver
(
  name "gazebo"
  provides ["laser:0"]
  gz_id "laser_iface_0"
)

driver
(
  name "vfh"
  provides ["position2d:1"]
  requires ["position2d:0" "laser:0"]
  cell_size 0.1
  window_diameter 61
  sector_angle 1
  safety_dist_0ms 0.2
  safety_dist_1ms 0.4
  max_speed 0.3
  max_turnrate_0ms 75
  max_turnrate_1ms 50
  weight_desired_dir 5.0
  weight_current_dir 3.0
)

driver
(
  name "gazebo"
  provides ["fiducial:0"]
  gz_id "fiducial_iface_0"
)

#driver
#(
#  name "gazebo"
#  provides ["camera:0"]
#  gz_id "camera_iface_1"
#  alwayson 1
#  save 0
#)

#driver
#(
#  name "gazebo"
#  provides ["power:0"]
#  gz_id "robot1"
#)
#

#
#driver
#(
#  name "gazebo"
#  provides ["sonar:0"]
#  gz_id "robot1"
#)
#
#driver
#(
#  name "gazebo"
#  provides ["ptz:0"]
#  gz_id "camera1"
#)
#

#
#driver
#(
#  name "gazebo"
#  provides ["gripper:0"]
#  gz_id "gripper1"
#)
#

#driver
#(
#  name "gazebo"
#  provides ["truth:0"]
#  gz_id "truth1"
#)
#
#driver
#(
#  name "gazebo"
#  provides ["left_disparity::camera:1"]
#  gz_id "stereo1"
#)

Any obvious mistakes?

BenW2 wrote
Hi,

Ive been trying to get gazebo and player working together. I have gazebo installed and able to open some of the example files, but cannot get player to connect with gazebo due to it not finding libgazeboplugin. On investigation it seems that gazebo does not generate this file when it compiles. I select the option in the config to do so, but nothing happens. Could anyone tell me how I can ensure that I am creating libgazeboplugin please? or perhaps a reason why it might not be made.

Thanks

:)