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

Revision history [back]

click to hide/show revision 1
initial version

Usually you want your call back to be a simple setting of variables. I would recommend that instead you just set the variables in the call back. Then in your main function you could call the service if the data from the subscriber has changed . However in theory what you want to do should work. I would be curious to see you implement both and see the timing differences.