Gazebo | Ignition | Community
Ask Your Question

Gazebo 5 (Jade deb) velocity motor issue

asked 2016-01-28 22:01:39 -0500

dcconner gravatar image

updated 2016-01-28 22:03:03 -0500

Ubuntu 14.04 ROS Jade I'm trying to update the a iRobot Create model based on the Turtlebot, which hasn't been updated since Hydro. The plugin was using the setVelocity(0,wheel_speed) command, but the robot wasn't moving. As best I can tell this was broken when Coulomb friction added.

The standard answer from similar tickets (see question 8371) seems to be to now use:

joint_steering_->SetParam ( "vel", 0, applied_steering_speed );

as shown in

When I try this (and the "fmax"), I get

[Wrn] [] The 'vel' parameter is deprecated to enable Coulomb joint friction with the 'friction' parameter
[Wrn] [] The 'fmax' parameter is deprecated to enable Coulomb joint friction with the 'friction' parameter
[Err] [] SetParam(fmax) boost any_cast error:boost::bad_any_cast: failed conversion using boost::any_cast

And the wheels still do not turn. A rostopic echo shows the joint velocity of ~8 rad/s, but the joint position is not moving (it vibrates with joint position moving in 4th decimal place)

Any pointers appreciated.

edit retag flag offensive close merge delete



I found this link , which says to remove setMaxForce, but still used setVelocity. This got the wheels spinning, but not behaving properly.

dcconner gravatar imagedcconner ( 2016-01-28 22:34:21 -0500 )edit

Fixed my movement issue by fixing the mu parameters to 100000, and large Kp,Kd which relate to contact forces and damping of body, and not any sort of controller. I removed the setMaxForce as suggested above. I suspect the mu = 1.0 from original model was causing penetration of ground plane and locking the wheels. Apparently SetVelocity still works as before inspite of other comments. Leaving this open due to issues with inconsistencies found during my debugging of other issue.

dcconner gravatar imagedcconner ( 2016-02-02 16:22:36 -0500 )edit

also needed to set step size to 0.001 and update to 1000 to get system to run properlyl

dcconner gravatar imagedcconner ( 2016-02-02 16:54:22 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2016-12-19 21:49:28 -0500

dcconner gravatar image

Looking back at my code; it seems that I fixed this by modifying parameters as above comment and then modifying my custom gazebo_ros_create.cpp plugin to change joints_[LEFT]->SetMaxForce(0, torque_) to joints_[LEFT]->SetEffortLimit(0, torque_)

RIGHT similarly

edit flag offensive delete link more

Question Tools



Asked: 2016-01-28 22:01:39 -0500

Seen: 943 times

Last updated: Dec 19 '16