Hey folks!
So I am using the PCA9685 to run 15 servos. They all work fine, but once I attach some arms to them I have 2 servos that shake at the end of their movement. I've tried changing the Min and Max values for their rotation, but still shake. If I touch the arm they are attached to then the shaking stops.
I assume that it is trying to reach a value, but is overshooting, then undershooting, and stuck in a loop trying to get to said position. At least that is what it seems like. 13 others in practically the same mechanical set up are working fine.
There are rather cheap hobby servos, but they are what I have to work with.
Any idea on how to fix that in code? I am using a ProMicro, with pins 2&3 for SDA&SCL respectively.
Is there a way to simply turn off the servo's control signal? They are not holding a load, so I am not worried about it needing power to hold a position.
About 95% of the servo problems reported on this forum (almost daily) are due to power supply problems, so that is always the first thing to suspect.
Please post links to your servos, to the power supply (or the current/voltage characteristics) and a hand drawn wiring diagram.
The general rule of thumb is 1 Ampere per moving servo, so in principle, you need a 5 to 6V, 15 Ampere power supply for the project.
Servos:
360mA stall current, so 5.4A max it seems.
Power supply:
10A 5VDC power supply, so show be plenty.
If it were a current issue I would expect other servos to be acting up as well, but it is just a couple of them, and at the end of their movement, not during it.
I will work on a sketch, but the power to the servo controller is coming from the main power supply, not through the Arduino, if that were a concern.
The SG-90 stall current is 650 +/- 80 mA, so to be safe, you need at least 10 Amperes.
End of movement twitching can be caused by driving the servos to or past their end stops, and that will eventually destroy them
magic_smoke:
If it were a current issue I would expect other servos to be acting up as well, but it is just a couple of them, and at the end of their movement, not during it.
Just to check, what happens if you limit the travel on those 2 servos to something less than the range that produces the twitching behavior?
If you write 180 and it starts twitching, try writing 170 instead.
Or, when you attach() the servo, use the optional min and max parameters (544 and 2400 by default) and with a smaller range, maybe 1000 and 2000.
If the stationary loads on the servos are not sufficient to move the servo against the friction of the gear train then one option is to detach the servo when a move is complete and only re-attach immediately before the next move.
If the stationary load is big enough to force the gear train to move then it would probably be advisable to use a bigger servo.
...R
It is a very light load. I will check to see if I am somehow hitting a limit (it is an occasional issue so not sure if that is the case), and if adjusting that doesn't work then I will just send it a '0' state once it finishes moving. It doesn't need to hold much force at all, so turning off is fine.
Thanks for the feedback!
" They all work fine, but once I attach some arms to them I have 2 servos that shake at the end of their movement"
Do the servos shake when the arms are removed? You may be overloading them and they constantly hunt to try to hold position.
zoomkat:
Do the servos shake when the arms are removed? You may be overloading them and they constantly hunt to try to hold position.
Nope. But the arm weighs barely anything, is just a long light piece of plastic. It seems to be just enough wobble to make the servo freak out due to it being a lever arm. Trying to figure out how to turn off that hunt. I send it a "0" position command, which turns off almost every other servo (can free rotate by hand), but this one does not.