ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

/cmd_vel republished as TwistWithCovarianceStamped

asked 2019-12-04 07:25:13 -0600

wintermute gravatar image

Hello, I am experimenting with robot_localization package, and I understand /cmd_vel has to be TwisthWithCovarianceStamped.

How can I read /cmd_vel and republish it as TwistWithCovarianceStamped?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2019-12-04 11:14:59 -0600

This use control ( feature takes a Twist.

You should use that, not using cmd_vel as a state estimation input. No changes required :-)

edit flag offensive delete link more


the documentation states it is a twist, but

/ekf_se is almost certainly wants to listen TwistWithCovarianceStamped

wintermute gravatar image wintermute  ( 2019-12-10 07:22:45 -0600 )edit

What are you trying to publish to exactly? Whats your config file? The cmd vel should be in the control input NOT a twist source.

I assure you that it takes a normal twist.

stevemacenski gravatar image stevemacenski  ( 2019-12-10 11:50:14 -0600 )edit

If the config file has these statements below, it will try to resubscribe to /cmd_vel as twist with pose:

twist0: cmd_vel

twist0_config: [true, false, false,

false, false, true] ...

twist0_queue_size: 3

twist0_rejection_threshold: 2

twist0_nodelay: false

when use control is true, and stamped control is false, ekf-se subscribes to /cmd_vel no problem and uses it.

since I deleted the twist0 .. statements from config file, problem has gone away.


wintermute gravatar image wintermute  ( 2019-12-10 16:31:59 -0600 )edit

Yes, you shouldn't have twist0 for cmd_vel, the use control will take care of all of this for you.

If your problem is resolved, can you hit the checkbox by my answer so its removed from the unanswered queue?

stevemacenski gravatar image stevemacenski  ( 2019-12-10 17:43:03 -0600 )edit

Question Tools



Asked: 2019-12-04 07:25:13 -0600

Seen: 156 times

Last updated: Dec 04 '19