ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Fast glance: I think that the issue is that your ros::ServiceServer service
goes out of scope as soon as the imu_callback
exits and the service server is then destroyed.
2 | No.2 Revision |
Fast glance: I think that the issue is that your ros::ServiceServer service
goes out of scope as soon as the imu_callback
exits and the service server is then destroyed.destroyed. Note, there are likely better structures for this program, but I think if you declared service
globally, and then defined it once you've received enough messages inside of the imu_callback
, then I think this would work.