Function rclc_executor_add_action_server

Function Documentation

rcl_ret_t rclc_executor_add_action_server(rclc_executor_t *executor, rclc_action_server_t *action_server, size_t handles_number, void *ros_goal_request, size_t ros_goal_request_size, rclc_action_server_handle_goal_callback_t goal_callback, rclc_action_server_handle_cancel_callback_t cancel_callback, void *context)

Adds a action server to an executor.

Attribute

Adherence

Allocates Memory

No

Thread-Safe

No

Uses Atomics

No

Lock-Free

Yes

Parameters:
  • executor[inout] pointer to initialized executor

  • action_server[in] pointer to a allocated and initialized action server

  • handles_number[in] max number of goals to handle with the server

  • ros_goal_request[in] type-erased ptr to an allocated ROS goal request message

  • ros_goal_request_size[in] size of the ROS goal request message type

  • goal_callback[in] function pointer to a goal request callback

  • cancel_callback[in] function pointer to a cancel request callback

  • context[in] context to pass to the callback functions

Returns:

RCL_RET_OK if add-operation was successful

Returns:

RCL_RET_INVALID_ARGUMENT if any parameter is a null pointer

Returns:

RCL_RET_ERROR if any other error occured