Robot links collapse into origin [closed]
I'm using ubuntu 16.04 on a Huawei Matebook-x, with kernel 4.15.0-91-generic. ROS distro: kinetic and version 1.12.14. Gazebo 7.
My package for the robot is at https://github.com/yiyinglai/FetchIt_....
I have seen answers and videos about similar problem, and I did what's suggested for the inertia calculation for niryo_gripper.urdf.xacro using the following script.
def inertia(m, x, y, z):
"""Solid cuboid of height h, width w, and length l, and mass m."""
Ixx = m * (y**2 + z**2) / 12
Iyy = m * (x**2 + z**2) / 12
Izz = m * (x**2 + y**2) / 12
tag = '<inertia ixx="{}" ixy="0.0" ixz="0.0" iyy="{}" iyz="0.0" izz="{}"/>'.format(Ixx, Iyy, Izz)
return tag
if __name__ == '__main__':
# mainsupport mass bounding box x, y, z
print('mainsupport')
print(inertia(0.01306, 0.0446, 0.0511, 0.044))
print('left gear')
print(inertia(0.0043, 0.022038, 0.049874, 0.01155))
print('right gear')
print(inertia(0.00375, 0.02207, 0.049804, 0.008))
print('rod')
print(inertia(0.00214, 0.012501, 0.041893, 0.016))
print('clamp')
print(inertia(0.00662, 0.027452, 0.06758, 0.016))
print('motor')
print(inertia(0.01658, 0.036, 0.024, 0.027))
When I launch gazebo simulation, I get a quite normal output on console:
... logging to /home/yiying/.ros/log/881f6094-6f12-11ea-b6cd-7c11cb4ab0c1/roslaunch-matebook-x-3897.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://matebook-x:44093/
SUMMARY
========
PARAMETERS
* /robot_description: <?xml version="1....
* /rosdistro: kinetic
* /rosversion: 1.12.14
* /use_sim_time: True
NODES
/
gazebo (gazebo_ros/gzserver)
gazebo_gui (gazebo_ros/gzclient)
spawn_urdf (gazebo_ros/spawn_model)
auto-starting new master
process[master]: started with pid [3922]
ROS_MASTER_URI=http://localhost:11311
setting /run_id to 881f6094-6f12-11ea-b6cd-7c11cb4ab0c1
process[rosout-1]: started with pid [3935]
started core service [/rosout]
process[gazebo-2]: started with pid [3939]
process[gazebo_gui-3]: started with pid [3964]
process[spawn_urdf-4]: started with pid [4005]
Gazebo multi-robot simulator, version 7.0.0
Copyright (C) 2012-2016 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
Gazebo multi-robot simulator, version 7.0.0
Copyright (C) 2012-2016 Open Source Robotics Foundation.
Released under the Apache 2 License.
http://gazebosim.org
[ INFO] [1585193598.698783796]: Finished loading Gazebo ROS API Plugin.
[Msg] Waiting for master.
[ INFO] [1585193598.700128591]: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 192.168.2.31
[ INFO] [1585193598.751193527]: Finished loading Gazebo ROS API Plugin.
[ INFO] [1585193598.751826873]: waitForService: Service [/gazebo/set_physics_properties] has not been advertised, waiting...
[Msg] Waiting for master.
[Msg] Connected to gazebo master @ http://127.0.0.1:11345
[Msg] Publicized address: 192.168.2.31
SpawnModel script started
[INFO] [1585193598.978037, 0.000000]: Loading model XML from ros parameter
[INFO] [1585193598.981118, 0.000000]: Waiting for service /gazebo/spawn_urdf_model
[ INFO] [1585193599.212867836, 0.022000000]: waitForService: Service [/gazebo/set_physics_properties] is now available.
[ INFO] [1585193599 ...
I would suggest you ask this question on
answers.gazebosim.org
instead, as it seems a Gazebo issue right now.