MC_MoveVelocity (motion control move velocity)

The MC_MoveVelocity instruction commands a never-ending controlled motion at a specified velocity.
Operation details:
  • If the DirectionIn input for MC_MoveVelocity is equal to 0 and:
    • The axis is in a moving state, the sign of the Velocity input is ignored, the axis continues to move in its current direction, and new dynamic parameters are applied.
    • The axis is not in a moving state, MC_MoveVolecity reports an error.
  • If the PTO Pulse limit is reached during execution of MC_MoveVelocity, the PTO Accumulator value is rolled over to 0 (or to the opposite soft limit if the limit is activated) and execution continues.
  • If the axis is in a moving state, and MC_MoveVelocity issues a motion in which the direction (the sign of Velocity * Direction) is the opposite of the current motion direction, the MC_MoveVelocity reports an error.
  • Once the signal "InVelocity" is set, it indicates MC_MoveVelocity is complete. Any subsequent motion event has no effect on the MC_MoveVelocity outputs except the signal "InVelocity".
  • The InVelocity output of MC_MoveVelocity stays True once the Velocity of the axis reaches the commanded Velocity or until MC_MoveVelocity is stopped.
  • The sign of (Velocity * Direction) determines the motion direction for MC_MoveVelocity. If the Velocity sign and the Direction sign are the same, positive motion is issued. If the Velocity sign and the Direction sign are different, negative motion is issued.
  • The signal "InVelocity" is reset when MC_MoveVelocity is overridden by another function block or Motion event, or at the falling edge of "Execute".
  • To stop or change the motion initiated by MC_MoveVelocity, the instruction block must be interrupted or overridden by another instruction block, which includes executing MC_MoveVelocity again with different parameters.
  • If MC_MoveVelocity is issued with the axis state in Standstill (not controlled by another function block) and a function block error occurs, the axis state goes to Error Stop.
Languages supported: Function block diagram, ladder diagram, structured text.
This instruction applies to the L50E and L70E controllers that support motion control.
MC_MoveVelocity
MC_MoveVelocity
MC_MoveVelocity parameters
Parameter
Parameter Type
Data Type
Desscription
EN
Input
BOOL
Instruction block enable.
  • TRUE: Execute current MC_MoveVelocity computation.
  • FALSE: There is no computation.
Applies only to ladder diagram programs.
AxisIn
Input
AXIS_REF
Use the AXIS_REF data type parameters to define AxisIn.
Execute
Input
BOOL
Indicates when to start motion.
  • TRUE: Start the motion at rising edge.
  • FALSE: Do not start motion.
Velocity
Input
REAL
Value of the maximum velocity [u/s].
Acceleration
Input
REAL
Value of the acceleration (increasing energy of the motor) [u/s
2
]
Deceleration
Input
REAL
Value of the deceleration (decreasing energy of the motor) [u/s
2
]
Jerk
Input
REAL
Value of the Jerk [u/s
3
]
DirectionIn
Input
SINT
The valid values are: -1, 0, 1.
BufferMode
Input
SINT
This parameter is not used.
ENO
Output
BOOL
Enable output.
Applies only to ladder diagram programs.
Axis
Output
Axis output is read-only in ladder diagram programs.
InVelocity
Output
BOOL
TRUE: Commanded velocity was reached (first time).
Busy
Output
BOOL
  • TRUE: The instruction block is not finished.
  • FALSE: The instruction block is finished.
Active
Output
BOOL
TRUE: Indicates that the function block has control on the axis.
Direction
Output
SINT
The valid values are: -1, 0, 1.
CommandAborted
Output
BOOL
TRUE: Command was overridden by another command, or Error Stop.
Error
Output
BOOL
Indicates that an error occurred.
  • TRUE: An error is detected.
  • FALSE: No error.
ErrorID
Output
UINT
A unique numeric that identifies the error. The errors for this instruction are defined in Motion control function block error IDs.

MC_MoveVelocity examples

MC_MoveVelocity function block diagram example
MC_MoveVelocity function block diagram example
MC_MoveVelocity ladder diagram example
MC_MoveVelocity ladder diagram example
MC_MoveVelocity structured text example
MC_MoveVelocity structured text example
Results
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal