This is an illuminating discussion. I thank you.
I see that you mentioned that there is often the most jitter at the end of the sweeps, but in my case your graph EXACTLY mirrors the motion that my LB Servo makes as it progresses through its full range of motion. The greatest jittering occurs towards the CENTER line of the sweep with the least towards the tail ends of each sweep. For the application that my daughter needs, this endogenous jitter may prove very functional. So, I think that we can live with this even if modifications aren't able to compensate.
That said, between the time of this new posting of mine and my previous posting I had reviewed the link that you had sent me, as well as read posts on various Arduino and r/c forums across the web and your post is an awesome summary of much that I ran across. Many thanks for the detail, succinctness and organization of the subject. And, more importantly, your graph really is the image worth a thousand words.
Still, I'm not sure that I totally understand the graph. Please help me. You called it:
"v=analogRead(A2)/4; and printed out i and v."
So, what specifically are the axes of the graph?
x=current with a y=voltage output?
Or, is X the angle of the sweep with y = voltage output (which is bumping up and down)?
Now, for solutions:
1) software: as you indicate, I will try to tinker with the delay in your sketch.
2) hardware: I read that more expensive servos usually work with less jitter because their potentiometers are more refined with greater resolution, as well as being made of higher quality substrate. But, I'd have to go beyond the LB hardware for such a solution and start to attach to the extra pins on the LB arduino. Also, mapping 25 - 255 over a 145 degree sweep provides an intrinsic resolution limit of (if my calculations are correct) a bit more than half a degree per step.
I did purchase a LB hardware developers kit, so that may be a way to go.
3) many sites suggest opening the servo and cleaning the potentiometer, suggesting that the pot may have oxidized surfaces or debris. I can't imagine that this is the likely problem since these are brand new (although stranger things have happened in factories). Also, the data that you cleverly collected by feeding d5 into a2 and analogRead(a2) totally mirrors what I am subjectively seeing and suggests, therefore, that the problem is within either the LB Arduino or the USB power source.
I've ruled out the USB power source as being the origin of the noisy current (or is it voltage?) by replacing the power with a 9v battery. Still, even with the 9v battery the servo jitters to an identical degree across the full range of motion.
4) some sites suggest that:
a) the placement of a tiny nanofarad capacitor (or even resistors) across "various" (I use 'various" to indicate my confusion about whether or not this is a signal problem or a power problem) leads will smooth the electrical noise originating from the Arduino that you have displayed with your i,v graph (which I'm embarrassed to say that I don't precisely understand).
b) the placement of a larger microfarad level capacitor will supplement any initial current drawdown that the servo can cause each time it begins motion.
This all begs a question tilted directly at Little Bits, Inc. Might Little Bits consider creating a servo and Arduino combination that solves this problem out of the box so that we don't have to? I'm a fairly well educated fellow, a newbie to programming and micro controllers to be sure, but quite capable of learning with a couple of college-level physics, math and computer courses under my belt and a professional medical degree (from 20 years ago) and I am fairly challenged by this. It's fun for me, but I think that this would be a royal turnoff for many kids who have a peripheral interest in the utility of computer science. I'm speaking, of course, about my very bright daughter who is more interested in the application of the LB Arduino towards her nascent veterinary ambitions.
Servos are a big deal as they provide a computer, and by extension the customer (child), the ability to very precisely manipulate the world. However, without convenient and reliable control, the servo is hardly practical and therefore a drawback when combined with Arduino.