MC_TorqueControl (FB)
FUNCTION_BLOCK MC_TorqueControl
This Function Block commands a controlled torque/force/pressure movement and also limits the movement of an axis.
This Function Block continuously exerts a torque or force of the specified magnitude. This magnitude is approached using a defined ramp (‘TorqueRamp’), and the Function Block sets the ‘InTorque’ output if the commanded torque level is reached. This function block is applicable for force and torque. When there is no external load, force is applicable. Positive torque is in the positive direction of velocity.
The movement is limited by velocity, acceleration / deceleration or by the value of the torque.
Specific additional tests are outside this function block. For instance, checking on the traveled distance could be done via tracing the actual positions during the action.
- Example
The example below shows the typical behavior of an intermediate “resistive” load (see ‘Deceleration’ limit) with some “inertia” (see ‘TorqueRamp’ limit).
This example could be implemented in a function block diagram like:
Note
This function should not be use together with MC_LimitMotion for the same axis. This function block is implemented as wrapper of two blocks MC_LimitMotion and MC_LoadControl
- InOut:
Scope
Name
Type
Initial
Comment
Input
ExecuteBOOLStarts the function block at rising edge
ContinuousUpdateBOOLDecide if new input parameters are processed during the movement. This input is checked only when Execute gets TRUE
TorqueLREAL[u] = technical unit. Value of the Torque or Force or Pressure. Positive and negative values are allowed
TorqueRampLREAL[u/s] = technical unit. Absolute value of the input is considered. If TorqueRamp = 0, will result in a jump for load-change, as fast as possible
PositionLREAL[u] = technical unit. The position limitation is just activated if Direction is Positive or Negative, and will limit the position if reached in the respective direction
VelocityLREAL[u/s] = technical unit. Absolute value of the maximum velocity. Velocity=0 will switch off the velocity limitation
AccelerationLREAL[u/s°°2] = technical unit. Value of the maximum acceleration (acceleration is applicable with same sign of torque and velocity) Acceleration=0 will switch off the acceleration limitation.
DecelerationLREAL[u/s°°2] = technical unit. Value of the maximum deceleration (deceleration is applicable with opposite signs of torque and velocity) deceleration=0 will switch off the deceleration limitation.
JerkLREALValue of the maximum jerk (not used)
DirectionMC_DirectionDefault
- Input Load itself is a signed value. “Direction” applies to the movement for, required load to reach with a positive or negative reference or any direction required.
DEFAULT: The required load will be reached, no matter what direction movement is required
POSITIVE: The required load will be reached just when it is possible to do so with movement in positive direction
NEGATIVE: The required load will be reached just when it is possible to do so with movement in negative direction
BufferModeMC_BufferModeNot supported, default mcABORTING used
Output
InTorqueBOOLCommanded load finally reached, the actual load can be different
BusyBOOLThe function block is not finished
ActiveBOOLIndicates that the function block has control on the axis
CommandAbortedBOOLCommand is aborted by another command from other PLCopen function block
ErrorBOOLSignals that error has occurred within function block
ErrorIDAC500_MotionControl.ERROR_IDError identification. For error details refer to enumeration ERROR_ID from AC500_MotionControl library
Inout
Load_AxisReference to axis