Using this repo with Melodic and Ubuntu 18.04
Closed this issue ยท 14 comments
If you are using newer version of Ubuntu and ROS like me, e.g., 18.04 and Melodic, you might encounter the following issue
When execute the command roslaunch simple_arm robot_spawn.launch
The following happens.
[INFO] [1533922425.774471, 261.179000]: Spawn status: SpawnModel: Entity pushed to spawn queue, but spawn service timed out waiting for entity to appear in simulation under the name simple_arm
[ERROR] [1533922425.775607, 261.179000]: Spawn service failed. Exiting.
[urdf_spawner-7] process has died [pid 8686, exit code 1, cmd /opt/ros/melodic/lib/gazebo_ros/spawn_model -urdf -param robot_description -x 0 -y 0 -z 0 -R 0 -P 0 -Y 0 -model simple_arm __name:=urdf_spawner
The hint is just a few lines away as the following
[ WARN] [1533922426.361753519, 261.179000000]: Deprecated syntax, please prepend 'hardware_interface/' to 'EffortJointInterface' within the <hardwareInterface> tag in joint 'joint_1'.
[ WARN] [1533922426.362443170, 261.179000000]: Deprecated syntax, please prepend 'hardware_interface/' to 'EffortJointInterface' within the <hardwareInterface> tag in joint 'joint_2'.
It turns out the urdf file is a bit outdated. The file is located at ./urdf/simple_arm.urdf.xacro
. Fix it and next time you launch simple_arm all will be well.
Still getting the same error!
Had the same problem; fixed the files and still saw that error. It got resolved when I ran roscore
from the same environment, however.
I also fixed the simple_arm.urdf.xacro
file as described above:
<!--Transmission and actuators-->
<transmission name="tran1">
<type>transmission_interface/SimpleTransmission</type>
<joint name="joint_1">
<hardwareInterface>hardware_interface/EffortJointInterface</hardwareInterface>
</joint>
<actuator name="motor1">
<hardwareInterface>hardware_interface/EffortJointInterface</hardwareInterface>
<mechanicalReduction>1</mechanicalReduction>
</actuator>
</transmission>
<transmission name="tran2">
<type>transmission_interface/SimpleTransmission</type>
<joint name="joint_2">
<hardwareInterface>hardware_interface/EffortJointInterface</hardwareInterface>
</joint>
<actuator name="motor2">
<hardwareInterface>hardware_interface/EffortJointInterface</hardwareInterface>
<mechanicalReduction>1</mechanicalReduction>
</actuator>
</transmission>
I am using roslaunch simple_arm robot_spawn.launch
to start the simulation. Below is some of the terminal output I still get (the warnings are gone). Any chance you can help me understand how I use roscore
to fix this?
ROS_MASTER_URI=http://localhost:11311
process[joint_state_publisher-1]: started with pid [5985]
process[robot_state_publisher-2]: started with pid [5986]
process[simple_arm/spawner-3]: started with pid [5987]
process[gazebo-4]: started with pid [5991]
process[gazebo_gui-5]: started with pid [5993]
process[urdf_spawner-6]: started with pid [5996]
[INFO] [1549209659.772957, 0.000000]: Controller Spawner: Waiting for service controller_manager/load_controller
[ INFO] [1549209660.180199028]: Finished loading Gazebo ROS API Plugin.
[ INFO] [1549209660.185877442]: waitForService: Service [/gazebo_gui/set_physics_properties] has not been advertised, waiting...
[ INFO] [1549209660.280082688]: Finished loading Gazebo ROS API Plugin.
[ INFO] [1549209660.289901841]: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
[INFO] [1549209660.837648, 0.000000]: Loading model XML from ros parameter robot_description
[INFO] [1549209660.846084, 0.000000]: Waiting for service /gazebo/spawn_urdf_model
[INFO] [1549209661.153316, 0.000000]: Calling service /gazebo/spawn_urdf_model
[INFO] [1549209661.477608, 261.179000]: Spawn status: SpawnModel: Entity pushed to spawn queue, but spawn service timed out waiting for entity to appear in simulation under the name simple_arm
[ERROR] [1549209661.480397, 261.179000]: Spawn service failed. Exiting.
[urdf_spawner-6] process has died [pid 5996, exit code 1, cmd /opt/ros/melodic/lib/gazebo_ros/spawn_model -urdf -param robot_description -x 0 -y 0 -z 0 -R 0 -P 0 -Y 0 -model simple_arm __name:=urdf_spawner __log:=/home/cyberams/.ros/log/c0eeb8fe-27cc-11e9-99d0-000c29ed7d8e/urdf_spawner-6.log].
log file: /home/cyberams/.ros/log/c0eeb8fe-27cc-11e9-99d0-000c29ed7d8e/urdf_spawner-6*.log
[ INFO] [1549209662.330640045, 261.179000000]: Camera Plugin: Using the 'robotNamespace' param: '/'
[ INFO] [1549209662.339560390, 261.179000000]: Camera Plugin (ns = /) <tf_prefix_>, set to ""
[ INFO] [1549209662.396577773, 261.179000000]: Loading gazebo_ros_control plugin
[ INFO] [1549209662.396993602, 261.179000000]: Starting gazebo_ros_control plugin in namespace: /simple_arm
[ INFO] [1549209662.398725036, 261.179000000]: gazebo_ros_control plugin is waiting for model URDF in parameter [/robot_description] on the ROS param server.
[ INFO] [1549209662.557855379, 261.179000000]: Loaded gazebo_ros_control.
[ INFO] [1549209662.599277788, 261.201000000]: waitForService: Service [/gazebo/set_physics_properties] is now available.
[INFO] [1549209662.815112, 261.325000]: Controller Spawner: Waiting for service controller_manager/switch_controller
[INFO] [1549209662.836359, 261.327000]: Controller Spawner: Waiting for service controller_manager/unload_controller
[ INFO] [1549209662.836787225, 261.327000000]: Physics dynamic reconfigure ready.
[INFO] [1549209662.850672, 261.327000]: Loading controller: joint_state_controller
[INFO] [1549209662.940487, 261.365000]: Loading controller: joint_1_position_controller
[INFO] [1549209663.252956, 261.529000]: Loading controller: joint_2_position_controller
[INFO] [1549209663.620970, 261.715000]: Controller Spawner: Loaded controllers: joint_state_controller, joint_1_position_controller, joint_2_position_controller
[INFO] [1549209663.654644, 261.726000]: Started controllers: joint_state_controller, joint_1_position_controller, joint_2_position_controller
VMware: vmw_ioctl_command error Invalid argument.
Aborted (core dumped)
[gazebo_gui-5] process has died [pid 5993, exit code 134, cmd /opt/ros/melodic/lib/gazebo_ros/gzclient __name:=gazebo_gui __log:=/home/cyberams/.ros/log/c0eeb8fe-27cc-11e9-99d0-000c29ed7d8e/gazebo_gui-5.log].
log file: /home/cyberams/.ros/log/c0eeb8fe-27cc-11e9-99d0-000c29ed7d8e/gazebo_gui-5*.log
I had to do two things that are not named in the lesson:
- Fix the files as shown here: sunsided@12dc5ba
- Call
rosdep install -i simple_arm
in the environment
I have fixed this issue with following PR:
ros-simulation/gazebo_ros_pkgs#1024
Now I fixed this problem!
- rosdep check simple_arm
: if not installed then 2. - rosdep install -i simple_arm
It will be working
I had to do two things that are not named in the lesson:
- Fix the files as shown here: sunsided@12dc5ba
- Call
rosdep install -i simple_arm
in the environment
and also > * Fix the files as shown here: sunsided@12dc5ba
As suggested by @sunsided I also needed to run roscore first in a different terminal:
Had the same problem; fixed the files and still saw that error. It got resolved when I ran
roscore
from the same environment, however.
Specifically I:
- Made the suggested fixes to /urdf/simple_arm.urdf.xacro
- Ran
rosdep install -i simple_arm
- Ran
roscore
in terminal - Ran
roslaunch simple_arm robot_spawn.launch
in second terminal
I did do the changes in the urdf.xacro, run rosdep and roscore in terminal before roslaunch. But it still gives me the same error :/
I'm having the same issue where Gazebo launches and then stays on a black screen while the terminal has the warning [WARN] [1584551552.862596, 0.000000]: Controller Spawner couldn't find the expected controller_manager ROS interface.
EDIT:
I followed the instructions as described by @willhunt and got it to work!
NOTE that Gazevo takes a very long time to start up. It took about 2 hours for me
i am still getting an error ...pls help
[ERROR] [1591443981.826796, 261.179000]: Spawn service failed. Exiting.
[urdf_spawner-6] process has died [pid 19183, exit code 1, cmd /opt/ros/melodic/lib/gazebo_ros/spawn_model -urdf -param robot_description -x 0 -y 0 -z 0 -R 0 -P 0 -Y 0
Same as @cheriyanhomey . After having followed all of these, I'm getting
Spawn service failed. Exiting.
Did not understand @marcin-sielski 's link. Where do we find that file where we have to insert that time.Now() command?
Using gazebo with Melodic on Ubuntu 18.04
When running the instructions rosrun gazebo_ros spawn_model -file </path_to_new_urdf/file_name.urdf> -urdf -x 0 -y 0 -z 1 -model panda
, I get the error output below.
[INFO] [1620980158.998395]: Loading model XML from file franka_description/robots/panda_arm.urdf .xacro
[INFO] [1620980159.002218]: Waiting for service /gazebo/ spawn_ urdf model
[INFO] [1620980159.015941]: Calling service /gazebo/spawn_ urdf model
[INFO] [1620980169.031581]: Spawn status: SpawnModel: Entity pushed to spawn queue, but spawn service timed out waiting for entity to appear in simulation under the name panda
[ERROR] [1620980169.033723]: Spawn service failed. Exiting.
Now I solve this problem as following:
I guess that the .utrf
file has no read-write
permission, which makes it impossible to modify the content of the.utrf
file. That is, the generated content is not writed into the .urtf
file. Hence I use this command sudo chmod +w xx.urtf
for appending the write
permission to .urtf
file.
Finally, it is working.
We hope this issue is resolved from the suggestions shared above and are closing out the issue.