IAxisPlcOpenMcParameterDrive
- Namespace
- ZEquipment
Drive parameters are used during active execution of your application such as homing of axis or changing an acceleration value from time to time. When writing parameters through this function block, those are generally written before an async action such as MoveAbsoluteAsync or MoveVelocityAsync is started and are therefore instantaneous active; In the case of an AxisPlcOpenMcParameterDrive function block the parameters of the active motion controller such as TwinCAT NC-motion are written or read;
If needed one can call MotionControllerChannel to return an interface to a ParameterChannelPlcOpenUM instance. With this it is possible to write any parameter at any time while using the PlcOpen axis.
INTERFACE IAxisPlcOpenMcParameterDrive
Properties
HomingCalibrationCam
If homing based on reference cam (Plc cam) is enabled and the input is read by a different terminal than the drive then here the [digital input](xref:ZEquipment.DigitalInput] can be provided. This input is therefore linked to another input terminal (e.g. EL1014).
Use this property in combination with HomingMode Default and HomingReferenceMode
As default this Interface is not set
PROPERTY HomingCalibrationCam : IDigital
Property Value
HomingClearPositionLag
This feature is only active when homing in direct mode. It can be used to set the actual set point and actual position value to the same value, so that there is no following error present.
Default setting is FALSE
PROPERTY HomingClearPositionLag : BOOL
Property Value
- BOOL
HomingDirectionOffPlcCam
Defines the direction which is used to move away from the parametrized homing cam, after this has been found during homing movement.
The default setting is PlcOpenDirection.Undefined
PROPERTY HomingDirectionOffPlcCam : ZCore.PlcOpenDirection
Property Value
HomingDirectionTowardsPlcCam
Defines the movement direction in which the drive starts to search.
The default setting is PlcOpenDirection.Undefined
PROPERTY HomingDirectionTowardsPlcCam : ZCore.PlcOpenDirection
Property Value
HomingMode
The plc homing mode defines how the homing should take place. The different modes are explained in PlcOpenHomingMode enumeration.
The default setting is PlcOpenHomingMode.Default
PROPERTY HomingMode : ZCore.PlcOpenHomingMode
Property Value
HomingPosition
Defines the absolute reference position which will be set after homing finished successfully.
The default homing position is 0.0
PROPERTY HomingPosition : LREAL
Property Value
- LREAL
HomingReferenceMode
Defines how the actual homing should take place. The different available modes are defined in PlcOpenHomingEncoderReferenceMode enumeration.
Default value is Default
PROPERTY HomingReferenceMode : ZCore.PlcOpenHomingEncoderReferenceMode
Property Value
HomingVelocityOffPlcCam
This velocity is used to move the axis away from the found homing cam. This setting is used together with HomingDirectionOffPlcCam.
The default homing velocity to go off the Plc cam is set to 0.0
PROPERTY HomingVelocityOffPlcCam : LREAL
Property Value
- LREAL
HomingVelocityTowardsPlcCam
Velocity which is used to search for the actual parametrized homing value (e.g. cam). This setting is used together with HomingDirectionTowardsPlcCam.
The default homing velocity to go towards the Plc cam is set to 0.0
PROPERTY HomingVelocityTowardsPlcCam : LREAL
Property Value
- LREAL
ModuloMoveDirection
If positioning type is set to PlcOpenPositioningType.Modulo there are different ways to make a modulo positioning.
- PlcOpenDirection.ShortestWay: The axis will move on the shortest path to its final position. For example: lets assume the axis has a modulo factor of 360 deg and its actual position is 10. We want to start a move PTP to 350 deg -> the axis will move -20 deg over 0 deg to 350 deg.
- PlcOpenDirection.PositiveDirection: The axis will only move in positive direction to reach its final position. For example: lets assume the axis has a modulo factor of 360 deg and its actual position is 10. We want to start a move PTP to 350 deg -> the axis will move 340 deg in positive direction to 350 deg.
- PlcOpenDirection.NegativeDirection: The axis will only move in negative direction to reach its final position. For example: lets assume the axis has a modulo factor of 360 deg and its actual position is 10. We want to start a move PTP to 350 deg -> the axis will move -20 deg over 0 deg to 350 deg.
Once this property is set, it will be stay on that value until a new movement will be executed. The default value for this property is PlcOpenDirection.ShortestWay
PROPERTY ModuloMoveDirection : ZCore.PlcOpenDirection
Property Value
MotionControllerChannel
This method returns an interface to the ParameterChannel of the active motion controller (e.g. for TwinCAT this is NcMotion). Therefore it is possible for the user to set every parameter in the application without separetely instantiating all parameter-function blocks or a suitable ParameterChannelPlcOpenUM from Zeugwerk Framework.
PROPERTY MotionControllerChannel : ZCore.IParameterChannel
Property Value
NegativeMovementEnabled
Set or test the negative direction lock to -> movement is allowed = TRUE, movement is locked = FALSE. Default setting is TRUE, which means movement direction negative is allowed.
PROPERTY NegativeMovementEnabled : BOOL
Property Value
- BOOL
PositioningDisplayType
Defines if the actual position is shown in modulo or absolute representation This property is changed automatically if the positioning type gets changed. However, if you change this property manually, a change in the positioning type will not change the display.
PROPERTY PositioningDisplayType : ZCore.PlcOpenPositioningType
Property Value
PositioningType
Defines the type of positioning for MoveAbsoluteAsync and (if not set otherwise) also the actual position which can be tested with ActualPosition. It is also possible to define modulo positioning type and absolute actual position display, but then the latter has to be set manually by setting the property to PlcOpenPositioningType.Absolute
Once a position display change has been done changing the positioning type of the axis will not change the position display again.
The default value here is [PlcOpenPositioningType.Absolute](xref:ZCore.PlcOpenPositioningType#Absolute
PROPERTY PositioningType : ZCore.PlcOpenPositioningType
Property Value
PositiveMovementEnabled
Set or test the positive direction lock to -> movement is allowed = TRUE, movement is locked = FALSE. Default setting is TRUE, which means movement direction negative is allowed.
PROPERTY PositiveMovementEnabled : BOOL
Property Value
- BOOL
Methods
ResetHomingParameter
This method is used to reset the saved parameters for MC_Home action of PlcOpenMc Axis. If there are any parameters set once by use of this Parameter-Channel, these parameters have to be used for the entire time of the actively running PLC.
If there are no parameters set, MC_Home will be executed by using the parameters which are set in the corresponding motion controller (e.g. Beckhoff NC-Motion).
By setting resetToDefault input to TRUE the default parameters are set as documented in each Property/Method
METHOD ResetHomingParameter (
resetToDefault : BOOL)
Inputs
resetToDefault
BOOLif set to TRUE, default parameters are set otherwise no parameters are written to MC_Home
ResetModuloParameter
This method is used to reset the saved parameters for MC_MoveModulo action of PlcOpenMc Axis. If there are any parameters set once by use of this Parameter-Channel, these parameters have to be used for the entire time of the actively running PLC.
If there are no parameters set, MC_MoveModulo will be executed by using the parameters which are set in the corresponding motion controller (e.g. Beckhoff NC-Motion).
By setting resetToDefault input to TRUE the default parameters are set as documented in each Property/Method
METHOD ResetModuloParameter (
resetToDefault : BOOL)
Inputs
resetToDefault
BOOLif set to TRUE, default parameters are set otherwise no parameters are written to MC_MoveModulo
SetHomingOptions
The PlcOpen MC_Home function block uses a set of homing options which have to be set in one dataset and therefore these have to be set here by these five inputs.
The default values are:
- ClearPositionFlag := FALSE
- DirectionTowardsPlcCam := ZCore.PlcOpenDirection.Undefined
- VelocitytowardsPlcCam := 0.0
- DirectionOffPlcCam := ZCore.PlcOpenDirection.Undefined
- VelocityOffPlcCam := 0.0
- ReferenceMode := ZCore.PlcOpenHomingEncoderReferenceMode.Default
METHOD SetHomingOptions (
ClearPositionLag : BOOL,
DirectionTowardsPlcCam : ZCore.PlcOpenDirection,
VelocityTowardsPlcCam : LREAL,
DirectionOffPlcCam : ZCore.PlcOpenDirection,
VelocityOffPlcCam : LREAL,
ReferenceMode : ZCore.PlcOpenHomingEncoderReferenceMode)
Inputs
ClearPositionLag
BOOLDirectionTowardsPlcCam
PlcOpenDirectionVelocityTowardsPlcCam
LREALDirectionOffPlcCam
PlcOpenDirectionVelocityOffPlcCam
LREALReferenceMode
PlcOpenHomingEncoderReferenceMode