ros2-realtime-demo / pendulum

ROS, ROS2, real-time, control, pendulum
Apache License 2.0
132 stars 38 forks source link

Process dies when using lifecycle transitions #47

Closed carlossvg closed 4 years ago

carlossvg commented 4 years ago

Describe the bug

When the nodes are transitioned using the command line lifecycle utils the process dies unexpectedly. This doesn't happen when the nodes are transitioned automatically using autostart.

The issues seem to be related to an incompatible QoS generated by the deadline QoS usage. If this QoS is removed, it works as expected.

To Reproduce

Terminal 1:

ros2 launch pendulum_bringup pendulum_bringup.launch.py autostart:=False

Terminal 2:

ros2 lifecycle set /pendulum_controller configure

Terminal 1:

[ERROR] [pendulum_demo-1]: process has died [pid 182186, exit code -11, cmd '/home/odin/adehome/pendulum_ws/install/pendulum_demo/lib/pendulum_demo/pendulum_demo --autostart False --priority 0 --cpu-affinity 0 --lock-memory False --lock-memory-size 0 --config-child-threads False --ros-args --params-file /home/odin/adehome/pendulum_ws/install/pendulum_bringup/share/pendulum_bringup/params/pendulum.param.yaml'].

Expected behavior

It is possible to use ros2 lifecycle to activate the nodes successfully.

Desktop (please complete the following information):

Additional context Add any other context about the problem here.

LanderU commented 4 years ago

Solved via: https://github.com/ros2-realtime-demo/pendulum/pull/48