Playing back recorded movements with servos
The jerky movement is likely caused by the fact that the servo can move fairly fast compared to the rate at which you're sending position commands. If you were to record the movement on a high speed camera, and play it back in slow-mo, what you'd see is the servo moving rapidly towards its target position, and begin to slow down as it reached that position, then finally stop on target.

Then you send it a new target position, and it accelerates quickly up to full speed, then slows down again and stop at the next target.

If you were to record twice as many positions, so that you're sending targets twice as often, then the motor might not have completely stopped before the next target arrives. At which point, it accelerates again. This will produce noticeably smoother movement, because there is less variation in speed (the servo never stops completely).

Double the target rate again, and you'll get smoother movement still. Personally, I suggest sending targets at the highest rate you can. This doesn't mean you need to take more position readings. You can use linear interpolation (or cubic interpolation, scroll down to the interpolation section on my page about Perlin Noise) to increase the number of target positions.

The more often you send target positions, the less the servo's velocity will vary, and the smoother will be its movement.

But, if you're paying attention, you'll notice that each time a new target arrives, the servo hadn't quite reached its previous target. Thus the servo is always late for its targets.

This may not be a problem for you, and it's the normal behaviour of a servo. As long as your're not asking the servo to go faster than it's able to, then it won't be that far behind, and you probably won't notice the error.



If you really need the servo to be dead on target all the time. For example, if you are operating a CNC milling machine, and you need to machine metal to an accuracy of 10um, then you need to use a position/velocity control loop which is aware of the list of upcoming target positions, and can control the velocity accordingly. It is probably not possible to do this with a Dynamixel servo.