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

Odometry error and, maximum and minimum speed

asked 2012-03-22 04:51:15 -0600

q2p0 gravatar image

updated 2012-03-24 03:06:31 -0600

Kevin gravatar image

Hi.

First I apologize for my limited English proficiency. I am programming a simple robot, using Stage to simulate the real world.

First question ( 4 questions to ask the same ):

  • How I can define an error for the data returned by the odometer? (Specifically for the current angle in the Z axis msg-> pose.pose.orientation.z);
  • Can it be defined in the .cfg file that is passed to Stage?
  • Where?
  • and Name?

Second question:

  • Where I can define the maximum and minimum speed of my robot? (Lineal and angular).

Thank you very much.

edit retag flag offensive close merge delete

Comments

Ok, question 1 is so much stupid because i can make a function that insert a random error whit the ranges i whant. XD

I make a new (offtopic?) question similar to question 2. Where I can define the error that make my robot when I publish a rotation angular velocity in the final rotation that i get.

q2p0 gravatar image q2p0  ( 2012-03-23 00:05:35 -0600 )edit

@q2p0 Please ask single questions at a time so that answers can be isolated and marked as accepted.

tfoote gravatar image tfoote  ( 2012-03-26 16:46:04 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-09-18 08:47:16 -0600

jackcviers gravatar image

Question number one has a few answers:

If your measurement error is constant, you can define it using the ros paramater server in your launchfile for your robot. Then read the error paramater from the parameter server and insert it into the orientation covariance matrix in a geometry_msgs/PoseWithCovariance. You probably want to include that message as part of a nav_msgs/Odometry message.

In the following example, the parameter z_rotation_covariance is defined in the launchfile:

<launch>
  <param name="z_rotation_covariance" value="0.05" />
</launch>

To use the parameter value in code, you'll want to use the rosparam api for your client.

If your error is a calculated or accumulated error, you will want to set up a service to calculate the changes as a function on some input and store the error in rosbag and another service to retrieve the error from rosbag whenever you need to use it in the orientation covariance matrix in a geometry_msgs/PoseWithCovariance. You probably want to include that message as part of a nav_msgs/Odometry message.

You will need to subscribe to whatever topics are publishing the parameters of your error estimation function, probably using a message_filter to combine the messages of several different topics into a single callback. ApproximateTimeSynchronizer is a good filter for doing this. Then when your filter callback is called, call your error calculation/accumulation service to calculate and store your error, then you can retrieve it from rosbag at any time using your error retrieval service.

Question number two is simpler:

You will want to model your robot using urdf. URDF joint tags allow you to specify joint upper and lower limits, efforts, types, etc. You might look into using Gazebo instead of Stage. It allows you to add several additional tags to your urdf to model the physics properties of your robot during simulation.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2012-03-22 04:51:15 -0600

Seen: 994 times

Last updated: Sep 18 '14