I'm currently developing a 6 dof robotic arm. The arm is vibrating when it stop moving and I want to reduce it. Another thing is that arm is so heavy (because there is a projector inside it, lol) and I have to use spring between joints. So, can anyone tell me 1. how to select springs because my supervisor told me that proper selection of springs can reduce vibration? 2. how do I tune the PID parameters? All the joints are dynamixel servos and their PID parameters are tunable. I read article about tuning for a single servo. How do I tune these parameters for the whole arm?
I think the vibrations of the mechanical structure are due to the mechanical structures natural frequency. The dynamixel servos you mentioned are quite performant and have a acceleration and deceleration. This means that it has an abrupt stop when it reaches its setpoint, and this "shock" excites the mechanical structure at its natural frequency.
You could set the PID controller of the dynamixel servos softer with a large settling time without any overshot. This might help.
To tune the PID you can follow the Ziegler-Nichols method. The order of tuning should be backwards, from end-effector to base.
Another solution (and actually this would be my recommendation): You can leave the PID controllers of the servos as they are and do a trajectory planning. Instead of reducing the performance of the controllers (i.e. instead of making them soft), generate the reference values, the setpoints of the controllers, in a smooth manner, where you control the changes in position, velocity and acceleration, and those are not implicitly set by the controller. They will still be influenced by the controllers, but their effect will be greatly reduced. If you plan the trajectories smoothly (continuous acceleration, no sudden changes) the mechanical structure (at its natural frequency) will not be excited anymore. You will lose some dynamical performance but you will gain smooth motions.
The spring can help your servos if they do not have enough torque. It may effect the frequency of the vibrations but will not eliminate these in most cases. Dampers can be used to reduce vibrations, if your spring is actually a spring-damper it can eliminate vibrations.
To dimension a spring you have to determine what is the maximum torque required by the mechanical system in one given axis. You compare that with the maximum torque of your motor. if it is larger, so you need more torque than you have, you can use this difference to dimension a spring. The spring exerts a force, which is then converted to a torque using the perpendicular distance. This perpendicular however changes with the motion of the joint. So the design variables, spring constant, perpendicular distance (distance and angle of attack) will effect how much torque the spring will exert for every position of the joint. The same way the mechanical torque requirements of the robot will change for every position of the joint. The motor torque will not change. So...the torque coming form the spring plus the torque coming from the motor will have to be smaller than the required torque for every possible position of the joint.
Since you mentioned a projector: Please keep in mind that a small motion at the projector level will produce a large motion at the projected image. So you will have to have very smooth motions in order to not excite the mechanical structure. Or you could use a more robust mechanical structure, which is not that easy to excite.
Backlash can also be compensated to some degree. You can find more about it here.
Springs (no matter the combination) are not going to reduce the vibration. (there are exceptions because real springs lose energy but I don't think it applies to your case.) Damping could reduce the vibration, but that means you are throwing away energy and it sounds like you need all you can get to move that heavy projector.
Keep in mind that PID does not work as well when the load on the joints change, which is what happens in an arm. Depending on the angle of the joints, sometimes gravity will increase or decrease the apparent load in a way that makes the PID gains not work well at that angle.
Increasing the D gain of your PID will help. However for an arm you should be using a trajectory generator to set the target position to intermediate points between the start and end position.
Another issue you might be having is that you probably have the extra projector support springs arranged to help lift the projector to the position you will use most often. This means you will have asymmetric force gradients on the arm with gravity creating one force and the spring creating another.
- Use the single servo PID tuning approach for each servo, one at a time, with the joint axis of the servo of interest vertical and the other joints in a position that puts the projector closest to where you normally want it. Leave the projector support spring on. (the goal is to eliminate the influence of gravity when tuning the PID)
- Set up the arm for normal use and increase the D gain on the joints that are vibrating too much until it's ok (or until you get a high frequency vibration). I predict that the arm performance will not be good when you do this and you should do the next step.
- Add a trajectory generator to your control. With this you should be able to set an accelleration that gives you better performance than step 2 but might be a little slow.
- Switch to torque control, do your own PID calculaton and add feedforward control for gravity compensation and support spring compensation.
All of the above should help regardless if the vibration is from motor, mechanism, or control.
Starting with actuators that are properly sized for the application would be best but it sounds like that is not an option for you.