(How) can a rospy node be reinitialized after ctrl+c?
TL:DR Is there a correct way to use rospy in the interactive shell? Seems stuck in shutdown after ctrl+c
Since interacting with ros from python is much more powerful than interacting via the command line interface, I've been attempting to use the interactive python shell to do many of the things I might otherwise do at the command line, like echoing and filtering messages.
The problem is that once I hit ctrl+c
to SIGINT
rospy.spin()
, from then on out rospy.spin()
is useless as it is in shutdown state. I've tried re-calling rospy.init_node
again, but that fails to solve the problem.
So, is there a correct way to use rospy in the interactive shell?
Is there a way to kick rospy out of the shutdown state?