How to know if robot has moved one meter using odometry
I'm working with ROS Melodic and Gazebo 9.9.0 on Ubuntu 18.04.2 LTS.
I'm developing a node with C++ and I want to move the robot one meter. If I use odometry, and the message nav_msgs/Odometry:
How can I know if the robot has moved one meter?
I'm doing an automatic controller that "order" the robot to move (on X axis or Y axis), and then stop it when the robot has moved one meter.