4am-robotics / cob_common

The cob_common stack hosts common packages that are used within the Care-O-bot repository. E.g. utility packages or common message and service definitions etc. Also the urdf desciption of the robot is located in this stack.
https://mojin-robotics.de/
Apache License 2.0
66 stars 136 forks source link

[cob_drive_wheel] fix physics for gazebo - base drifting #265

Closed fmessmer closed 5 years ago

fmessmer commented 5 years ago

as mentioned and observed by @ipa-pfs both cob and raw are spinning when simulated in gazebo although no command is sent, i.e .they start spinning right after being spawned

this seems to be a physics (inertia, friction) problem of the base, most likely the drive_wheel model, as it can be observed that:

fmessmer commented 5 years ago

this https://github.com/ipa320/cob_control/issues/187#issuecomment-462286083 seems to be related @bvanelli FYI

fmessmer commented 5 years ago

see https://github.com/ipa320/cob_simulation/issues/165 @bvanelli @ipa-pfs FYI

fmessmer commented 5 years ago

I think the problem was a missing query for physics_type in the initSim function, which is used in https://github.com/ros-simulation/gazebo_ros_pkgs/blob/kinetic-devel/gazebo_ros_control/src/default_robot_hw_sim.cpp#L359-L372

this is fixed in https://github.com/ipa320/cob_gazebo_plugins/pull/38/commits/72fbd71580eea86d5afc243d3f647779c48c741c

please re-open in case you are still facing this problem