Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0 votes
0 answers
25 views

Issues with asynchronously handling a Subscriber callback

I am trying to create a listener that sends a message through a Discord webhook to my Discord server. The issue that I am encountering at the moment is that I do not know how to create an asynchronous ...
Pogo's user avatar
  • 1
0 votes
1 answer
491 views

Wait for subscriber callback to receive message - best practice

Hello, I am wondering what is the best practice in python to wait for a subscribed topic to start publishing, before using its messages in the spin method. An simplified example of what I am doing ...
user avatar
0 votes
2 answers
23 views

publish after processing data from 2 synced subscribers (rospy)

I want to make one node to subscribe 2 topics synchronously, process those data, and publish it. I know that publishing and subscribing data with single node is possible, but have never seen any ...
user avatar
0 votes
1 answer
4 views

subscriber callback in a python class is overwriting the class variables with the most recent data before the first callback processing finishes

I am on ROS Melodic. When a subscriber is receiving data at a faster rate than it could process, the class variables are being updated before the callback process is finished. For example, when I run ...
user avatar
2 votes
3 answers
112 views

message_filters doesn't call the callback function

I'm trying to use the message_filters in order to subscribe to two topics. Here's my code ...
user avatar
0 votes
1 answer
42 views

How to set callback queue size in rospy

Hello, I'm currently working on a project where I use a network written in TensorFlow to segment some point clouds. I have created a node which subscribes to the point cloud topic. The callback ...
user avatar
0 votes
1 answer
4 views

callback models for roscpp and rospy

For example, I have a ROS node that has several callback and timers. Those callbacks and timers need to read or modify the same global variable. Should I use mutex or other locking mechanism to ...
user avatar
0 votes
1 answer
9 views

Subscribers not making callbacks

I have a listener function that subscribes to two topics as shown below, but the callbacks (which I confirmed are updating) don't seem to update some variables in the listener. I confirm that the ...
user avatar
0 votes
1 answer
5 views

How to execute subscriber callback on some condition?

Hi all, I am working on a small project in Python and ROS Indigo. To implement a small functionality, I have created a node in which the node has a subscriber (queue size 10) and corresponding ...
user avatar
0 votes
1 answer
9 views

subscriber cannot receive topic on rospy

I made a node which has 1 action client, 5 subscribers and 1 publisher. I wrote its pseudo code is following. When I tried a certain sequence, one of the subscribers sub1 did not call its callback cb1 ...
user avatar
0 votes
1 answer
29 views

How does rospy.Timer behave if it triggers while the previous callback is still busy?

I'm using a rospy.Timer (periodic, not one-shot) to handle a long-running process in a non-blocking way. I only want one instance of the process to be running at ...
user avatar
0 votes
1 answer
6 views

Callback function not updating values (Rospy)

I have a program used to read in command velocities from two sources (teleop/navigation), blend them, and then publish the blended velocity to the Turtlebot. While debugging, I noticed that the code ...
user avatar
1 vote
2 answers
63 views

Passing arguments to callback in Python

Hi! I have a problem passing arguments to a callback function when Subscribing a ROStopic. The code below is what I do have now. But I only received error messages when I tried to pass arguments to ...
user avatar
0 votes
1 answer
29 views

PyQt Signals for ROS callbacks in RQT Plugin

Hi everyone, while writing a RQT plugin I had a hard time to figure out, how to connect a rospy callback to a PyQt SLOT in order to update the UI in a correct way. The ROS WIKI only tells you, that ...
user avatar
0 votes
1 answer
7 views

How to use variable's value (subscriber function) in another function

Hello all ! I want to pass the variable which is set to its value when called the callback function. and then want to use the value of the variable in another function. ...
user avatar
0 votes
1 answer
2 views

Collect messages

I need to collect messages from a topic, that is, subscribe to a topic, and then do something with some condition about the message is met (a flag on the message) with all the messages recibed ...
user avatar
0 votes
2 answers
29 views

[rospy] How do you unsubscribe to a topic, from within the callback?

In a previous answer a similar issue was addressed but solved in another manner, however the solution suggsted: ...
user avatar