Ask Your Question
0

How to move a differential drive robot to target Co-ordinates?

asked 2016-11-02 15:30:09 -0500

Kishore Kumar gravatar image

I want to move a differential drive robot to a target co-ordinate(X = 50, Y = -50 ) from home position (X=0, Y=0) and return back to home position. The max distance the robot has to move is 20 meters.

I don't want to complicate it using navigation stack because it is very simple application. How to accomplish this in ROS using odometry feedback.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-11-03 10:38:12 -0500

lucasw gravatar image

Every update step you could find the transform of the target frame in your robot vehicle frame, and then extract the x linear distance to the target, and the yaw rotation (see http://answers.ros.org/question/24699... for a recent example), and give your differential drive a linear x command proportional to the x distance and an angular z command proportional to the yaw. Ideally your differential drive accepts a cmd_vel Twist message and that linear x and angular z go straight into it.

edit flag offensive delete link more

Comments

1

If your drive doesn't take Twist messages but rather individual wheel values, you can use the code from my cmd_vel linear and angular relationship post.

kramer gravatar imagekramer ( 2016-11-04 07:38:37 -0500 )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

1 follower

Stats

Asked: 2016-11-02 15:30:09 -0500

Seen: 382 times

Last updated: Nov 03 '16