Hello,
Is there a recommended way to control logic in ROS when I want to do something in sequential order? I am using ROS2 on Ubuntu 20.04. Previously (without using ROS), I have written discrete controllers where I keep track of the state of my program and execute the appropriate commands in loops.
As an example, let's say I have a robot arm with a gripper and a camera. I want to do the following tasks in this order and only move on to the next task when the previous has finished 1) Close the gripper 2) Move the robot arm to a position (IK) 3) Run object detection routine with the camera.
I am pretty sure I can "hack" together a way to perform this routine with topics that act as flags that tell me when a task has finished but is there a better (more scalable) way that you recommend?
Thanks
Originally posted by nickd on ROS Answers with karma: 92 on 2022-05-09
Post score: 1