Closed adeschamps closed 3 weeks ago
I added commit 04195f3 which stops the publish loop when the mouse button is released. This takes care of a problem that I experienced where another process, such as a navigation stack, and the mouse_teleop node were fighting for control of the robot even when I wasn't trying to manually control the robot.
Just comment. I've faced the same issue and this PR completely fix my problem. Thank you.
The ROS
create_timer
call never actually gets driven, because the main loop is blocked onself._root.mainloop()
at the end ofMouseTeleop.__init__
. This commit uses a Tkinterafter
call instead and lets the Tkinter invoke the publish function.Technically this will publish messages slightly less often than requested, because the function will be called every
period + execution_time
, but for a tool like this I think keeping the code simpler is more valuable.