ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
This same stinking issue comes up over here every few months. Our current solution, which I think is the final one, is to disregard whatever the PR2 URDF file says. We get correct robot rotation in Rviz when we do the following:
The confusion appears to stem from the 3DM-GX2's left-handed coordinate system (their Z-axis points down and Y points to the right, instead of up and left, respectively), and the way the IMU is mounted in the PR2.
So to answer your question - if the PR2's IMU is pitched by 180 degrees (that's what's in the URDF), then I'm guessing their IMU is mounted with the label facing up and the cable facing 'backwards' (towards the back of the robot).
2 | No.2 Revision |
This same stinking issue comes up over here every few months. Our current solution, which I think is the final one, is to disregard whatever the PR2 URDF file says. We verified that we get correct robot rotation in Rviz when we do the following:
Hopefully this helps someone else looking for the same problem. The confusion appears to stem from the 3DM-GX2's left-handed coordinate system (their Z-axis points down and Y points to the right, instead of up and left, respectively), and the way the IMU is mounted in the PR2.
So to answer your question - if the PR2's IMU is pitched by 180 degrees (that's what's in the URDF), then I'm guessing their IMU is mounted with the label facing up and the cable facing 'backwards' (towards the back of the robot).
3 | No.3 Revision |
Update: my coworker and I learned that this solution is incomplete. While the rotations in RViz are correct, the yaw values are off by 180 degrees (i.e. the robot will point South when the IMU points North). This can be fixed with an addition of 180 degrees to wherever you use the IMU values, but I consider that to be hacky. Just FYI.
This same stinking issue comes up over here every few months. Our current solution, which I think is the final one, is to disregard whatever the PR2 URDF file says. We verified that we get correct robot rotation in Rviz when we do the following:
Hopefully this helps someone else looking for the same problem. The confusion appears to stem from the 3DM-GX2's left-handed coordinate system (their Z-axis points down and Y points to the right, instead of up and left, respectively), and the way the IMU is mounted in the PR2.
So to answer your question - if the PR2's IMU is pitched by 180 degrees (that's what's in the URDF), then I'm guessing their IMU is mounted with the label facing up and the cable facing 'backwards' (towards the back of the robot).