Info

This question is locked. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

Simulink ROS2 subscriber transport stopped

13 Ansichten (letzte 30 Tage)
Renzo
Renzo am 27 Okt. 2022
Locked: Jagadeesh Konakalla am 10 Jun. 2024
Hello,
I am trying to subscribe to a ros2 topic, but I get the following error:
STD exception 'mwboost::wrapexcept<std::runtime_error>': 'Transport stopped.' was caught.
My Simulink model is the same as the example given in the tutorial, except I changed the subscriber topic to /controller_output to match my code.Inside the subsystem block at the bottom of my screenshot, I changed the bus assignment from the tutorial from x,y to torque, delta according to my message definition.
In my Linux terminal, I can see the messages being posted by using ros2 topic echo /controller_output
ROS2 subscriber block with sample time 0.01, topic /controller_output, message /custom_msgs/ControllerCommand
QoS: Reliable and Volatile
My setup:
Ubuntu 20.04
Matlab R2022b
ROS2 Humble
My message definition in ControllerCommand.msg
float64 torque
float64 delta
  1 Kommentar
Prabeen Sahu
Prabeen Sahu am 27 Okt. 2022
Bearbeitet: Prabeen Sahu am 27 Okt. 2022
Hello Renzo,
Please restart the model and see if the issue still exists.
I need some more information to help you on this issue.
  • Does the original example work fine in your PC ?
  • Do you see this issue only with custom_msgs/ControllerCommand message or with other standard messages also ? Instead of custom_msgs/ControllerCommand please publish standard messages(geometry_msgs/Point) from "Ubuntu 20.04 ROS2 Humble" to a different topic(/location1). Please change the subscriber topic to /location1 and change the bus assignment to x,y in the Simulink model. Please run the model with these changes and check if this works.
  • Please also attach the support file generated by the command ros.internal.generateSupportFile
- Prabeen

Antworten (0)

This question is locked.

Produkte


Version

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by