Ask Your Question
0

/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
1

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

This use control (http://docs.ros.org/melodic/api/robot...) 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

Comments

the documentation states it is a twist, but

/ekf_se is almost certainly wants to listen TwistWithCovarianceStamped

wintermute gravatar imagewintermute ( 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. https://github.com/cra-ros-pkg/robot_...

stevemacenski gravatar imagestevemacenski ( 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.

best

wintermute gravatar imagewintermute ( 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 imagestevemacenski ( 2019-12-10 17:43:03 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

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

Seen: 16 times

Last updated: Dec 04