Velocity and Acceleration override using MC_SetOverride
MC_SetOverride is used to override the speed and change the rate of acceleration of the selected axis movement. Setting velocity to 0.0 will stop the axis but won’t put the axis in StandStill state. A value of 1.0 equals 100%. The selected axis must be executing a move to use this function block.
-
Negative number should not be used and will cause a function block error.
-
LS_Connect and MC_Power must be executed before this function block can be used.
-
The examples in this topic can be found in the XMC_SingleAxis_FBs.zip downloadable from Example Applications.

Element Name | Element Type | Description |
---|---|---|
Enable | Input | Level detected request to execute the function block. |
Axis | Input/Output | Axis reference variable. This can not be a constant. |
VelFactor | Input | Specify the override velocity, 1.0 = 100%. |
AccFactor | Input | Specify the override in acceleration/deceleration rate, 1.0 = 100%. |
JerkFactor | Input | Specify the override in jerk rate, 1.0 = 100%. |
Enabled | Output | Indicates the inputted torque value and current operating torque value are equal. |
Busy | Output | Indicates the function block is currently being executed. |
Error | Output | Indicates whether an error occurs or not. |
ErrorID | Output | Error Identification number. |

Before executing MC_SetOverride
After executing MC_SetOverride

//Set axis reference
Axis1 := 1;
IF (_AX01_RDY) AND (_AX01_SV_ON) THEN
//Example MC_SetOverride fb
INST_SETOVERRIDE(Enable:=Execute_Override, Axis:=Axis1,
VelFactor:=INST_SETOVERRIDE.VelFactor,
AccFactor:=INST_SETOVERRIDE.AccFactor,
JerkFactor:=INST_SETOVERRIDE.JerkFactor,
ErrorID=>INST_SETOVERRIDE.ErrorID);
END_IF;
LM517