Stepper motor axes

The basic version of the 'stepper motor axis' is operated without physical encoder. This means that there is no physical feedback of the actual position. Due to the operating principle of the stepper motor the number of steps made is exactly the same as the pulses output and hence the step counter can be used as a pseudo encoder. When doing so, please be aware that this relationship is lost in case of motor overloading. The diagram below shows the relationship between torque and drift angle.

Stepper motor axes 1:

Diagram 1: Dependency of relative torque (M/Mmax) on drift angle.

The angle details relate to a complete pulse cycle. The area displayed represents 3.6 degrees on the motor shaft for a motor with 200 pulses at full stepping operation.

If the motor has to provide torque when stopped or moving, then the rotor is pushed away from the torque-free ideal position by a corresponding angle. This corresponds to the relationship of a non-linear spring in the drive train. Apart from the resulting position deviation of the driven machine part this is unproblematic if the upper and lower vertex are not reached. In this case the motor torque drops, and the remaining load torque continues to push the motor. The motor is then not able to return to the correct angel and runs through a complete polling cycle. Only then is there a chance that the magnetic fields from rotor and stator interlock solidly. However, this only leads to a stable relationship if the load moment now is significantly below the motor torque. In this case the motor has then moved by complete cycle and must be re-referenced. However, this situation is not recognizable without appropriate sensors.

A totally different situation occurs if the load torque does not go down almost immediately due to the polling cycle shift. This is usually the case if the load torque results from the acceleration. Now the motor does not engage at the next stable point with a polling cycle shift, but rather runs through these points. It loses more and more speed in comparison with the distinct stator field and runs through each further pulse cycle without creating a net torque. This means that the motor coasts down due to excessively high noise development. At the end the travel profile runs through an area of decreasing pulse frequencies. Depending on the load moment the motor is rapidly accelerated just before the end of the profile and follow the rest of the profile. Finally, it has not made most of the profile and hence the route. This is also not recognizable without appropriate sensors.

When designing a stepper motor particular attention is to be given to fact that the speed has a strong influence on the available torque. The diagram below shows the relationship for a typical motor.

Stepper motor axes 2:

Diagram 2: Dependency of torque (Nm) on speed (RPM) for a typical stepper motor.

Apart from the load torque the motor also has to achieve the torque from the processes that result from the dynamics of the travel profile. If the total torque as shown in the example marked in red is 0.3 Nm then this motor may be run with a max speed of 1200 RPM. In practice however it is essential to plan in a suitable torque reserve.

Configuration of the stepper motor axis

Axis type: 'Continuous axis (incl. SERCOS)'

Encoder type: 'Encoder on KL5051/KL2502-30K/KL2521'

Controller type: e.g. 'position controller P'

Drive type: 'Drive on KL4XXX/KL2502-30K/KL2521'

Referencing

As usual, the digital referencing cam signal must be mirrored into the axis interface to the NC (PlcToNc axis structure) via the PLC. The usual procedure for referencing an axis applies, but the hardware feature "latching of a position", initiated by a sync impulse, is not available. Instead, the falling edge is used as local event for determining a reference position during ramp-down from the referencing cam. The accuracy of the referencing process can be increased as required through a reduction in velocity during ramp-down from the cam (the maximum possible precision is one motor step).

Stepper motor axes 3:

In comparison with the axis with analog set value output e.g. via a KL4032 the operation of a stepper motor power section on a KL2502-0010 or -3020 or KL2521 the terminal has to be parameterised depending on the application.

Parameterization of the KL2502-0010 or -3020

These versions of the KL2502 have different hardware from the basic one. The resulting increase of all internal working frequencies makes an expanded work area accessible. However this is not taken into account in the KS2000 software at present.

Stepper motor axes 4:

Parameterization of the KL2521

The base frequency 1 is to be set so that the terminal creates the maximum frequency when fully driven for the application concerned. If too low a value is entered here then the axis does not reach the foreseen velocity. If the setting is too high the resolution is worse than it was possible with the high resolution terminal. If this is acceptable then at least limits have to be ensured with by corresponding settings, so that the axis does not travel at too high velocity.

The terminal’s operating mode is to be set as per the signal definition of the power section. In this example, a direction signal and a pulse is expected.

The reference frequency for the example shown in figure 2 is calculated with the formula BF = N * S / 60. Here BF is the frequency in Hertz, N the speed in RPM and S the step number of the motor in the selected operating mode.

Sample calculation:

BF = 1200 [RPM] * 200 [1/R] / 60 [s/min] = 4000 Hz

The following example shows the correct setting for this example.

Stepper motor axes 5:

Settings in TwinCAT NC

The scaling factor of the encoder (Sf) is to be calculated from the feed per motor rotation (VU) and the step number (S) of the motor in the selected operating mode:

Sf = VU / S

Use of a KL2521

If a KL2521 is used the reference velocity (Vref) of the drive is to be calculated from the reference frequency (BF) and the scaling factor (Sf) of the encoder. The reference output is to be set to 1.0 when doing so. If the reference frequency of the terminal is set as per the maximum usable frequency then the "maximum allowed velocity" and the "rapid traverse velocity (G0)" in the global axis data can be set to a max of about 90 % of the reference velocity. If a higher reference frequency is selected then a maximum of about 90 % of the velocity may be entered, that would result in case the reference frequency is set exactly.

Vref = BF * Sf

Use of a KL2502-0010 or -3020

If a KL2502-0010 or -3020 is used then the reference velocity of the drive can be entered in two alternative formats. The first one uses an extrapolation of the output frequency on the full value range of the setpoint, even if this frequency cannot be displayed by the terminal. Here the S shows the step number of the motor in the selected operating mode. Here the reference frequency (BF) is the product of the maximum output value and the frequency scaling and results in 32768*8=262144.

Vref = BF * S = 262144 * S

Alternatively the reference velocity of the drive at the max selected velocity can be specified. For this the max corresponding frequency (Fmax) and the step number (S) of the motor are to be calculated in the selected operating mode.

Vref = Fmax * S

The associated relative control factor (A) is to be given as the reference output.

A = Fmax / BF = Fmax / 262144

All other axis parameters are to be set in the same way as for a servo axis. Here in particular empirical tests for the setting of the acceleration, deceleration and max jerk are to be carried out with the maximum expected mass to be moved in operation. Here it may not happen that the axis leaves out part of the movement due to overload.

Notice Stepper motors have a more or less distinctive natural resonance. This can lead to problems in the case of very flat ramps or unfavorably selected target velocities. The axis will then generate significant noise and can then be shifted and lose its correct reference by one or more polling cycles due to superposition of the travel movement with a low frequency jitter movement caused by brief overloading.