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

Default callback group?

asked 2020-12-09 18:53:59 -0600

galaxee gravatar image

http://docs.ros2.org/latest/api/rclpy... I saw in the definition for action clients that if no callback group was defined that the node's default callback group is used. How can I find what this is?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2020-12-11 15:22:27 -0600

clalancette gravatar image

The default callback group is just an internal, MutuallyExclusive callback group. That means that one, and only one of the callbacks within the group can run simultaneously. This is the safest configuration to run in, though it may not be the highest performance.

To directly answer your question, I don't think we have a way to access the default callback group. What are you trying to do that you need it?

edit flag offensive delete link more

Comments

Thanks! I don't need to access the default callback group, I just didn't know where to look to see what the default callback group was.

Just to make sure I understand, does this mean that if for one node, you use a MultiThreadedExecutor but a MutuallyExclusiveCallbackGroup, it's not different from using a SingleThreadedExecutor?

galaxee gravatar image galaxee  ( 2020-12-11 15:30:44 -0600 )edit

Ah, no worries. I had to go grubbing through the source to find it, but it is created here: https://github.com/ros2/rclcpp/blob/9...

clalancette gravatar image clalancette  ( 2020-12-11 15:38:38 -0600 )edit

Thanks! Sorry I edited my comment but not sure if you saw the edit. Does this mean that if for one node, you use a MultiThreadedExecutor but a MutuallyExclusiveCallbackGroup, it's not different from using a SingleThreadedExecutor?

galaxee gravatar image galaxee  ( 2020-12-11 15:45:15 -0600 )edit

Question Tools

3 followers

Stats

Asked: 2020-12-09 18:53:59 -0600

Seen: 2,779 times

Last updated: Dec 11 '20