Modes and Commands

The axis can perform different commands. There are two methods to select a command, using O.Axisxx.Command or the specific command bit.
O.Axisxx.Command and Command Bits
Command
O.Axisxx.Command
Command Bit
Move Position
O.Axiss.Command = 1
O.Axisxx.Command_MovePosition = 1
Move Velocity
O.Axiss.Command = 2
O.Axisxx.Command_MoveVelocity = 1
Jog
O.Axiss.Command = 4
O.Axisxx.Command_Jog = 1
Stop
O.Axiss.Command = 8
O.Axisxx.Command_Stop = 1
Set Home Position
O.Axiss.Command = 16
O.Axisxx.Command_SetHomePosition = 1
Home
O.Axiss.Command = 32
O.Axisxx.Command_Home = 1
The last accepted command is reflected in I.Axisxx.Command and the specific command bits.
I.Axisxx.Command and Command Bits
Command
I.Axisxx.Command
Command Bit
Move Position
I.Axiss.Command = 1
I.Axisxx.Command_MovePosition = 1
Move Velocity
I.Axiss.Command = 2
I.Axisxx.Command_MoveVelocity = 1
Jog
I.Axiss.Command = 4
I.Axisxx.Command_Jog = 1
Stop
I.Axiss.Command = 8
I.Axisxx.Command_Stop = 1
Set Home Position
I.Axiss.Command = 16
I.Axisxx.Command_SetHomePosition = 1
Home
I.Axiss.Command = 32
I.Axisxx.Command_Home = 1
The following steps describe how to send commands to the stepper module:
  1. The ladder program updates output data for command parameters (for example, O.Axisxx.Command or O.Axisxx.Command_MovePosition, O.Axisxx.TargetPosition).
  2. The ladder program updates O.Axisxx.Execute from 0 to 1.
  3. The ladder program waits for I.Axisxx.CommandAccepted or I.Axisxx.CommandError to be set to 1.
    The ladder program should not update command parameters before this step.
  4. The ladder program clears O.Axisxx.Execute.
    The module clears I.Axisxx.CommandAccepted or I.Axisxx.CommandError.
    The module sets I.Axisxx.CommandActive while the command is in progress.
The following steps describe the items to check before sending the next command.
  1. The ladder program waits for I.Axisxx.CommandAccepted and I.Axisxx.CommandError to clear.
  2. Check if the previous command is still active.
    1. For Stop command – The ladder program can send a Stop command even if the last command is still active.
    2. For Move Velocity command – If the last command was Move Velocity, the ladder program can send another Velocity command to change velocity or velocity profile at any time.
    3. For other commands (Move Position, Move Jog, Set Home Position, or Home command) – The ladder program waits for I.Axisxx.CommandActive to clear. If the last command was Move Velocity, the command is always active until a Stop command is sent.
  3. Send the next command.
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal