Skip to main content

Kollmorgen Support Network

Tuning Servos with a PiC900 | 12 Feb 2015 | |

Tuning Servos with a PiC900

This document refers to G&L PiC application note AN000032 and describes tuning servos with a PiC900.

When tuning servos with a PiC900 following this outline will result in high servo performance.

Note:  Before tuning an axis remember to take into account any safety precautions necessary. 

The following values can be temporarily updated in the control using the Field download feature in Servo Setup.  If the scan is restarted the values will revert back to the values which existed at the time of the last servo setup library build and download.

  • Proportional gain - Control Proportional gain.
  • Integral gain  - Control Integral gain
  • Derivative gain - Control Derivative gain
  • Analog output offset - Zero speed offset to compensate for DC bias.
  • Slow velocity filter - Low pass velocity filter.
  • Feed Forward Percent - Velocity feed forward compensation.

Additionally there are 3 other parameters not on the field download list which can be temporarily updated although they are not on the field download list.  Simply change the value in the editing section then go to axis tune and do a field download.

Output Scaling:

  • Commanded voltage - Voltage commanded at maximum speed.
  •  Motor RPM at voltage - The Maximum speed at the commanded voltage.
  •  Counts/motor revolution - Feedback units per speed unit in Motor RPM at voltage.      

These 3 variables combine to affect the output voltage for both the combined gains and the feed forward terms.  The desired effect is to get the control and the drive to agree on what voltage level represents a given speed.  In a 10 Volt system,  if the control outputs 5 V the axis will move at exactly 1/2 speed.

To begin tuning:

  1. Tune the drive velocity loop.  ( See the Drive Tuning section of the DSM100 or MicroDSM  Installation Manual).
  2. Reduce the control proportional gain to 1000. 
  3. Set the control integral and derivative gain to 0.
  4. Set Feed Forward to 100 percent.
  5. Move the axis at a constant speed using a velocity move.
  6. While the axis is at constant command velocity observe the following error.  Since feed forward is set to 100 percent the following error should be changing plus and minus around 0.
    1. If the axis is being commanded plus and the following error is always plus then reduce the value entered for MAX. RPM in servo setup.
    2. If the axis is being commanded plus and the following error is always minus then increase the value entered for MAX. RPM in servo setup.
    3. If the axis is being commanded minus and the following error is always minus then reduce the value entered for MAX. RPM in servo setup.
    4. If the axis is being commanded minus and the following error is always plus then increase the value entered for MAX. RPM in servo setup.

Continue to adjust the value until the following error is changing from plus to minus around zero.  When the system seems balanced then increase the speed and observe the following error again, repeat steps 5 and 6 as necessary.

  1. With the axis stopped observe the stability of the axis.  The axis may move back and forth a count or 2 but should not move any more than that.  Begin to increase the proportional gain incrementally.  Stop periodically and test the stability by creating a load disturbance on the axis.  Typically a well tuned servo will have a proportional gain between 2000 and 4000.
  2. Again command the axis in a velocity move and observe the stability of the following error and the axis.  Continue to increase the proportional gain until the axis achieves the desired response.  If the axis begins to become unstable, then reduce the proportional gain by about 20%.  Instability can be seen by watching the following error.  If  the following error begins to change more rapidly, or the +/- swing begins to increase the axis is becoming unstable.  Instability can also be seen using an oscilloscope.  When using an oscilloscope observe the feedback velocity.  The signal should be flat at constant speed.  Observing the drive current is also useful.

Other tips on tuning:

Typically a well tuned servo will have a control proportional gain between 2000 and 4000.  Some of the better drives like the Centurion DSM100  and MicroDSM drives allow gains up to 6000, 8000 or even higher.  Hydraulics do not typically allow as high of a gain.  If the proportional gain cannot be raised above 2000 this might indicate:

  1. A poor mechanical system with backlash, compliance, or poor inertia match. Mechanically look at the coupling, be sure a flexible coupling is not being used. Try to determine how much lost motion is in the gearbox. Be sure belts are a steel reinforced belt or similar product. Belts should not be rubber timing belts. Size the mechanics to determine the inertia reflected back to the motor.
  2. B.  The drive velocity loop does not have very high bandwidth or is improperly tuned. Re-tune the velocity loop.

Different applications require different tuning.  In many cases the move type can also impact what gain settings are used. 

When tuning to remove overshoot first consider the acceleration and deceleration which is being commanded.  Is the requested acceleration and deceleration reasonable?  One way to test this is to put a value of 100 or 200 in the slow velocity filter.  If the overshoot goes away the acceleration and deceleration being asked for is too high.  If the acceleration or deceleration being commanded is higher than the servo system is capable of achieving it will always overshoot.  Reducing the acceleration and deceleration should eliminate this problem.  Increasing the drive gain may also eliminate overshoot.  A faster interrupt rate may reduce overshoot as well.

In intermittent motion applications the Feed Forward value can be reduced to affect the amount of overshoot.

When using Ratio moves some functions such as RATIO_RL and RATIOSLP are better suited to handle smooth speed changes.  By designing linear or s-curve ramps to change speed the gain can often be higher without overshoot.  If using one of the other ratio functions it may be possible to add some slow velocity filter to alleviate the problem.

Always consider the ratio of the master and slave.  When the ratio between the slave and master becomes high the slave axis will begin to look unstable especially at slower speeds.  Using the slow velocity filter will reduce this problem.  A better solution would be to increase the resolution available from the master axis.  This will reduce the ratio between the master and slave counts.

About this Article

Randy Bauer