Skip to main content

Questions tagged [multithreading]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
0 answers
10 views

ROS: Further understanding the diffrence of MultiThreadedSpinner and AsyncSpinner

I have several years of experience with robot software development using ROS, especially ROS Noetic. I want to clarify my understanding about ...
Danendra's user avatar
1 vote
0 answers
23 views

rclcpp::AsyncParametersClient inside a timer callback

I am trying to have a parameter client set the parameters of a node in a timer callback.But unfortunately the parameters are not set during the callback the code is as follows. i also tested with a ...
Saksham Kohli's user avatar
0 votes
0 answers
27 views

How do I determine the order of ROS messages in Python

I am using ros-noetic. I am receiving ROS messages and putting them into a python Queue which is FIFO. I suspect but I am not sure that what is happening is the subscriber callbacks are called in a ...
jasonsf's user avatar
  • 49
2 votes
1 answer
110 views

ROS2 data consumer/aggregator pattern

I'm fairly new to ROS2 after having worked with ROS for a number of years. A typical pattern we would often use was to have a ROS node subscribe to a number of inputs, and then combine and process ...
felix_blix's user avatar
0 votes
1 answer
21 views

Multiple subscriber cbs to service handler

I need to covert single incoming messages from a GUI (following the logic publish once) and in the callback invoke a service request to a device. The service request should wait for a response, which ...
JS-FWR's user avatar
  • 13
0 votes
0 answers
42 views

Exector Error while using multithreading

I am currently working on migrating a ROS1 project to ROS2, I am using a multithreaded executor to have concurrent callbacks, I have an error I am unfamiliar with. Does anyone have had this error? if ...
tyraex's user avatar
  • 1
0 votes
0 answers
11 views

Client doesn't revieve response in nested callbacks

I want to create node which provides a action server, this server expects the name of a waypoint and is then able to ask other nodes which calculate the pose of the waypoint for the appropriate ...
NotARobot's user avatar
1 vote
1 answer
34 views

Blocking call on MoveIts CurrentStateMonitor?

I've created my own move_group_interface due to some complications with the original and the need to expose more functionality of ...
NotARobot's user avatar
0 votes
1 answer
103 views

MicroROS and Multithreading - freeRTOS vs Zephyr

I would like to get to know MicroROS. Therefore I worked with one of the recommended boards (Olimex STM32-E407) for the last weeks. And I have a few questions. I really want to know if MicroROS is ...
Johannes's user avatar
0 votes
0 answers
97 views

ROS 2: Controlling Timer Callback Execution Threads

I have a ROS 2 node that manages a simulation instance. I wish to manage timers for stepping physics and rendering camera views of the simulation environment, where callbacks for either functionality ...
Peter David Fagan's user avatar
0 votes
0 answers
48 views

Handling Concurrent Service Calls in ROS 2 Action Server Callback

I'm developing a ROS 2 application and facing challenges with concurrent service calls within an action server callback. My get_all_ras_poses_concurrent function retrieves the current poses of all RAS ...
Zantos's user avatar
  • 1
0 votes
1 answer
589 views

ROS2 multi-threaded executor timers block subscriber callbacks

Using RCLCPP, ROS2-Iron, Ubuntu 22.04. Using rclcpp::executors::MultiThreadedExecutor executor When defining callback groups, if I leave both timers and subscribers ...
Toby Buckley's user avatar
0 votes
2 answers
2k views

ROS2: multi nodes, each on a thread in same process

When looking at the examples it's unclear if ROS2 nodes are thread safe if you want to launch your own threads vs using multithread-executor. For example, suppose I have a process I want to run ...
FourierFlux's user avatar
0 votes
2 answers
174 views

Multiple servers in a single node [ROS2]

I am trying to make two servers for two different services in a single node. For example, like so: ...
Suchetan Saravanan's user avatar
0 votes
0 answers
190 views

Creating node with multiple subscribers working on shared data

I'm working with ROS2. Suppose I have a state estimator taking in multiple data forms at different rates, ex IMU and GPS or something similar. My state estimator will be a single node and this node ...
FourierFlux's user avatar
0 votes
0 answers
28 views

Executor multithread doesnt work

Im having problems to execute tasks from 2 nodes using the multithreadExecutors and the call_back groups. I'm running 1 node with 2 classes: ...
Juan Miguel Sequeira Da Silva's user avatar
0 votes
2 answers
146 views

Associate two executors for a single node

I am running ROS2 Humble Hawksbill, I have a requirement where in I need to associate two executors StaticSingleThreadedExecutors for a lifecycle single node. I ...
RobotBramhana's user avatar
1 vote
1 answer
158 views

Spinning multiple nodes across multiple threads

I have an application which dynamically spins up multiple nodes and needs to spin them (as they have subscribers). Quick example, stolen from here: https://answers.ros.org/question/358343/rate-and-...
user avatar
0 votes
1 answer
9 views

Correct way to interrupt a callback

I will present my problem with an example. I have a callback of Imu messages which I want to integrate on the fly. In a parallel thread I want to access the integrated value from the callback and ...
user avatar
0 votes
1 answer
3 views

[SOLVED] Thread does not terminate

Hello, I've a problem with terminating a node and I hope someone can help. Consider some code like below: ...
user avatar
0 votes
1 answer
5 views

how to execute service while getting subscriber messages

I want to build a service to move to a particular point on a line. The problem is when I receive my service call, the thread is stuck in this callback and so global spinner in another thread does not ...
user avatar
0 votes
2 answers
24 views

Multithreading vs ROS nodes

Hi, My Background: I am currently working on a project involving (Parrot A.R.) drone navigation. I require state estimation and controller module. Assuming the state estimator and controller are ...
user avatar
0 votes
1 answer
5 views

Ros barebones compiled from source for QNX crashes with memory fault

I have successfully cross compiled ROS barebones for QNX to be run on ArmV7. When I attempt to run ros master or rosout the program crashes with a memory fault. Debugging it further reveals that it ...
user avatar
0 votes
1 answer
4 views

Communicate between Android and ROS threads

Hello, I have a simple Java class that launch a thread containing a ROS node ...
user avatar
0 votes
1 answer
52 views

ROS Threading, AsyncSpinners and Control

Hello everybody, I am a relatively new ROS user (but I've spent years working with other middlewares), and up to now I am generally happy about it. I have a doubt related to my software framework I ...
user avatar
0 votes
1 answer
13 views

Confusion about AsyncSpinner

Hi, I am confused about the behavior of AsyncSpinner. My understanding is that AsyncSpinner would allow a node to process ...
user avatar
0 votes
1 answer
8 views

Callback function and Threading

Hello everyone, I am having a callback function which is supposed to receive the data and to assign it to a local variable. Until here, everything is fine. However, after the assignment, when I want ...
user avatar
0 votes
2 answers
7 views

How to make call to multiple services in parallel?

I have 4 services which have are completely independent of each other. I want to call them in parallel from another ros node. But the all service call end consuming the time that they would use in ...
user avatar
0 votes
2 answers
23 views

starting multiple instances of same callback in MultiThreadedSpinner

My end goal is to have a callback receive a message and until the next message is received to run a few lines of code in an infinite loop. My initial thought was to create a ...
user avatar
0 votes
2 answers
1 view

Creating continous tf broadcaster with Boost::Thread

This is a bit of a continuation from a previous question here:here. Basically, I want to create a class that allows me to continuously publish frames to tf. I have no experience at all in ...
user avatar
0 votes
1 answer
13 views

how are threads used to service callbacks in nodelets?

I have several nodelets, each subscribes to different messages (using the single threaded node handle). However, I realized one of my nodes, which subscribes to images and to odometry messages, and ...
user avatar
0 votes
1 answer
36 views

Issue with multithreading and standard output

I have a multithreaded piece of python code that moves the arms of my robot. The basic premise is that there is one thread for each arm, and threads block until each arm as finished it's movements (i....
user avatar
0 votes
1 answer
66 views

Multi-threading in ROS nodes and MultiThreadedSpinner and AsyncSpinner

To put it simply: What is the application of multithreading in ros nodes? I am not from a Computer Science background. I have been learning Operating System concepts like processes, threads, signals, ...
user avatar
0 votes
1 answer
72 views

rospy and Tkinter - spin() and mainloop()

I want to write a rospy node that uses Python's GUI toolkit Tkinter, problem is that rospy.spin() and top.mainloop() are both blocking calls. I thought of starting one and setting an interrupt to ...
user avatar
1 vote
1 answer
50 views

Multi threading

Hi, I am trying to understand different options to use multi threading with ROS. I found different things : Use MT nodelet interface (with getMTNodeHandle()) Use MultiThreadedSpinner or AsyncSpinner ...
user avatar
0 votes
1 answer
79 views

How do I get out of ros::spin() in another thread?

Hi All, So what I am doing is enumerated in the points below. After that, I explain my questions in detail. I recently got my hands on an ATI force/torque sensor which is pretty cool. I already had ...
user avatar
0 votes
2 answers
62 views

Suggest good example of multi-threading with ROS?

Can some someone point me to a good example of multi-threading using ROS? I would like to move calculations outside the main ROS callbackQueue, and then publish a topic after the calculations are done....
user avatar
0 votes
1 answer
13 views

while loop lock subcribing

Hi everybody,I'm part of an international project team working on robot using ROS. We are stuck with a problem about multithreading. The code below never exit the loop because of the _current_angle is ...
user avatar