# Robot Operating System 2 (ROS2)-Based Frameworks for Increasing Robot Autonomy: A Survey
## 3 General Architecture for Enhancing Cobot Autonomy
### Design and Requirements
Manipulation: This refers to the ways robots physically interact with and modify the environment and objects around them with a wide range of actions such as grasping, packaging, assembling, or cutting, depending on the end-effector attached to the end of the robotic arm. All these actions require an appropriate control of the robot's end-effector. This is a task difficult to generalize because it heavily depends on the specific required manipulation action and on the type of end-effector used to accomplish it. As an example, the same grasping action for a pick-and-place task can be done both with suction cups or with a two-finger gripper. This choice, which should be based on the type of object to be grasped, determines a different tool control interface (e.g., suction/release commands instead of open/close) and a different grasp planning (e.g., suction cups require as contact point a flat facet near the object's center of mass to maintain stability, while a two-finger gripper requires two parallel facets at an appropriate distance). Each of these tasks individually handles a specific problem, but none of them alone can ensure the desired enhanced autonomy achievable only by appropriately interconnecting  
Figure 2: Main tasks for enhancing cobot autonomy. them, for example, as shown in Figure 3, in which task interconnection and consequent grouping into layers is proposed for a fixed-base robot. In Figure 3, the starting layer is a perception layer resulting from the combination of the perception task with the recognition task; the latter, if necessary, interprets the raw data pre-processed (e.g., filtered and/or fused) by the former to extract the information needed for the execution of the other tasks. The planning layer is the core layer of the architecture, responsible for making decisions on how the robot should behave at each level, from the type of action it should perform (the high-level behavior task) to the details of how the action must be executed in terms of motion of both the robot and its end-effector (the low-level planning, re-planning and manipulation tasks) adapting to the current scenario and the surrounding environment. This layer requires the information provided by the perception layer (and specifically by the recognition task) and provides as output a motion plan that must satisfy the robot's physical limitations, the perceived environmental constraints, and some goals that could be either predefined or externally requested or inferred from perception. This is the most complex layer responsible for the logic ensuring the desired higher level of autonomy.To ensure the highest level of autonomy, the behavior task should not be limited to a predefined sequence of actions depending on a fixed required goal, but it should use the perception to decide autonomously both the goal and the best sequence of actions to achieve it. Then, for each scheduled action, the lower-level planning is entrusted to the other three tasks and specifically to the planning and re-planning ones, whose close interaction allows the robot to react to static and/or dynamic obstacles, preventing collisions. Specifically, the planning task is ideally invoked only once to plan a feasible trajectory from the starting pose to the goal position required by the current action, while the re-planning task is executed continuously to monitor potential collisions and, if necessary, takes action to locally modify the trajectory, finally invoking the global planner again if the local re-planning fails. The proposed architecture also includes a manipulation task to emphasize the need for a particular action, such as manipulation. Even if this action could be managed by the other modules, a dedicated task should be allocated for it for its complexity and specificity (e.g., it concerns not only the planning of the robot but also of the end-effector). Further details on this topic, which will not be explored in this paper for the sake of brevity, can be found in [71; 72].