Control modes

The KINGSTAR Subsystem offers several modes that control how your application, Subsystem and servo drives interact with each other. This section describes the way each mode works.

To choose a control mode, use the SetAxisControlMode function. The control mode must be compatible with the current access mode, which is set using the SetAxisAccessMode during initialization. Not all drives support control mode changes while the motor is powered on.

modeDirectVel

This mode is called Direct Velocity. The servo drive operates in cyclic synchronous velocity (CSV). In this mode, your application needs to calculate interpolation arithmetic, and send a velocity command to the KINGSTAR Subsystem (KS) every EtherCAT cycle. This mode cannot use MoveAxis functions.

NOTE:  We suggest you use this mode only for RT API.

  1. Your application interpolates the commanded positions for the cycle based on the target and the motion profile.
  2. The application calculates the commanded velocity based on the commanded and feedback positions. It passes the commanded velocity to the KS using the SetAxisVelocity function.
  3. The KS sends the velocity to the servo drive.
  4. The servo drive converts the velocity to a torque and sends the corresponding current to the servo motor.
  5. The drive receives the current position from the encoder, and sends it back to the application.
  6. These steps are repeated until the motor reaches its destination.

modeDirectPos

This mode is called Direct Position. The servo drive operates in cyclic synchronous position (CSP). In this mode, your application needs to calculate interpolation arithmetic, and send a commanded position to the KINGSTAR Subsystem (KS) every EtherCAT cycle. This mode cannot use MoveAxis functions.

NOTE:  We suggest you use this mode only for RT API.

  1. Your application interpolates the commanded position for the cycle based on the target and motion profile. It passes the commanded position to the KS using the SetAxisPosition function.
  2. The KS sends the position to the servo drive.
  3. The drive calculates the velocity based on the position and interpolation period. It then converts the position and velocity to a torque and sends the corresponding current to the servo motor.
  4. The drive receives the position from the encoder.
  5. These steps are repeated until the motor reaches its destination.

modeDirectTor

This mode is called Direct Torque. The servo drive operates in cyclic synchronous torque (CST). In this mode, your application needs to calculate interpolation arithmetic, and sends a torque command to the KINGSTAR Subsystem (KS) every EtherCAT cycle. This mode cannot use MoveAxis functions.

NOTE:  We suggest you use this mode only for RT API.

IMPORTANT:  Torque doesn't have the default value. You must tune the torque and find the best PID parameters before you use this mode. You may use KINGSTAR Configuration Tool, or use your own tool for tuning.

  1. Your application interpolates the commanded position for the cycle based on the target and motion profile. It then calculates a commanded torque based on the arithmetic model of the machine and the feedback position. It passes the commanded torque to the KS using the SetAxisTorque function.
  2. The KS sends the torque to the servo drive.
  3. The drive sends the corresponding current to the servo motor.
  4. The drive receives the current position from the encoder, and sends it back to the application.
  5. These steps are repeated until the motor reaches its destination.

modeMasterIntVel

This mode is called Master Interpolation Velocity. The servo drive operates in cyclic synchronous velocity (CSV). In this mode, the KINGSTAR Subsystem (KS) handles most calculations for you.

  1. You use various functions to command a movement to the KS.
  2. The KS interpolates the commanded position for the cycle based on the target and motion profile.
  3. The KS uses its PID to calculate the commanded velocity based on the commanded and feedback positions. It then sends the velocity to the servo drive.
  4. The drive converts the velocity to a torque and sends the corresponding current to the servo motor.
  5. The drive receives the current position from the encoder and sends it back to the KS.
  6. The steps 2-5 are repeated until the motor reaches its destination.

modeMasterIntPos

This mode is called Master Interpolation Position. The servo drive operates in cyclic synchronous position (CSP). In this mode, the KINGSTAR Subsystem (KS) handles most calculations for you.

  1. You use various functions to command a movement to the KS.
  2. The KS interpolates the commanded position for the cycle based on the target and motion profile.
  3. The KS sends the commanded position to the servo drive.
  4. The drive calculates the velocity based on the position and interpolation period. It then converts the position and velocity to a torque and sends the corresponding current to the servo motor.
  5. The drive receives the current position from the encoder and sends it back to the KS.
  6. The steps 2-5 are repeated until the motor reaches its destination.

modeMasterIntTor

This mode is called Master Interpolation Torque. The servo drive operates in cyclic synchronous torque (CST). In this mode, the KINGSTAR Subsystem (KS) handles most calculations for you.

  1. You use various functions to command a movement to the KS.
  2. The KS interpolates the commanded position for the cycle based on the target and motion profile.
  3. The KS uses its PID to calculate the commanded torque based on the commanded and feedback positions. It then sends the torque to the servo drive.
  4. The drive sends the corresponding current to the servo motor.
  5. The drive receives the current position from the encoder and sends it back to the KS.
  6. The steps 2-5 are repeated until the motor reaches the destination.

modeSlaveInt

This mode is called Slave Interpolation. The servo drive operates in Profile Position (PP). In this mode, most calculations are done in the servo drive.

  1. You use various functions to command a movement to the KINGSTAR Subsystem (KS).
  2. The KS sends the commanded movement and motion profile to the servo drive.
  3. The drive interpolates the commanded position for the cycle based on the target and motion profile.
  4. The drive uses its PID to calculate the commanded torque based on the commanded and feedback positions. It then sends the corresponding current to the servo motor.
  5. The drive receives the current position from the encoder and sends it back to the KS.
  6. The steps 3-5 are repeated until the motor reaches its destination. The drive then signals the KS that the movement has ended.

modePidVel

This mode is called PID Velocity. The servo drive operates in cyclic synchronous velocity (CSV). In this mode, your application needs to calculate interpolation arithmetic and send a position command to the KINGSTAR Subsystem (KS) every EtherCAT cycle. The KS and the servo drive perform the remaining calculations. This mode cannot use MoveAxis functions.

  1. Your application interpolates the commanded position for the cycle based on the target and motion profile. It passes the commanded position to the KS using the SetAxisPosition function.
  2. The KS uses its PID to calculate the commanded velocity based on the commanded and feedback positions. It then sends the velocity to the servo drive.
  3. The drive converts the velocity to a torque and sends the corresponding current to the servo motor.
  4. The drive receives the current position from the encoder and sends it back to the KS.
  5. These steps are repeated until the motor reaches its destination.

modePidTor

This mode is called PID Torque. The servo drive operates in cyclic synchronous torque (CST) mode. In this mode, your application needs to calculate interpolation arithmetic and send a position command to the KINGSTAR Subsystem (KS) every EtherCAT cycle. The KS and the servo drive perform the remaining calculations. This mode cannot use MoveAxis functions.

  1. Your application interpolates the commanded position for the cycle based on the target and motion profile. It passes the commanded position to the KS using the SetAxisPosition function.
  2. The KS uses its PID to calculate the commanded torque based on the commanded and feedback positions. It then sends the torque to the servo drive.
  3. The drive sends the corresponding current to the servo motor.
  4. The drive receives the current position from the encoder and sends it back to the KS. These steps are repeated until the motor reaches its destination.

See also

RT and Win32 API – Axis configuration

SetAxisControlMode

RT and Win32 Type

McControlMode