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

Revision history [back]

While I think that combining gazebo and real sensors and actuators should definitely be possible, I'm not sure if it would really help, in particular in the example you gave us.

The IMU sensor and odometry are not independent from each other, i.e. whenever the robot moves, the odometry will be updated but the IMU will also generate data based on that exact movement. In other words, you needed to move the IMU sensor the same way the robot moves in simulation and they need to be absolutely synchronized.

Time synchronization and too slow or too fast simulation might cause other problems. For instance, you need to make sure that your sensors use sim time, not wall time. Otherwise time stamps would never fit.

While I think that combining gazebo and real sensors and actuators should definitely be possible, I'm not sure if it would really help, in particular in the example you gave us.

The IMU sensor and odometry are not independent from each other, i.e. whenever the robot moves, the odometry will be updated but the IMU will also generate data based on that exact movement. In other words, you needed to move the IMU sensor the same way the robot moves in simulation and they need to be absolutely synchronized.

Time synchronization and too slow or too fast simulation might cause other problems. For instance, you need to make sure that your sensors use sim time, not wall time. Otherwise time stamps would never fit.

Edit Thanks for the more detailed explanation, Dejan. I think though that you might run into synchronization problems (simulation might run slower than reality). You need to make sure that the pose of the real robot is aligned with the simulated robot. Not sure how hard that is. But maybe you can use another method for absolutely localizing the robot, e.g. GPS or markers. But then the question would be, what do you do if the two versions of the robot drift apart? Another concern would be the realism of the simulation. In particular friction models might not be modeled perfectly in game engines such as ODE or Bullet (to be tested tough). Tuning the parameters right could help but could be quite some effort.