ROS2 Node or os call #340
Replies: 3 comments
-
Here is my question updated for more clarity : I have an action goal to drive calling a node like this :
I want to stop the current action if a bump is detected (reflexes are enabled) and I added this hazard subsricption in the drivedistance node :
My issue is the drive action is not stopped when a bump happens. The robot is only driving/bump/reflex/drive/bump... indefinitely. |
Beta Was this translation helpful? Give feedback.
-
Hi @azbitak-invn; You can create as many nodes as you want in a single application or you can have multiple applications running at the same time each with one single node. What do you mean by "sacading" ? |
Beta Was this translation helpful? Give feedback.
-
Hi @alsora , `class DriveDistanceActionClient(Node):
` |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I m running ROS2 in Raspberry using python. I can drive the robot and getting bump events, but I would like to know the best approach.
I want to drive the robot and when bumps occur doing a rotation and continue my drives.
Should I use
os.system('ros2 action send_goal...")
approach or it's better to have Nodes ?Also I m wondering how to have several Node working together ?
I used
rclpy.executors.MultiThreadedExecutor()
but whenexecutor.spin_once()
is executed the drive is "sacading".Thanks
Beta Was this translation helpful? Give feedback.
All reactions