RCK_DriftCompensation (FB)
FUNCTION_BLOCK RCK_DriftCompensation
This function block is implemented to compensate the cutter drift which the cutter leaves it original position during the rotary cutter system runs for a long time that means the cutter axis stops at home position, but the cutter is not at the position where the homing sensor is. Usually, this is caused by the lost of precision from floating-point calculation or the relative slide between the cutter and the motor shaft.
An external function block or program should be used to capture the position of cutter axis when the cutter crosses the homing senor. The capture done signal and the detected cutter axis position need to be connected to the inputs SwitchDetected and DetectedPositon.
This function block can only be activated when cutter state is in “Automatic”.
Input AccLimit is used to define the percentage during the compensation which acceleration and deceleration work.
Note
The unit of MaxDeviation, MaxCompensation, DetectedPosition of cutter axis must be degree as the same in cutter axis setting page.
- InOut:
Scope
Name
Type
Initial
Comment
Input
EnableBOOLFALSE
Enable the function block with Enable = TRUE
MaxDeviationLREAL10.0
[Degree] specified maximum allowed deviation. Range: > 0 and <= 180/NumberOfCutter
MaxDeviationCountValueINT10
Specified maximum allowed times which the detected deviation continuously exceeds MaxDeviation. Range: >=0 and <= 100
MaxCompensationLREAL10.0
[Degree] Specified maximum amount of single compensation allowed. Range: >0 and <= MaxDeviation
AccLimitLREAL50.0
[Percentage] Defines the percentage during the compensation which acceleration and deceleration work. Range: >= 0 and <= 100
SwitchDetectedBOOLFALSE
The signal from external to indicate that a new position is deteced
DetectedPositionLREAL0.0
[Degree] the detected cutter axis position
Output
DoneBOOLShows the status of the command. Done = TRUE if the execution is finished
BusyBOOLIndicates that the function block is not finished
ActiveBOOLIndicates that drift compensation is working
ErrorBOOLSignals that error has occurred within function block
ErrorIDAC500_MotionControl.ERROR_IDError identification. For error details refer to Enumeration AC500_MotionControl.ERROR_ID
AppErrorIDError identification. For error details refer to Enumeration ERROR_ID
CurrentDeviationLREALthe current detected deviation
MaxDeviationCounterINTthe counter of how many times which the detected deviation continuously exceeds MaxDeviation, reset to zero automatically if the detected deviation is less than MaxDeviation
Inout
RotaryCutterReference to rotary cutter