zmk5 / jupyter-ros2

Jupyter widget helpers for ros2, the Next-Generation of the Robot Operating System
28 stars 8 forks source link

Subscribers require the use of spin_once() #2

Open zmk5 opened 4 years ago

zmk5 commented 4 years ago

Compared to the original, ros2 requires the use of either a class rclpy.timer or for the node to be used with rclpy.spin_once() to even display the callback. A temporary solution requires a thread to keep spinning every tenth of a second to achieve a successful callback.