MC_AxRtGenerator_BkPlcMc

MC_AxRtGenerator_BkPlcMc 1:

This function block performs the task of a setpoint generator. To this end a profile-specific function block is called, depending on the value set as nProfileType in Axis.ST_TcHydAxParam.

MC_AxRtGenerator_BkPlcMc 2: Inputs/outputs

VAR_INOUT
    Axis:       Axis_Ref_BkPlcMc;
END_VAR

Name

Type

Description

Axis

Axis_Ref_BkPlcMc

Here, the address of a variable of type Axis_Ref_BkPlcMc should be transferred.

MC_AxRtGenerator_BkPlcMc 3: Outputs

VAR_OUTPUT
    Error:      BOOL;
    ErrorID:    UDINT;
    LagError:   BOOL;
END_VAR

Name

Type

Description

Error

BOOL

The occurrence of an error is indicated here.

ErrorID

UDINT

An encoded indication of the cause of the error is provided here.

LagError

BOOL

If the lag error exceeds the set limits, it is indicated here. This signal is also available if position lag monitoring is not activated.

Behavior of the function block

The function block investigates the axis interface that has been passed to it every time it is called. A number of problems can be detected and reported during this process:

If it is possible to carry out these checks without encountering any problems, the setpoint generation is executed by calling an appropriate function block corresponding to the nProfileType in Axis.ST_TcHydAxParam.

The LagError output indicates whether the current lag error of the axis exceeds the set limits. The axis is only set to an error state if bMaxLagEna is set in Axis.ST_TcHydAxParam.

The following generators are presently available:

nProfileType

Description

iTcMc_ProfileCtrlBased

Standard profile: Single-stage time-referenced acceleration, displacement-referenced (square root) braking ramp, target approach at creep velocity, selectable behavior when stationary.

An axis in motion can be restarted at any time (new target, new velocity etc.), except in error state or in a state with dependent control value generation.

Info: Overshooting the new target can happen even if the axis is in front of the target position at the time of the start.

Info: The function block can be parameterized such that it starts automatically and assumes an active motion state under certain conditions, which are defined through its parameters.

Info: This generator type can optionally operate in purely time-controlled mode with continuously closed position controller.

iTcMc_ProfileJerkBased

Standard profile: Single- or two-stage time-controlled acceleration through optional jerk limitation, displacement-controlled (square root generator) braking ramp, target approach with jerk limitation, selectable behavior in idle state.

An axis in motion can be restarted at any time (new target, new velocity etc.), except in error state or in a state with dependent control value generation.

Info: Overshooting the new target can happen even if the axis is in front of the target position at the time of the start.

Info: The function block can be parameterized such that it starts automatically and assumes an active motion state under certain conditions, which are defined through its parameters.

Info: This generator type can optionally operate in purely time-controlled mode with continuously closed position controller.

Info: Some functions are not supported by this generator type, or not fully.

iTcMc_ProfileTimePosCtrl

Info: Only present for compatibility reasons; will shortly no longer be supported.

Special profile: Two stage acceleration (initially time-referenced, then displacement-referenced following square root curve), displacement-referenced (square root) braking ramp, target approach at creep velocity, selectable behavior when stationary.

It is not possible to execute a start for an axis that is already travelling (new target, new velocity etc.).

iTcMc_ProfileCosine

Info: Only present for compatibility reasons; will shortly no longer be supported.

Special profile: Two stage acceleration (initially time-referenced, then displacement-referenced following cosine curve), displacement-referenced (cosine) braking ramp, target approach at creep velocity, selectable behavior when stationary.

It is not possible to execute a start for an axis that is already travelling (new target, new velocity etc.).

iTcMc_ProfileTimeRamp

Special profile: Single-stage time-controlled acceleration, time-controlled braking ramp, target approach with creep speed, conditionally selectable behavior in idle state. The generator uses position cams instead of an encoder.

An axis in motion can be restarted (new target, new velocity etc.), except in error state.

Info: This generator type is intended for axes, which only have digital cams instead of an encoder.

If only the usual function blocks (encoder, generator, finish, drive) for the axis are to be called, a function block of type MC_AxStandardBody_BkPlcMc should be used for simplicity.

iTcMc_ProfileCtrlBased

A profile is generated with a time-controlled acceleration phase, a displacement-controlled braking phase based on the square root generator principle, and a target approach with creep speed.

MC_AxRtGenerator_BkPlcMc 4:

The arrows on the profile of the control value suggest how the shape of the curve can be affected through the parameters of the move order or of the axis. To begin with, a time-controlled ramp function "1" is used to accelerate to the required travel velocity "2". This control value is maintained until a point is reached that was recalculated at the start. After this point, a displacement-referenced ramp "3" is followed to brake down from the main travel velocity to the creep velocity "5"; this control value is reached at a specified distance, "4", from the target. This control value is retained until the target has been approached to within a specified remaining distance "6". The axis is then switched to its idle behavior.

Parameters active in the travel profile

Start ramp "1": The smallest of the following values is the effective one: fMaxAcc and fAcc in Axis.ST_TcHydAxParam, Acceleration of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Travel phase "2": The smallest of the following values is the effective one: fRefVelo and fMaxVelo in Axis.ST_TcHydAxParam, Velocity of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Braking ramp "3": The smallest of the following values is the effective one: fMaxDec and fDec in Axis.ST_TcHydAxParam, Deceleration of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Creep phase "4", "5": The values of fCreepSpeed and fCreepDistance in Axis.ST_TcHydAxParam have an effect.

Transfer to target "6": The fBrakeDistance and/or fBrakeDeadTime in Axis.ST_TcHydAxParam have an effect.

Automatic starting of the axis

If the difference between the actual position and the current target position exceeds the value in Axis.ST_TcHydAxParam.fReposDistance, an automatic start is triggered.

iTcMc_ProfileJerkBased

A profile is generated with a time-controlled acceleration phase (with optional jerk limitation), a displacement-controlled braking ramp based on the square root generator principle, and a target approach with jerk limitation.

MC_AxRtGenerator_BkPlcMc 5:

The arrows on the profile of the control value suggest how the shape of the curve can be affected through the parameters of the move order or of the axis. To begin with, a time-controlled ramp function "1" is used to accelerate to the required travel velocity "2". The optional jerk limitation "6" can take effect. The travel speed is maintained until a point is reached that was recalculated at the start. At this point a displacement-controlled braking ramp "3" is applied, until the distance to the target has reduced to the residual distance. The deceleration "4" is reduced with limited jerk "5" towards the target. The axis is then switched to its idle behavior.

Parameters active in the travel profile

Start ramp "1": The smallest of the following values is the effective one: fMaxAcc and fAcc in Axis.ST_TcHydAxParam, Acceleration of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Travel phase "2": The smallest of the following values is the effective one: fRefVelo and fMaxVelo in Axis.ST_TcHydAxParam, Velocity of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Braking ramp "3", "4": The smallest of the following values is the effective one: fMaxDec and fDec in Axis.ST_TcHydAxParam, Deceleration of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Transfer to target "5": fMaxJerk in Axis.ST_TcHydAxParam and fJerk of the function block used on axis start take effect (example: MC_MoveAbsolute_BkPlcMc) and fBrakeDistance and/or fBrakeDeadTime in Axis.ST_TcHydAxParam.

iTcMc_ProfileTimePosCtrl

MC_AxRtGenerator_BkPlcMc 6:

Only present for compatibility reasons; will shortly no longer be supported. It should not be used for new projects and should be replaced when existing projects are revised, if possible.

iTcMc_ProfileCosine

MC_AxRtGenerator_BkPlcMc 7:

Only present for compatibility reasons; will shortly no longer be supported. It should not be used for new projects and should be replaced when existing projects are revised, if possible.

iTcMc_ProfileTimeRamp

A profile is generated with a time-controlled acceleration phase, a time-controlled braking phase and a target approach with creep speed.

MC_AxRtGenerator_BkPlcMc 8:

The arrows on the profile of the control value suggest how the shape of the curve can be affected through the parameters of the move order or of the axis. To begin with, a time-controlled ramp function "1" is used to accelerate to the required travel velocity "2". This control value is maintained until the direction-specific target window cam is detected. From here, a time-controlled ramp "3" is applied to decelerate from the set motion value to the set creep value "5". This control value is maintained until the direction-specific target cam is detected. The axis is then switched to its idle behavior.

Parameters active in the travel profile

Start ramp "1": fStartRamp has an effect in Axis.ST_TcHydAxParam.

Travel phase "2": The smallest of the following values is the effective one: fRefVelo and fMaxVelo in Axis.ST_TcHydAxParam, Velocity of the function block used to start the axis (for example: MC_MoveAbsolute_BkPlcMc).

Braking ramp "3": fStopRamp has an effect in Axis.ST_TcHydAxParam.

Creep phase "4": fCreepSpeed has an effect in Axis.ST_TcHydAxParam.

Behavior of the function block on restart during a motion

If a further start command is issued during an active movement, a distinction has to be made between two cases.

MC_AxRtGenerator_BkPlcMc 9:

This profile is created on restart in the same direction with a different velocity (higher in this case).

MC_AxRtGenerator_BkPlcMc 10:

This profile is created on restart in the opposite direction, in this case with the same velocity.

This profile type can only be used in a meaningful manner in combination with the encoder type iTcMc_EncoderDigCam. See also Special case: digital position cams.