UTNuclearRoboticsPublic / jog_arm

A real-time robot arm jogger.
45 stars 22 forks source link

Sleeps in jog_arm_server #5

Closed martinappo closed 6 years ago

martinappo commented 6 years ago

In the jog_arm_server code there are several sleeps in different loops. I have few questions and/or suggestions concerning these.

  1. There are some sleeps that have "magic number" as duration. Maybe some comment or reasonable named constant would help understand these. (Collision checking loop (l:167), jogging cmd wait loop (l:209), jogging calculations loop(l:233)
  2. All the sleeps are constant sleeps. That is ros::Rate, rate.sleep() pattern is not used. Is there any explanation, why is that?
AndyZe commented 6 years ago

Thanks for the suggestion. I didn't realize there was a significant difference between Duration and Rate until now. It is buttery-smooth. :)

abd812f