-
Notifications
You must be signed in to change notification settings - Fork 119
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Communication between nodes fails for non small-sized images ros2 topics #570
Comments
@iqedgarmg In order to reproduce your issue, it would be nice to have a minimal reproducer with the code you are running, as long as the QoS settings. |
Hi @MiguelCompany, thanks a lot for your quick response!. In this drive, you can download the publisher/subscriber node that I developed using OpenCV: https://drive.google.com/drive/folders/1p4GziL_vGGfIfFkao0-Z-lpc-YTRcodE?usp=sharing This package has two nodes: a) Publisher Publisher generates two topics:
b) Subscriber If everything works fine, you should visualize an OpenCV window with the received image topic. This is the configuration that I run on both machines to achieve ros2 connection: 1.- Change ROS middleware to fastrtps
2.- Call a discovery server (machine that has the publisher)
3.- Setup a global discovery server (IP of the machine that has the publisher)
4.- Set FastRTPS profile
with this configuration file:
In my case, the subscriber works fine if the image resolution is less than 100x100 pixels (as well as for any topic of small size), but didn't work for larger image resolutions (publisher continues working, but subscriber callback not work). Please let me know if you require further information. Thanks again for your help! |
Hi @MiguelCompany, I finally found the way to make the subscriber working. I write the solution if this is useful for someone: 1.- Set QoS on Python publisher
2.- Setup SYNCHRONOUS mode
By developing the previous modifications (and following the instructions described in my previous response), now the publisher and subscriber are working using the original image size at 12 Hz. |
Hi everyone!
I make a basic python camera publisher/subscriber using ros2 galatic on a pair of Windows 10 machines located on the same local network. I change the middleware layer on both machines to fast-rtps using this tutorial:
https://fast-dds.docs.eprosima.com/en/latest/fastdds/ros2/discovery_server/ros2_discovery_server.html
and this .xml file:
Once configured, I can publish/subscribe topics between both machines using small-size data topics. Nevertheless, when I try to subscribe to the camera topic generated by my node, the callback did not work on the subscriber node.
Curiously, if I resize the published image to a small resolution (100x100 pixels) everything works fine. So, I think that this is a problem related to the topic data size.
I tried with some of the solutions mentioned in this issue:
#460
Nevertheless still at the moment I can't subscribe to the camera topic if the image is greater than 100x100 pixels.
Thanks in advance for your help!
Bug report
Required Info:
Steps to reproduce issue
https://docs.ros.org/en/galactic/Installation/Windows-Install-Binary.html
https://fast-dds.docs.eprosima.com/en/latest/fastdds/ros2/discovery_server/ros2_discovery_server.html
Expected behavior
Actual behavior
Additional information
The text was updated successfully, but these errors were encountered: