MC_SetOverride (FB)¶
FUNCTION_BLOCK MC_SetOverride
This function block sets velocity, acceleration/deceleration and jerk override factors for an axis.
Function blocks that are working on the axis consider these override factors. The factors contribute as a factor to the calculation of the commanded velocity, acceleration and jerk of the motion.
- Example 1
- Use of
MC_SetOverride
In this example, the axis is moved from position 0 u to position 100 u with MC_MoveAbsolute.The maximum velocity is 100 u/s, the maximum acceleration is 1000 u/s², and the maximum jerk is 10000 u/s³.Shortly after the axis reaches position 50 u, an override is commanded with velocity factor 0.75 (75%).

Note
The override factors can be changed at any time and act directly on the ongoing motion.
The function block instance of MC_SetOverride should be called before the movement function blocks of the axis are called. If it is called after the movement function block, the override will take effect one cycle later.
Changing the override should require about the same amount of computation as aborting an ongoing movement with a new movement.
An override has no influence on slave axes once they are ramped in / in sync. However, the override does act while ramping in or gearing in.
It is recommended to use ramp type trapezoid or quadratic when using this function block. With the other ramp types sin² and quadratic_smooth, an overshoot may occur when applying a new override. This is analogous to the possible overshoot when aborting movements with these ramp types.
Coordinated movements (e.g.
MC_MoveLinearAbsolute
) commanded on an axis group will consider override factors set on any axis of the axis group.In state
discrete_motion
reducing theAccFactor
and/orJerkFactor
can lead to a position overshoot – a possible cause of damage. If SMC_MoveContinuousAbsolute or SMC_MoveContinuousRelative is active, a change ofVelFactor
can also lead to a position overshoot or an unwanted reversal. See the documentation for these two function blocks for details.
- Example 2
- An override during deceleration leading to position overshoot.The maximum velocity is 100 u/s, the maximum acceleration is 1000 u/s², and the maximum jerk is 10000 u/s³.The override for acceleration and jerk is reduced to 0.5 (50%) during deceleration to the target position 100 u. In this situation, the override leads to a position overshoot and a reversal of the axis.

- InOut:
Scope
Name
Type
Initial
Comment
Inout
Axis
Reference to the axis
Input
Enable
BOOL
TRUE
: The override factors are continuously writtenVelFactor
LREAL
1
New override factor for the velocity in the range [0, 1]
AccFactor
LREAL
1
New override factor for the acceleration/deceleration in the range (0, 1]
JerkFactor
LREAL
1
New override factor for the jerk in the range (0, 1]
Output
Enabled
BOOL
TRUE
: The override factors are set successfullyBusy
BOOL
TRUE
: Function block is in operationError
BOOL
TRUE
: Error has occurred during executionErrorID
SMC_ERROR
Error identification